PowerShell for Windows Admins:

PowerShell v4


April 16, 2014  11:30 AM

WMI against remote machines



Posted by: Richard Siddaway
CIM, PowerShell 3, PowerShell v4, WMI

WMI is a great tool for managing your Windows machines – I’d argue that PowerShell wouldn’t be as powerful as it is without WMI. If you question that remember that 60% of the additional cmdlets in Windows Server 2012 & 2012 R2 are CDXML based i.e. publish a WMI class as a PowerShell...

April 15, 2014  10:06 AM

PowerShell versions



Posted by: Richard Siddaway
PowerShell 3, PowerShell v4

I’ve been using the CIM cmdlets for a number of posts recently and had a comment that a reader got a message that Get-CimInstance didn’t exist on their Windows 7 machine. Windows 7 ships with PowerShell 2.0; Windows 8 with PowerShell 3.0 and Windows 8.1 with PowerShell 4.0. You need...


April 14, 2014  2:43 PM

Status of Office software



Posted by: Richard Siddaway
CIM, Office 2010, Office 2013, PowerShell 3, PowerShell v4, WMI

You can also use the SoftwareLicensingProduct CIM class to test the status of your Office products. Get-CimInstance -ClassName SoftwareLicensingProduct -Filter "Name LIKE 'Office%'" | where PartialProductKey | select Name, ApplicationId, LicenseStatus You need to be careful with Office...


April 13, 2014  5:50 AM

Checking license activation



Posted by: Richard Siddaway
CIM, PowerShell 3, PowerShell v4, Windows Server 2012, Windows Server 2012 R2, WMI

I’m building some virtual machines for my demo’s at the upcoming PowerShell summit. To make the demo’s, and setup, more interesting(?) I decided to use some Server Core instances. The usual setup activities become a bit more interesting with Server Core – particular Windows...


April 10, 2014  2:16 PM

Requires



Posted by: Richard Siddaway
PowerShell Basics, PowerShell v4

A comment was left on my last post stating that the requires keyword could be used to test for modules. Requires is a keyword that can be put at the top of scripts and modules. It will prevent the script or module running if the requirement isn’t met.  You can test for a number of items. This...


April 9, 2014  1:33 PM

Testing module existence



Posted by: Richard Siddaway
PowerShell 3, PowerShell v4

I had a comment left on an old post stating that Get-ADuser errored stating it wasn’t a cmdlet. This is because the module wasn’t loaded or on PowerShell 3 and above available to be auto-imported. That got me thinking about testing for a modules existence. function test-module...


April 7, 2014  12:49 PM

Finding the class key



Posted by: Richard Siddaway
CIM, PowerShell 3, PowerShell v4, WMI

Time to extend our module for investigating CIM. This time I want to show you how to find the key to the class. You need to know the key property of a CIM class when you perform a number of actions – most particularly when you create an instance of the class. Its just a matter of iterating...


April 4, 2014  12:18 PM

Discovering namespaces part 2



Posted by: Richard Siddaway
CIM, PowerShell 3, PowerShell v4, WMI

I recently showed how to use Get-CimInstance to discover the namespaces present in a particular CIM namespace. I’m going to try to use CIM instaed of WMI but expect the old terminology to creep in occasionally. The function I showed last time will only find the first level of namespaces in a...


April 2, 2014  11:43 AM

CIM snippets–working with file system



Posted by: Richard Siddaway
CIM, File System, PowerShell 3, PowerShell v4, WMI

The latest instalment from the WMI team on using PowerShell and the CIM cmdlets is available -

Bookmark and Share     0 Comments     RSS Feed     Email a friend


March 31, 2014  4:03 AM

DSC resource kit wave 3



Posted by: Richard Siddaway
PowerShell v4, Windows Server 2012 R2

Desired State Configuration (DSC) is the new server configuration and compliance mechanism that ships with PowerShell 4.0 and Windows Server 2012 R2. Resources are the way you perform configuration. Now you have more options with the release of wave 3 of the DSC resource kit. Details from


Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to: