Author: Mike F Robbins

Mike F Robbins is a Microsoft MVP on Windows PowerShell and a SAPIEN Technologies MVP. He is a co-author of Windows PowerShell TFM 4th Edition and is a contributing author of a chapter in the PowerShell Deep Dives book. Mike has written guest blog articles for the Hey, Scripting Guy! Blog, PowerShell Magazine, and He is the winner of the advanced category in the 2013 PowerShell Scripting Games. Mike is also the leader and co-founder of the Mississippi PowerShell User Group. He blogs at and can be found on twitter @mikefrobbins.

Toughest Event Yet – 2012 PowerShell Scripting Games Beginner Event #3

The details of the event scenario and the design points for Beginner Event #3 of the 2012 PowerShell Scripting Games can be found on the “Hey, Scripting Guys! Blog”. This was the toughest event out of the first three for me. I spent a lot of time researching how to check permissions because part of the first design point stated: "If you do not have permission off the root, create the nested folders where you have permissions". This was clarified in the comments section later during the day Read more [...]

Get-Method | My-Madness | 2012 PowerShell Scripting Games Beginner Event #2

The details of the event scenario and the design points for Beginner Event #2 of the 2012 PowerShell Scripting Games can be found on the “Hey, Scripting Guys! Blog”. Listed below are my notes about the requirements and design points: Find all services that are running and can be stopped. The command must work against remote computers. Use the simplest command that will work. You do not need to write a script. Return the results to the screen, not to a file. You may use aliases. I started Read more [...]

My Approach to the 2012 PowerShell Scripting Games Beginner Event #1

The details of the event scenario and the design points for Beginner Event #1 of the 2012 PowerShell Scripting Games can be found on the “Hey, Scripting Guys! Blog”. Listed below are my notes about the requirements and design points: Computers run Windows 7 and servers run Windows 2008 R2. They’re all in one domain. PowerShell remoting is enabled on all computers (both servers and desktops). Use PowerShell to retrieve the top ten processes based on the memory working set. There’s no Read more [...]

Importing PowerShell Modules and Locating Added Cmdlets

Want to add a feature to a Windows Server 2008 R2 machine using PowerShell? That functionality is part of the ServerManager PowerShell Module that's install by default on 2008 R2. The module has to be imported for it's cmdlets to be made available since it's not loaded by default when you launch PowerShell. To view the Modules that are available to be imported, run Get-Module -ListAvailable The ServerManager module has to be imported so that it's commands are made available to PowerShell. Read more [...]

Game On! The 2012 PowerShell Scripting Games

Since this is my first year entering the PowerShell Scripting Games, I’m only submitting scripts for the beginner events but I’m also taking a look at the advanced ones to get an idea of what kind of knowledge is needed for them. It’s not too late to join in on the fun. Make sure you read the requirements of each event carefully, create your script, test it, and think about it for a while before submitting it. I had four stars on the first Beginner Event: Another judge must have given me Read more [...]

How Do I Get-Started With PowerShell?

Commands in PowerShell are called cmdlets (pronounced "command lets") and they are in the form of singular verb-noun commands like Get-Alias (not Get-Aliases). In my opinion, there are three cmdlets that are the key to figuring out how to use PowerShell and finding help when you need it. These cmdlets are: Get-Help (help) Get-Command (gcm) Get-Member (gm) Get-Help or Help for short. Help isn't actually an alias, but it works exactly the same way if your using the PowerShell ISE. I've Read more [...]

Using PowerShell to Ace the Scripting & Regular Expression Interview Question

Last week I saw a tweet that referenced a couple of interesting articles on interview questions for programmers. I'm no programmer, but one of them (Steve Yegge's The Five Essential Phone-Screen Questions) had an interesting question about identifying which of 50,000 web pages had phone numbers in them. You have to identify all of the web pages with phone numbers hard coded in them. All of the web pages are HTML files in a directory tree under a folder named website. The phone numbers are in the Read more [...]

Confusion on PowerShell Parameterized Functions

I've run into an issue with PowerShell functions that I don't understand. I guess my confusion is most of the examples I've found online and in books don't work the way the authors explained (at least not for me). The problem is when I define a parameter inside a function, that parameter is not accessible when running the script. When I move the parameter outside of the function, it's accessible and it works without issue. I'm guessing this is because of Read more [...]

Where Do I Find This Thing Called PowerShell?

If you’re running Windows 7, you already have PowerShell 2.0 installed. It’s located under “All Programs > Accessories > Windows PowerShell”. I’m running a 64bit version of Windows 7 so I have both 64bit and 32bit (x86) links in my start menu. I prefer the PowerShell ISE (Integrated Scripting Environment) as apposed to the PowerShell Console. I use the 64bit version and have never run into an issue where I needed to use the 32bit (x86) versions. According to the Microsoft Support Read more [...]

Get-WmiObject : The RPC Server is Unavailable. (Exception from HRESULT: 0x800706BA)

This week while working with some PowerShell scripts that retrieve WMI information from remote servers, I ran into an issue where I was able to return results from Windows 2008 R2 servers without issue but was unable to return results from Windows 2008 (non-R2) servers even though they had PowerShell 2.0 installed and as far as I could tell they were configured exactly the same as the Windows 2008 R2 servers. Here's the error I received: Get-WmiObject : The RPC server is unavailable. (Exception Read more [...]

Your Search Cannot Be Completed Because This Site Is Not Assigned To An Indexer.

Your attempting to search a SharePoint 2010 Site (Foundation Edition) and you receive the following error message "Your search cannot be completed because this site is not assigned to an indexer." Search has never been configured for this SharePoint farm so we'll be configuring it from the ground up. First you'll need two service accounts, one for the search service to run as and one for the actual crawling. Todd Klindt has a great blog on service accounts that I use for reference. I used the Read more [...]

Installation of SQL Server Features from the Command Line

I'm installing a line of business application that requires the SQL Server Management Studio and Client Tools Connectivity be installed as a prerequisite. I want to script this instead of having to manually click through the GUI for the installation since this will be installed on several servers. I've mounted the SQL Server 2008 R2 ISO on "Z" drive. The following command will produce the desired results: At first, I thought that the CONN parameter was incorrect Read more [...]

Set EqualLogic PS Series SAN Volume ACL’s using PowerShell

Query and return the current Access Control List (ACL) for an EqualLogic PS Series SAN volume named "mikefrobbins" using PowerShell: You can see the same information using the GUI: Remove the current ACL’s using the following PowerShell command: Once again, you can see the same information using the GUI: Add new ACL’s using the following PowerShell command: You can also Read more [...]

Unable to Grant Domain Local Groups Full Access Permission to a Exchange 2010 Mailbox using the GUI

John Doe is a user in your Active Directory environment (Windows Server 2008 R2 Forest Function Level) with a mailbox on the email server (Exchange Server 2010 with SP2): You want to grant a domain local group named "Test Group" the full access permission to John Doe's mailbox: You attempt to grant this permission by selecting "Manage Full Access Permission" from the Exchange 2010 Management Console: When you click add and search for the group, it doesn't appear: PowerShell to Read more [...]

Oh Where, Oh Where Have My Group Policy Options Gone?

You are unable to find specific GPO options such as “Compatibility View” settings for Internet Explorer. One of the first things to look at is: Where are the policy definitions being retrieved from? The default for an Active Directory environment is from the local machine as shown in the image below: If you’re editing the GPO on a domain controller and have multiple domain controllers that are running different operating system versions, the available options will vary from machine Read more [...]

Open a SharePoint Document Library with Windows Explorer

When attempting to open a SharePoint document library from a machine running Windows Server 2008 or 2008 R2 by using the “Open with Explorer” button as shown in the image to the right, you receive:  “Message from webpage > Your client does not support opening this list with Windows Explorer.”: To resolve this problem, enable the “Desktop Experience” feature on the machine you are attempting to open the document library from (the client machine): You can also enable the "Desktop Read more [...]