2013 Scripting Games: Advanced Event 2
Summary: Dr. Scripto needs to create a tool to find basic information from his servers.Microsoft Scripting Guy, Ed Wilson, is here. Welcome to Week 2 of the 2013 Scripting Games. Just in case you are not up to speed, this year The Scripting Guys are not hosting the Scripting Games. They are being hosted at www.powershell.org. I am in full support of the Games, and I am posting the events here for your perusal. However, if you would like to submit an entry to the event, you must go to www.powershell.org.
An Inventory Intervention
Dr. Scripto finally has the budget to buy a few new virtualization host servers, but he needs to make some room in the data center to accommodate them. He thinks it makes sense to get rid of his lowest-powered old servers first…but he needs to figure out which ones those are. This is just the first wave, too. There’s more budget on the horizon, so it’s possible that he’ll need to run this little report a few times. Better make a reusable tool. All of the virtualization hosts run Windows Server, but some of them don’t have Windows PowerShell installed, and they’re all running different operating system versions. The oldest operating system version is Windows 2000 Server (he knows, and he’s embarrassed, but he’s just been so darned busy). The good news is that they all belong to the same domain, and that you can rely on having a Domain Admin account to work with. The good Doctor has asked you to write a Windows PowerShell tool that can show him each server’s name, the installed version of Windows, amount of installed physical memory, and number of installed processors. For processors, he’ll be happy to get a count of cores, or sockets, or even both—whatever you can reliably provide across all these versions of Windows. He has a few text files with computer names, and he’d like to pipe the computer names, as strings, to your tool, and have your tool query those computers. Oh, and in case he forgets how to use it—make sure this tool of yours has a full Help display available. I invite you to follow me on Twitter and Facebook. If you have any questions, send email to me at email@example.com, or post your questions on the Official Scripting Guys Forum. See you tomorrow. Until then, peace.
Ed Wilson, Microsoft Scripting Guy