PowerShell: Prompt Function to Monitor Memory Usage

Have you ever wanted to monitor your memory utilization in a PowerShell instance, but may not want to continually issue commands to determine it? Introducing …… the PowerShell Prompt to monitor memory utilization!! function prompt { "$(‘{0:n2}’ -f ([double](Get-Process -Id $pid).WorkingSet/1MB)) MB> " } Here’s the result:

Continue reading

PowerShell: Finding Friday the 13th

Update (2012-01-13): Justin Dearing (aka @zippy1981) informed me that it would be more efficient to look at the 13th of each month, and test if it was a Friday. In theory at least, he’s absolutely correct; I wrote the function the first way I thought of it, and I always …

Continue reading

PowerShell: Move ConfigMgr Collections

Introduction If you work with Microsoft System Center Configuration Manager (SCCM / ConfigMgr) 2007 in any capacity, you probably are familiar with the concept of "collections" and how painful they can be to work with sometimes. The ConfigMgr console does not provide any method of moving a collection from one …

Continue reading

PowerShell: Report / Check the Size of ConfigMgr Task Sequences

Introduction In Microsoft System Center Configuration Manager 2007 operating system deployment (OSD), there is a limitation of 4MB for task sequence XML data. This is discussed in a couple of locations: http://social.technet.microsoft.com/forums/en-us/configmgrosd/thread/6C4A4BB2-847B-4290-878C-3E041D9B3FD2 http://myitforum.com/cs2/blogs/smslist/archive/2009/10/08/mssms-maximum-number-of-steps-in-an-sccm-task-sequence.aspx – Jason Sandys (ConfigMgr MVP) references the link below http://technet.microsoft.com/en-us/library/bb932192.aspx The Technet document linked to above says …

Continue reading

PowerShell: Override GPO and Detect Windows Updates

Introduction If you’re using a workstation in an enterprise environment, there may be Active Directory Group Policy Object (GPO) settings forcing a certain behavior of the Microsoft Windows Update Agent (aka. Automatic Update Agent). You might be a power user who wants to actually ensure that their workstation is fully …

Continue reading

PowerShell: Get a List of Installed Software from ConfigMgr

Let’s say you’ve got Microsoft’s System Center Configuration Manager (SCCM / ConfigMgr) in your IT environment (and if you don’t, why on earth not!). If you’re on the desktop management team, you might occasionally get requests from someone on a network or security team, inquiring as to the installed software …

Continue reading

ConfigMgr: Cleanup Software Updates Objects

Introduction A common complaint I hear about Microsoft System Center Configuration Manager (SCCM / ConfigMgr) 2007 is the ability to clean up expired and superseded software updates from the objects related to software updates. As software updates are marked as expired or are superseded by newer software updates, Microsoft marks …

Continue reading

PowerShell: Disable ConfigMgr Task Sequence Countdown Notification

Introduction If you are using Microsoft System Center Configuration Manager (SCCM / ConfigMgr) to deploy task sequences to ConfigMgr client systems, you may notice that by default, a countdown notification is shown as a balloon notification in the client’s system tray. In some cases, this functionality may be undesirable, and …

Continue reading

Extreme PowerShell / ConfigMgr: Extending Hardware Inventory

Introduction In previous versions of Microsoft System Center Configuration Manager (ConfigMgr / SCCM), a common task for administrators, engineers, and consultants, was to extend the hardware inventory configuration. These inventory extensions were written in Managed Object Format (MOF) and allowed the SCCM client agents to report back a wider array …

Continue reading