Network Devices

Query IPMI with cnspec

Query IPMI interfaces with cnspec

Query and inventory your servers using cnspec and the Intelligent Platform Management Interface (IPMI). IPMI provides management and monitoring capabilities independently of the host system's CPU, firmware (BIOS or UEFI), and operating system.

Prerequisites

To query IPMI interfaces with cnspec, you must have:

Connect to an IPMI interface

To query an IPMI interface, provide the username and host address:

cnspec shell ipmi USER@HOST
For...Substitute...
USERYour IPMI username
HOSTThe IPMI interface IP or hostname

For example:

cnspec shell ipmi admin@192.168.1.100 --ask-pass
Enter password:

You can also provide the password directly:

cnspec shell ipmi admin@192.168.1.100 --password YOUR_PASSWORD

Example queries

Once connected, you can query IPMI resources.

Retrieve the device ID information

cnspec> ipmi.deviceID
ipmi.deviceID: {
  deviceAvailable: true
  deviceRevision: 1
  firmwareRevision: "2.45"
  ...
}

Retrieve the chassis status

cnspec> ipmi.chassis
ipmi.chassis: {
  systemPower: "on"
  ...
}

Retrieve the management controller GUID

cnspec> ipmi.guid
ipmi.guid: "12345678-1234-1234-1234-123456789abc"

Learn more

On this page