Reading WMI Information

When creating task sequences you’ll find yourself using alot of WMI filters to determine if a certain task needs ran on a machine. I’ve found WMI Reader to be an excellent tool to dig through WMI. It can be downloaded for free from softpedia.

Deploying Server 2008 R2 Std via SCCM

I was asked to create a deployment for Server 2008 R2 today. I figured it would be easy as hell, however that wasn’t the case. The task sequence kept throwing an error on the “Setup Windows and ConfigMgr task. Ends up it was due to the product key. After messing around with the TS over and over again, I found that if I removed the product key the TS would finish successfully. I ended up finding out that the copy of Server 2008 R2 that I got off my companies licensing site doesn’t allow for a MAK key to be entered during setup. After some more searching online however I found a way to input the MAK key another way so that when the OS went to automatically activate itself it wouldn’t throw an error.

What you need to do is add a Run Command Line task to your TS that comes after the OS is already installed. Put in the command line “SLMGR.VBS -ipk XXXXX-XXXXX-XXXXX-XXXXX-XXXXX” and then tell it to start in %system root%system32.

By doing that you’re specifying a product key to be used during automatic activation.

ConfigMgr Console | The RPC Server is unavailable

In the event that you get the error

The RPC server is unavailable. (Exception from HRESULT: 0x800706BA)

when trying to launch the ConfigMgr console on a remote machine, the following is probably what’s going on.

You’re probably running Configuration Manager on a Server 2008 host, and you haven’t unblocked Remote Administration in the Windows Firewall. Either unblock that, or disable the Windows Firewall. Whichever you decide to do should fix your problem and allow you to manage ConfigMgr remotely.

Modifying your primary OS partition

So here’s the scenario that got me into posting this. One of the sysadmins created a new virtual machine in VMWare by cloaning another. The original only had a 20GB drive, but he wanted it to be 40GB. He added the needed space, and then was going to use a partitioning tool to modify the OS partition. Well, he found out that VMWare didn’t like his partition tool and wouldn’t allow it to boot so at that point I pointed out that he could just use diskpart. Apparently he was under the assumption that diskpart wouldn’t allow him to mess with the primary partition… but he soon discovered otherwise. All you need to do to be able to use diskpart to manage your partitions outside of windows is do the following…

  1. Get a WinPE 2.0 disc, or a Windows Vista/7 disc
  2. On the WinPE disc, just get to command prompt, which should be super easy. On the Windows installation discs, you’ll need to select your language, click Install Now, then click SHIFT + F10.
  3. Once the command prompt is up, type diskpart. You’ll then see your prompt change from X:> to DISKPART>
  4. At this point if you don’t know what commands you need, you can go to the below link to read up on it.


Set file associations with a script

So I’m ashamed to be presenting a scripting technique that doesn’t use PowerShell… but I don’t have the time right now to find out how to do it in PowerShell.

I’ve come across the need to set PDF files to open using Adobe Reader instead of another program. After looking into it, I found that I can create a batch file and use the assoc command, like so.

@echo off
assoc .pdf=AcroExch.Document
Simple as that.