Windows – Identification of Power Supplies on Windows Servers

hardwarepower-supply-unitpowershellwindows

First off, I'm not sure if this is the right form, but it seemed like the best fit.

For a management automation project, I am trying to identify the power supply units on servers across my network. Currently, I am doing this with a PowerShell script. I have tried using Get-WmiObject with the classes CIM_PowerSupply, CIM_UninturruptiblePowerSupply and Win32_Battery, but each return an empty collection.

Is this behaviour normal for these commands, and if so, are any other interfaces exposed to query for this hardware?

Best Answer

Servers, at least the HP and Dell ones that I am used to, often have an interface for a separate management network built into them. On HP it's named iLO (integreated lights out). Dell's is iDRAC. The idea is that these connect via Ethernet to an IP network, but typically a separate one from production, either by vlan or by physical separation. These management interfaces give you access to hardware diagnostics, BIOS settings, and the ability to remotely view the POST process. This often includes the ability to mount an iso or remote bootable media and use that to start the server without being in the room with it, theoretically from anywhere on the internet.

However, these interfaces are not often accessible inside the operating system of the server itself, unless you are using the management system. The WMI objects you are trying to use are the ones for UPS, where the UPS is connected to the server with a dedicated connection, e.g. USB cable. The purpose of this connection is to signal the server to shut down at a given condition.

So, short answer, yes, the behavior is normal if you do not have a UPS connected to your system.

To gather the information you need, you'll probably want to refer to whatever management system is available on your servers, if any. Otherwise, you can pull the info from invoices or do a physical inventory, if all you need is the specs of the power supplies.