快速业务通道

snmp抓取linux机器OID一览 抓取squidOID

作者 佚名技术 来源 Linux系统 浏览 发布时间 2012-04-17

CPU Statistics

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 snmpwalk -v 1 -c public localhost .1.3.6.1.4.1.2021.4.3.0
UCD-SNMP-MIB::memTotalSwap.0 = INTEGER: 489940 kB


Available Swap Space snmpwalk -v 1 -c public localhost .1.3.6.1.4.1.2021.4.4.0
UCD-SNMP-MIB::memAvailSwap.0 = INTEGER: 284752 kB


Total RAM in machine snmpwalk -v 1 -c public localhost .1.3.6.1.4.1.2021.4.5.0
UCD-SNMP-MIB::memTotalReal.0 = INTEGER: 255672 kB


The available real memory snmpwalk -v 1 -c public localhost .1.3.6.1.4.1.2021.4.6.0
UCD-SNMP-MIB::memAvailReal.0 = INTEGER: 14456 kB


the Total free memory in the machine (free Swap memory free RAM memory)

snmpwalk -v 1 -c public localhost .1.3.6.1.4.1.2021.4.11.0
UCD-SNMP-MIB::memTotalFree.0 = INTEGER: 298804 kB


Total RAM Shared snmpwalk -v 1 -c public localhost .1.3.6.1.4.1.2021.4.13.0
UCD-SNMP-MIB::memShared.0 = INTEGER: 0 kB


Total RAM Buffered snmpwalk -v 1 -c public localhost .1.3.6.1.4.1.2021.4.14.0
UCD-SNMP-MIB::memBuffer.0 = INTEGER: 2888 kB


Total Cached Memory snmpwalk -v 1 -c public localhost .1.3.6.1.4.1.2021.4.15.0
UCD-SNMP-MIB::memCached.0 = INTEGER: 47816 kB

Disk Statistics

The snmpd.conf needs to be edited. Add the following (assuming a machine with a single ‘/’ partition):

disk / 100000 (or)

includeAllDisks 10% for all partitions and disks

The OIDs are as follows

Path where the disk is mounted: .1.3.6.1.4.1.2021.9.1.2.1
Path of the device for the partition: .1.3.6.1.4.1.2021.9.1.3.1
Total size of the disk/partion (kBytes): .1.3.6.1.4.1.2021.9.1.6.1
Available space on the disk: .1.3.6.1.4.1.2021.9.1.7.1
Used space on the disk: .1.3.6.1.4.1.2021.9.1.8.1
Percentage of space used on disk: .1.3.6.1.4.1.2021.9.1.9.1
Percentage of inodes used on disk: .1.3.6.1.4.1.2021.9.1.10.1

System Uptime: .1.3.6.1.2.1.1.3.0

Examples

These Commands you need to run on the SNMP server

Get available disk space for / on the target host

#snmpget -v 1 -c “community” target_name_or_ip .1.3.6.1.4.1.2021.9.1.7.1

this will return available disk space for the first entry in the ‘disk’ section of snmpd.conf; replace 1 with n for the nth entry

Get the 1-minute system load on the target host

#sn

凌众科技专业提供服务器租用、服务器托管、企业邮局、虚拟主机等服务,公司网站:http://www.lingzhong.cn 为了给广大客户了解更多的技术信息,本技术文章收集来源于网络,凌众科技尊重文章作者的版权,如果有涉及你的版权有必要删除你的文章,请和我们联系。以上信息与文章正文是不可分割的一部分,如果您要转载本文章,请保留以上信息,谢谢!

分享到: 更多

Copyright ©1999-2011 厦门凌众科技有限公司 厦门优通互联科技开发有限公司 All rights reserved

地址(ADD):厦门软件园二期望海路63号701E(东南融通旁) 邮编(ZIP):361008

电话:0592-5908028 传真:0592-5908039 咨询信箱:web@lingzhong.cn 咨询OICQ:173723134

《中华人民共和国增值电信业务经营许可证》闽B2-20100024  ICP备案:闽ICP备05037997号