开发者

How to find out the number of CPUs using SNMP

Is there a way to get the number of CPUs using SNMP in linux + net-snmp package (with the default net-snmp package mibs 开发者_运维问答installed)?

UC Davis SNMP mib provides a lot of CPU information, but I do not see an object for the number of CPUs.


Depends on the implementation, but the HOST-RESOURCES-MIB hrDevice.hrDeviceTable should contain entries for the number of CPUs.

OID: .1.3.6.1.2.1.25.3.2

Any devices in the table matching:

hrDeviceType: .1.3.6.1.2.1.25.3.1.3

indicates a CPU/Core/HyperThread

There is also the HOST-RESOURCES::hrDevice.hrProcessorTable table, which should indicate their firmware ID's, which should help you differentiate cores/hyperthreads from physical cpus.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜