bond0網卡SNMP ifSpeed/ifHighSpeed欄位數值顯示錯誤造成cacti繪圖異常解法

參考資料: http://forum.nedi.ch/index.php?topic=1323.0

 

bond0(2000M) = eth0(1000M) + eth1(1000M)

在ifSpeed應該是顯示2000000000(2000M)但是卻是顯示10000000(10M),造成cacti在繪圖時有10M上限的錯誤限制導致流量大時顯示破圖

[root@storage-sata.idc.local ~]# snmpwalk -c public -v 2c localhost ifSpeed
IF-MIB::ifSpeed.1 = Gauge32: 10000000
IF-MIB::ifSpeed.2 = Gauge32: 4294967295
IF-MIB::ifSpeed.3 = Gauge32: 4294967295
IF-MIB::ifSpeed.4 = Gauge32: 1000000000
IF-MIB::ifSpeed.5 = Gauge32: 100000000
IF-MIB::ifSpeed.6 = Gauge32: 1000000000
IF-MIB::ifSpeed.7 = Gauge32: 1000000000
IF-MIB::ifSpeed.8 = Gauge32: 100000000
IF-MIB::ifSpeed.9 = Gauge32: 100000000
IF-MIB::ifSpeed.10 = Gauge32: 10000000
IF-MIB::ifSpeed.11 = Gauge32: 0
[root@storage-sata.idc.local ~]# snmpwalk -c public -v 2c localhost ifDesc
IF-MIB::ifDescr.1 = STRING: lo
IF-MIB::ifDescr.2 = STRING: eth6
IF-MIB::ifDescr.3 = STRING: eth7
IF-MIB::ifDescr.4 = STRING: eth2
IF-MIB::ifDescr.5 = STRING: eth3
IF-MIB::ifDescr.6 = STRING: eth0
IF-MIB::ifDescr.7 = STRING: eth1
IF-MIB::ifDescr.8 = STRING: eth4
IF-MIB::ifDescr.9 = STRING: eth5
IF-MIB::ifDescr.10 = STRING: bond0
IF-MIB::ifDescr.11 = STRING: br0

 

修正的方式為編輯/etc/snmp/snmpd.conf加入下面這行

interface bond0 6 2000000000

執行service snmpd restart

[root@storage-sata.idc.local ~]# snmpwalk -c public -v 2c localhost ifSpeed
IF-MIB::ifSpeed.1 = Gauge32: 10000000
IF-MIB::ifSpeed.2 = Gauge32: 4294967295
IF-MIB::ifSpeed.3 = Gauge32: 4294967295
IF-MIB::ifSpeed.4 = Gauge32: 1000000000
IF-MIB::ifSpeed.5 = Gauge32: 100000000
IF-MIB::ifSpeed.6 = Gauge32: 1000000000
IF-MIB::ifSpeed.7 = Gauge32: 1000000000
IF-MIB::ifSpeed.8 = Gauge32: 100000000
IF-MIB::ifSpeed.9 = Gauge32: 100000000
IF-MIB::ifSpeed.10 = Gauge32: 2000000000
IF-MIB::ifSpeed.11 = Gauge32: 0

修正後cacti的圖表

bonding

 

 

 

 

Facebook Comments Box

Leave a Reply