Skip to content

Instantly share code, notes, and snippets.

@denibertovic
Last active June 29, 2023 12:50
Show Gist options
  • Save denibertovic/140ce30dc79575337e518973879ff116 to your computer and use it in GitHub Desktop.
Save denibertovic/140ce30dc79575337e518973879ff116 to your computer and use it in GitHub Desktop.
Example for setting fan threshold with IPMI

set password

export IPMI_PASSWORD=xxxxx

USAGE info:

   id        : name of the sensor for which threshold is to be set
   threshold : which threshold to set
                 unr = upper non-recoverable
                 ucr = upper critical
                 unc = upper non-critical
                 lnc = lower non-critical
                 lcr = lower critical
                 lnr = lower non-recoverable
   setting   : the value to set the threshold to

sensor thresh <id> lower <lnr> <lcr> <lnc>
   Set all lower thresholds at the same time

sensor thresh <id> upper <unc> <ucr> <unr>
   Set all upper thresholds at the same time

LOWER

NOTE: for some reason Lower Non-Critical cannot be set (is ignored)

cpu

ipmitool -H 192.168.5.5 -U ADMIN -P $IPMI_PASSWORD sensor thresh FAN1 lower 280 560 600

chasis

ipmitool -H 192.168.5.5 -U ADMIN -P $IPMI_PASSWORD sensor thresh FAN2 lower 0 140 280
ipmitool -H 192.168.5.5 -U ADMIN -P $IPMI_PASSWORD sensor thresh FAN3 lower 0 140 280

hd zone

ipmitool sensor thresh FANA lower 420 560 800
ipmitool sensor thresh FANB lower 420 560 800

UPPER

NOTE: for some reason Upper Non-Critical cannot be set

cpu

ipmitool -H 192.168.5.5 -U ADMIN -P $IPMI_PASSWORD sensor thresh FAN1 upper 2660 2800 2940

chasis

ipmitool -H 192.168.5.5 -U ADMIN -P $IPMI_PASSWORD sensor thresh FAN2 upper 1540 1680 1820
ipmitool -H 192.168.5.5 -U ADMIN -P $IPMI_PASSWORD sensor thresh FAN3 upper 1540 1680 1820

hd zone

ipmitool sensor thresh FANA upper 1920 2060 2200
ipmitool sensor thresh FANB upper 1920 2060 2200
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment