If you were at this year's TechEd event in New Orleans, I hoped you dropped by the SAPIEN Technologies booth and picked up your free Scripting Toolkit. What's that you say? Check it out on the SAPIEN blog and then download your free copy.
Category: WMI
This Old Script
I’m very slowly revising my main web site. The upshot for now is that there is no direct link to my old script library. Many of my Mr. Roboto tools can be found on this page. Until I can finish the upgrade project, you can use this link, http://www.jdhitsolutions.com/scripts.htm to take you directly to the…
TechEd 2010 VBScript to PowerShell
Last week I posted my demo slides as well as my demo videos. As promised, I’ve gone through and expanded a bit on my original slide deck. TechEdNA-2010-Hicks-ParadigmShift is a 3MB PDF of my expanded PowerPoint slide deck. If you have any questions about the content or what it takes to get your head from…
Get Parent Process
Recently I helping out on a post in the forums at ScriptingAnswers.com. The question centered around identifying processes on a computer and their parent process. There are many ways you could slice and dice this problem using WMI and Get-WmiObject. Getting the parent process ID is pretty simple, but going backwards from there to identify…
New WMI Object
I have one more variation on my recent theme of working with WMI objects. I wanted to come up with something flexible and re-usable where you could specify a WMI class and some properties and get a custom object with all the classes combined. My solution is a function called New-WmiObject. Function New-WMIObject { [cmdletbinding()]…
Select WMI
I’ve been helping out on some WMI and PowerShell issues in the forums at ScriptingAnswers.com. As I was working on a problem I ended up taking a slight detour to address an issue that has always bugged me. When I run a command like this: get-wmiobject -query “Select Name,Description,Disabled from Win32_UserAccount” PowerShell wants to return…
Test Connection Troubles
In this week’s Prof. PowerShell column, I have an article on using the Test-Connection in Windows PowerShell. I thought it was pretty straightforward, but I didn’t take problems into account. I received an email asking what to do about error messages. For example, what if you have a computername in the list that can’t be…
Promoting Scripting and PowerShell
Last week I was interviewed on the Mind of Root podcast about what administrators can do to promote PowerShell and automation in their environments. The show is now available for streaming or download. I still think your best approach is to gently let everyone know that it’s not a matter of if you will use…
Promoting PowerShell
This question comes up quite often: “How can I encourage adoption of Windows PowerShell in my organization?” I periodically poll people about their adoption plans and what sort of things are standing in the way. Most of the obstacles in my opinion can be cleared with experience, exposure and education. On Twitter today, @ChuckBoyceJr was…
Think Objectively
A challenge many new comers to PowerShell face, especially those arriving with a VBScript background, and one that I often talk about, is shifting gears from working with text to working with objects. Here’s a good example.
Get Disk Quota
During a recent class I was teaching, a student asked about a way to get disk quota reports from Windows file servers. I knew there was a WMI class, Win32_DiskQuota, and had some old VBScript files. However, they were pretty basic and not as robust as I would have liked. So I worked up PowerShell…
Drive Report Console Chart
In thinking about some of my recent posts, I realize I should make clear that these scripts and functions are not necessarily good PowerShell examples. They don’t take advantage of objects and the pipeline. They are single purpose and one-dimensional. Not that there’s anything wrong with that. My recent examples, and the one I have…
August Mr. Roboto link repaired
My August Mr. Roboto column was published online with a broken link to the PowerShell script. This has since been fixed. You can download the Get-WMIInfo.ps1 script from here.
Friendly WMI Dates
Gee..you think you know something only to find out you don’t. Or maybe this falls into the category of teaching an old dog new tricks.
When I first started using PowerShell several years ago, I learned about how to convert a WMI date to a more user friendly format…