Using Microsoft’s New AD PowerShell Cmdlets

In the past two weeks I have really started playing with the new AD PowerShell cmdlets from Microsoft.  I am really glad these cmdlets are finally here.  I will admit though, to get them working in my lab, it was not easy.  I cant blame this though on the cmdlets themselves, as my problems stemmed…

0

Mailbox Database Statistics

UPDATED: Minor Script Modifications made, detailed help comments added mainly for PSv2 and units added to property names First of all, let me apologize as I have been posting very much lately.  My plan with this blog was to post at least twice a week.  Obviously my posting has slowed way down.  I haven’t at…

1

Example for Identifying Domain Controller Subnet Membership with PowerShell

First of all let me thank Rich Doyle (a fellow PFE) for allowing me to post this script.  Rich writes some pretty kick-butt stuff and I know I speak for many of us that appreciate his help and his scripts! Now Rich claims he hacked this together and didn’t get around to polishing it up…

1

Counting Public Folder SubFolders

This sample script was written by a brilliant fellow PFE named Chris Schrimsher.  Chris gave me permission to post this script out there to the two of you reading my posts…you know who you are 🙂 In this script there is a concept that he is using that I like.  He uses a hash table…

1

List Mailbox Sizes for both Exchange 2003 and Exchange 2007

This is a script I put together because…well I don’t remember what prompted me to write it.  Who cares 🙂 This script uses the built-in cmdlets for Exchange 2007 find 2007 servers and legacy servers.  It then uses WMI to talk to the legacy servers to get the mailbox sizes.  Technically, this script requires Exchange…

13

Resolve IP Addresses to Hostname using PowerShell

I had a previous customer shoot me an email asking for help whipping up a script to convert a list of IP addresses from a text file to their respective host names, and put that into another text file.  I put together a little demonstration script to show a way to get this done.  I…

13

So many ways to take care of that poor old cat – Getting a list of just directories in PowerShell

Such a simple concept…how can we just retrieve a listing of folders instead of files and folders.  Hopefully readers of this post know already that in PowerShell (1 or 2) we use “Get-ChildItem” (many still use the alias “dir”) to retrieve a listing of files and folders.  If you didn’t know that “dir” was an…

0

Find Expiring Certificates Using PowerShell – One-Liner and a Script

This code is not really complicated at all.  Just the same it can come in very handy, and some folks have never played with the Certificate provider.  I have provided a one-liner version of this code, and a script version.  They are basically the same, but certainly the script one is considerably more verbose and…

1

Get Exchange Mailbox Database Size – One-Liner – Version 2

In my previous post (Some Handy Exchange Mailbox and Database Size Powershell One-Liners), I introduced a handy one-liner for looking up current mailbox database sizes.  In Exchange 2007, the physical size of the database file isn’t listed when you run a cmdlet like “get-mailboxdatabase”.  This piece of information of course is of great interest to…

3

Lesson Learned Today about PowerShell’s .Net Type System

Today I was asked why this person saw more properties showing with a “format-table”, than with a “format-table *”.  I will admit, I wasn’t sure.  I kicked myself later once I got the answer and I realized I should have known this.  There is a PFE colleague of mine that always seems to be AMAZING…

0