Konfiguracja progów (thresholds) dla sensorów w IPMI
Sensory IPMI klasy threshold dostarczają analogową wartość pomiaru (np. aktualną temperaturę) z przynależnymi do niej wartościami granicznymi (górnymi i dolnymi). W razie potrzeby mogą one (thresholds) zostać dostosowane do indywidualnych potrzeb. Dopasowane wartości obowiązują natychmiast po ich zmianie, nie są jednak we wszystkich systemach zapisywane na stałe w SDR. Po odłączeniu serwera od zasilania i następnym włączeniu wartości graniczne muszą zostać ponownie dopasowane (np. przez skrypt Init w Linuksie).[1] W tym artykule jest opisana edycja wartości granicznych na przykładzie ipmi-sensors-config z pakietu FreeIPMI i ipmitool. Dostosowujemy przy tym wartości sensora Serverboard Temp na serwerze Intel SR2500.
Systemy umożliwiające stały zapis skonfigurowanych wartości thresholds
W poniższym systemie zaobserwowaliśmy zapisanie ustawionych wartości granicznych na stałe:
- Supermicro X9SCM-F (przetestowane z firmwarem IPMI v1.30, edycja sensora FAN 1)
Jak opisano w instrukcji, taki stały zapis odbywa się w SDR, ale nie we wszystkich systemach.
Wartości graniczne
IPMI przewiduje do sześciu możliwych wartości granicznych, są to:
- unr: Upper Non-Recoverable
- ucr: Upper Critical
- unc: Upper Non-Critical
- lnc: Lower Non-Critical
- lcr: Lower Critical
- lnr: Lower Non-Recoverable
Ograniczenia
Jedynie wartości graniczne, które są standardowo dostępne mogą zostać edytowane. Thresholds, które nie są przewidziane przez producenta nie mogą zostać dodane. IPMI wspiera jedynie określone wartości graniczne dla sensorów typu threshold. Szczegółowe informacje na ten temat znajdują w "Settable Threshold Mask" i "Readable Threshold Mask" specyfikacji IPMI.[2]
Np. wartości graniczne dla sensorów mierzących prędkość pracy wentylatorów (np. Fan1) płyty głównej Supermicro X8DT3-F mogą zostać ustalone jedynie co 135 RPM (np. 270/405/540/675/...).
ipmi-sensors-config (FreeIPMI)
FreeIPMI oferuje narzędzie ipmi-sensors-config do edycji wartości granicznych.
Odczyt wartości granicznych
Z opcją -L mogą zostać odczytane poszczególne sensory. ipmi-sensors-config dodaje do nazw sensorów numer, gdyż w niektórych serwerach jedna nazwa jest używana przez kilka sensorów. Z -o -S mogą następnie zostać odczytane wartości graniczne:
user@ubuntu-10-10:~$ ipmi-sensors-config -h 192.168.1.211 -l admin -u admin -p **** -L 1_BB_+1.2V_Vtt 2_BB_+1.5V_AUX 3_BB_+1.5V 4_BB_+1.8V 5_BB_+3.3V 6_BB_+3.3V_STB 7_BB_+1.5V_ESB 8_BB_+5V 9_BB_+12V_AUX 10_BB_+0.9V 11_Serverboard_Temp [...] user@ubuntu-10-10:~$ ipmi-sensors-config -h 192.168.1.211 -u admin -p **** -l ADMIN -o -S 11_Serverboard_Temp Section 11_Serverboard_Temp ## Possible values: Yes/No Enable_All_Event_Messages Yes ## Possible values: Yes/No Enable_Scanning_On_This_Sensor Yes ## Possible values: Yes/No Enable_Assertion_Event_Lower_Non_Critical_Going_Low Yes ## Possible values: Yes/No Enable_Assertion_Event_Lower_Critical_Going_Low Yes ## Possible values: Yes/No Enable_Assertion_Event_Upper_Non_Critical_Going_High Yes ## Possible values: Yes/No Enable_Assertion_Event_Upper_Critical_Going_High Yes ## Possible values: Yes/No Enable_Deassertion_Event_Lower_Non_Critical_Going_Low Yes ## Possible values: Yes/No Enable_Deassertion_Event_Lower_Critical_Going_Low Yes ## Possible values: Yes/No Enable_Deassertion_Event_Upper_Non_Critical_Going_High Yes ## Possible values: Yes/No Enable_Deassertion_Event_Upper_Critical_Going_High Yes ## Give valid input for sensor type = Temperature; units = degrees C Lower_Non_Critical_Threshold 10.000000 ## Give valid input for sensor type = Temperature; units = degrees C Lower_Critical_Threshold 5.000000 ## Give valid input for sensor type = Temperature; units = degrees C Upper_Non_Critical_Threshold 61.000000 ## Give valid input for sensor type = Temperature; units = degrees C Upper_Critical_Threshold 66.000000 ## Give valid input for sensor type = Temperature; units = degrees C; 'None' to not use hysteresis Positive_Going_Threshold_Hysteresis 2.000000 ## Give valid input for sensor type = Temperature; units = degrees C; 'None' to not use hysteresis Negative_Going_Threshold_Hysteresis 2.000000 EndSection user@ubuntu-10-10:~$
Dopasowanie wartości granicznych
Z -c -e mogą zostać zmienione wartości graniczne:
user@ubuntu-10-10:~$ ipmi-sensors-config -h 192.168.1.211 -u admin -p **** -l ADMIN -c -e 11_Serverboard_Temp:Upper_Non_Critical_Threshold=51 user@ubuntu-10-10:~$ ipmi-sensors-config -h 192.168.1.211 -u admin -p **** -l ADMIN -c -e 11_Serverboard_Temp:Upper_Critical_Threshold=56 user@ubuntu-10-10:~$
Jeżeli kilka wartości granicznych ma być zmienionych, to wszystkie wartości mogą zostać zapisane w pliku, edytowane i następnie ponownie załadowane:
user@ubuntu-10-10:~$ ipmi-sensors-config -h 192.168.1.211 -u admin -p **** -l ADMIN --checkout -n sensors.orig user@ubuntu-10-10:~$ cp sensors.orig sensors.new user@ubuntu-10-10:~$ vi sensors.new user@ubuntu-10-10:~$ ipmi-sensors-config -h 192.168.1.211 -u admin -p **** -l ADMIN --commit -n sensors.new user@ubuntu-10-10:~$
Kontrola wartości granicznych
Z -o -S mogą zostać odczytane wartości graniczne po zakończeniu przeprowadzania zmian:
user@ubuntu-10-10:~$ ipmi-sensors-config -h 192.168.1.211 -u admin -p **** -l ADMIN -o -S 11_Serverboard_Temp Section 11_Serverboard_Temp ## Possible values: Yes/No Enable_All_Event_Messages Yes ## Possible values: Yes/No Enable_Scanning_On_This_Sensor Yes ## Possible values: Yes/No Enable_Assertion_Event_Lower_Non_Critical_Going_Low Yes ## Possible values: Yes/No Enable_Assertion_Event_Lower_Critical_Going_Low Yes ## Possible values: Yes/No Enable_Assertion_Event_Upper_Non_Critical_Going_High Yes ## Possible values: Yes/No Enable_Assertion_Event_Upper_Critical_Going_High Yes ## Possible values: Yes/No Enable_Deassertion_Event_Lower_Non_Critical_Going_Low Yes ## Possible values: Yes/No Enable_Deassertion_Event_Lower_Critical_Going_Low Yes ## Possible values: Yes/No Enable_Deassertion_Event_Upper_Non_Critical_Going_High Yes ## Possible values: Yes/No Enable_Deassertion_Event_Upper_Critical_Going_High Yes ## Give valid input for sensor type = Temperature; units = degrees C Lower_Non_Critical_Threshold 10.000000 ## Give valid input for sensor type = Temperature; units = degrees C Lower_Critical_Threshold 5.000000 ## Give valid input for sensor type = Temperature; units = degrees C Upper_Non_Critical_Threshold 51.000000 ## Give valid input for sensor type = Temperature; units = degrees C Upper_Critical_Threshold 56.000000 ## Give valid input for sensor type = Temperature; units = degrees C; 'None' to not use hysteresis Positive_Going_Threshold_Hysteresis 2.000000 ## Give valid input for sensor type = Temperature; units = degrees C; 'None' to not use hysteresis Negative_Going_Threshold_Hysteresis 2.000000 EndSection user@ubuntu-10-10:~$
ipmitool
ipmitool umożliwia również edycję wartości granicznych. Jednakże ipmitool używa do identyfikacji jedynie nazwę sensorów, co w przypadku serwerów z kilkoma sensorami o tej samej nazwie może powodować problemy.
Odczyt wartości granicznych
Z ipmitool sensor get SENSORNAME
odczytywane są aktualne wartości graniczne sensorów:
user@ubuntu-10-10:~$ ipmitool -I lan -H 192.168.1.211 -U admin -P **** sensor get "Serverboard Temp" Locating sensor record... Sensor ID : Serverboard Temp (0x30) Entity ID : 7.1 Sensor Type (Analog) : Temperature Sensor Reading : 32 (+/- 1.500) degrees C Status : ok Lower Non-Recoverable : na Lower Critical : 5.000 Lower Non-Critical : 10.000 Upper Non-Critical : 61.000 Upper Critical : 66.000 Upper Non-Recoverable : na Assertion Events : Assertions Enabled : lnc- lcr- unc+ ucr+ Deassertions Enabled : lnc- lcr- unc+ ucr+ user@ubuntu-10-10:~$
Dopasowanie wartości granicznych
user@ubuntu-10-10:~$ ipmitool -I lan -H 192.168.1.211 -U admin -P **** sensor thresh "Serverboard Temp" unc 51 Locating sensor record 'Serverboard Temp'... Setting sensor "Serverboard Temp" Upper Non-Critical threshold to 51.000 user@ubuntu-10-10:~$ ipmitool -I lan -H 192.168.1.211 -U admin -P **** sensor thresh "Serverboard Temp" ucr 56 Locating sensor record 'Serverboard Temp'... Setting sensor "Serverboard Temp" Upper Critical threshold to 56.000 user@ubuntu-10-10:~$
Kontrola wartości granicznych
Nowe wartości graniczne już obowiązują, co pokazuje ipmitool sensor get "Serverboard Temp"
:
user@ubuntu-10-10:~$ ipmitool -I lan -H 192.168.1.211 -U admin -P **** sensor get "Serverboard Temp" Locating sensor record... Sensor ID : Serverboard Temp (0x30) Entity ID : 7.1 Sensor Type (Analog) : Temperature Sensor Reading : 33 (+/- 1.500) degrees C Status : ok Lower Non-Recoverable : na Lower Critical : 5.000 Lower Non-Critical : 10.000 Upper Non-Critical : 51.000 Upper Critical : 56.000 Upper Non-Recoverable : na Assertion Events : Assertions Enabled : lnc- lcr- unc+ ucr+ Deassertions Enabled : lnc- lcr- unc+ ucr+ user@ubuntu-10-10:~$
W Sensor Data Record Repository (SDR) są nadal zapisane pierwotne granice. W przypadku, gdy serwer zostanie odłączony od zasilania i ponownie podłączony obowiązują z powrotem pierwotne wartości graniczne.
user@ubuntu-10-10:~$ ipmitool -I lan -H 192.168.1.211 -U admin -P **** sdr get "Serverboard Temp" Sensor ID : Serverboard Temp (0x30) Entity ID : 7.1 (System Board) Sensor Type (Analog) : Temperature Sensor Reading : 33 (+/- 1.500) degrees C Status : ok Nominal Reading : 38.000 Normal Minimum : 20.000 Normal Maximum : 55.000 Upper critical : 66.000 Upper non-critical : 61.000 Lower critical : 5.000 Lower non-critical : 10.000 Positive Hysteresis : 2.000 Negative Hysteresis : 2.000 Minimum sensor range : Unspecified Maximum sensor range : Unspecified Event Message Control : Per-threshold Readable Thresholds : lcr lnc unc ucr Settable Thresholds : lcr lnc unc ucr Threshold Read Mask : lcr lnc unc ucr Assertion Events : Assertions Enabled : lnc- lcr- unc+ ucr+ Deassertions Enabled : lnc- lcr- unc+ ucr+ user@ubuntu-10-10:~$
Odnośniki
- ↑ Some sensor configuration may not be stored in non-volatile memory, so users may wish to veryify that new configurations exist after system reboots or to always run ipmi-sensors-config during system initialization. (Manpage ipmi-sensors-config)
- ↑ http://download.intel.com/design/servers/ipmi/IPMI2_0E4_Markup_061209.pdf na stronie 521 (strona 549 w PDFie)
Autor: Werner Fischer