1.被监控服务器安装snmp
编辑linux主机下的/etc/snmp/snmpd.conf文件
找到62行:
access notConfigGroup "" any noauth exact systemview none none
修改成:(如果有#号,把#号去掉)
access notConfigGroup "" any noauth exact mib2 none none
找到89行,把改行的#去掉:
#view mib2 included .iso.org.dod.internet.mgmt.mib-2 fc
修改成:
view mib2 included .iso.org.dod.internet.mgmt.mib-2 fc
重起snmpd:/etc/init.d/snmpd restart
2.监控服务器devise添加,选择SNMP - Interface Statistics添加网卡,其他默认,勾选网卡Graph Trees中添加新节点
验证snmp是否通:snmpwalk -v 2c -c public IP
备注:
1、查找以下字段:
sec.name source community
com2sec notConfigUser default public
将"comunity"字段改为你要设置的密码.比如"public".
将“default”改为你想哪台机器可以看到你的snmp信息,如10.10.10.10。
2、查找以下字段:
# Finally, grant the group read-only access to the systemview view.
# group context sec.model sec.level prefix read write notif
access notConfigGroup "" any noauth exact all none none
将"read"字段改为all.
3、查找以下字段:
# incl/excl subtree mask
#view all included .1 80
将该行前面的"#"去掉.
可以一试
待测试
access notConfigGroup "" any noauth exact mib2 none none
view all included .1 80
view mib2 included .iso.org.dod.internet.mgmt.mib-2 fc
或者
编辑linux主机下的/etc/snmp/snmpd.conf文件
找到62行:
access notConfigGroup "" any noauth exact systemview none none
修改成:(如果有#号,把#号去掉)
access notConfigGroup "" any noauth exact mib2 none none
找到89行,把改行的#去掉:
#view mib2 included .iso.org.dod.internet.mgmt.mib-2 fc
修改成:
view mib2 included .iso.org.dod.internet.mgmt.mib-2 fc
重起snmpd:/etc/init.d/snmpd restart