Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

How to find total CPU utilization of a server using SNMP ? I am trying to find the CPU utilization % of one server having 64 CPU's ?

Thanks.

share|improve this question
    
Which OS? Does it use a standard SNMP library, or one of their own? –  Mark Henderson Sep 27 '11 at 11:22
    
Solatis 10. Yes, its having SNMP. –  Rubi Naaz Sep 27 '11 at 12:33
add comment

1 Answer

I'm going to guess you're using Linux, but because you don't specify, I can't guarantee that these will be OK (although they apply to most major Unix distribution as well)

The OID's you're looking for are (taken from here):

Load

  • 1 minute Load: .1.3.6.1.4.1.2021.10.1.3.1
  • 5 minute Load: .1.3.6.1.4.1.2021.10.1.3.2
  • 15 minute Load: .1.3.6.1.4.1.2021.10.1.3.3

CPU

  • percentage of user CPU time: .1.3.6.1.4.1.2021.11.9.0
  • raw user cpu time: .1.3.6.1.4.1.2021.11.50.0
  • percentages of system CPU time: .1.3.6.1.4.1.2021.11.10.0
  • raw system cpu time: .1.3.6.1.4.1.2021.11.52.0
  • percentages of idle CPU time: .1.3.6.1.4.1.2021.11.11.0
  • raw idle cpu time: .1.3.6.1.4.1.2021.11.53.0
  • raw nice cpu time: .1.3.6.1.4.1.2021.11.51.0

Memory Statistics

  • Total Swap Size: .1.3.6.1.4.1.2021.4.3.0
  • Available Swap Space: .1.3.6.1.4.1.2021.4.4.0
  • Total RAM in machine: .1.3.6.1.4.1.2021.4.5.0
  • Total RAM used: .1.3.6.1.4.1.2021.4.6.0
  • Total RAM Free: .1.3.6.1.4.1.2021.4.11.0
  • Total RAM Shared: .1.3.6.1.4.1.2021.4.13.0
  • Total RAM Buffered: .1.3.6.1.4.1.2021.4.14.0
  • Total Cached Memory: .1.3.6.1.4.1.2021.4.15.0

I can't remember off the top of my head, but I think the percentage of CPU time is 100*processors, so in your case, 100% is actually 6,400%

You can find all sorts of interesting things to monitor via SNMP here.

share|improve this answer
    
Thanks Mark for the detailed explanation. Can you please tell me the necessary parameters from the above list which provides the total CPU usage at a given time ? –  Rubi Naaz Sep 27 '11 at 12:41
    
You can only get "live" CPU usage from SNMP, so if you want to go back in time, you will need an NMS that polls the SNMP at regular intervals and stores the results. Nagios and Zabbix are the two most common I think for this, but might be overkill if all you're after is a simple CPU history. Otherwise, if you just want to get CPU usage now, then you need to use snmpget if you're using the net-snmp tools (otherwise you'll need to look up the syntax of whatever SNMP agent you're using) –  Mark Henderson Sep 27 '11 at 20:47
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.