IPMI Sensor

Overview

Get bare metal metrics using the command line utility ipmitool.

If no servers are specified, the plugin will query the local machine sensor stats via the following command:

ipmitool sdr

or with the version 2 schema:

ipmitool sdr elist

When one or more servers are specified, the plugin will use the following command to collect remote host sensor stats:

ipmitool -I lan -H SERVER -U USERID -P PASSW0RD sdr

Configuration

# Read metrics from the bare metal servers via IPMI
[[inputs.ipmi_sensor]]
  ## optionally specify the path to the ipmitool executable
  # path = "/usr/bin/ipmitool"
  ##
  ## Setting 'use_sudo' to true will make use of sudo to run ipmitool.
  ## Sudo must be configured to allow the 'cua' user to run ipmitool
  ## without a password.
  # use_sudo = false
  ##
  ## optionally force session privilege level. Can be CALLBACK, USER, OPERATOR, ADMINISTRATOR
  # privilege = "ADMINISTRATOR"
  ##
  ## optionally specify one or more servers via a url matching
  ##  [username[:password]@][protocol[(address)]]
  ##  e.g.
  ##    root:passwd@lan(127.0.0.1)
  ##
  ## if no servers are specified, local machine sensor stats will be queried
  ##
  # servers = ["USERID:PASSW0RD@lan(192.168.1.1)"]

  ## Recommended: use metric 'interval' that is a multiple of 'timeout' to avoid
  ## gaps or overlap in pulled data
  interval = "30s"

  ## Timeout for the ipmitool command to complete. Default is 20 seconds.
  timeout = "20s"

  ## Schema Version: (Optional, defaults to version 1)
  metric_version = 2

Permissions

When gathering from the local system, the agent will need permission to the ipmi device node. When using udev you can create the device node giving rw permissions to the cua user by adding the following rule to /etc/udev/rules.d/52-circonus-unified-agent-ipmi.rules:

KERNEL=="ipmi*", MODE="660", GROUP="cua"

Alternatively, it is possible to use sudo. You will need the following in your config:

[[inputs.ipmi_sensor]]
  use_sudo = true

You will also need to update your sudoers file:

$ visudo
# Add the following line:
Cmnd_Alias IPMITOOL = /usr/bin/ipmitool *
cua  ALL=(root) NOPASSWD: IPMITOOL
Defaults!IPMITOOL !logfile, !syslog, !pam_session