ipmitool dcmi power reading
v1.0.0
당신이 스스로에게 "내 전력 소비 수를 얻는 방법"이라고 스스로에게 묻고 있기 때문에?
인터넷 링크 :
따라서 두 가지 옵션이있는 것 같습니다.
나는 RacADM 방법을 몇 년 동안 사용했는데, IDRAC 세션이 열려 있기 때문에 느리고 때로는 작동하지 않습니다. 그런 다음 ipmitool을 사용했는데 훌륭했지만 구문 분석해야 할 텍스트 출력이있었습니다.
그래서 처음에는 동일한 텍스트 출력으로 동일한 도구를 작성했으며 작동했습니다. 원래 C 코드는 여기에서 찾을 수 있습니다 : Ipmitool 1.8.19
이를 가능하게 한 도서관 IPMI-R에 특별한 감사를드립니다.
A tool to fetch the power reading with ipmi dcmi
Usage: ipmitool-dcmi-power-reading [OPTIONS]
Options:
-c, --connection-uri <CONNECTION_URI>
The connection URI to use [default: file:///dev/ipmi0]
--timeout-ms <TIMEOUT_MS>
How many milliseconds to wait before timing out while waiting for a response [default: 2000]
--format <FORMAT>
The format to output [default: text] [possible values: text, json]
-h, --help
Print help
-V, --version
Print version
Instantaneous power reading : 212 Watts
Minimum during sampling period : 2 Watts
Maximum during sampling period : 468 Watts
Average power reading over sample period : 184 Watts
IPMI timestamp : 2024-05-05 14:17:17 UTC
Sampling period : 1000 Milliseconds
Power reading state is : activated
{ "grp_id" : 220 , "curr_pwr" : 209 , "min_sample" : 2 , "max_sample" : 468 , "avg_pwr" : 184 , "time_stamp" : 1714918638 , "sample" : 1000 , "state" : 64 }