snmp协议监控Linux
Posted 山を下りる
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了snmp协议监控Linux相关的知识,希望对你有一定的参考价值。
ip地址 | 服务 | |
zabbix | 10.0.0.71 | snmp客户端 |
web01 | 10.0.0.7 |
ip地址 | 服务 | |
web01 | 10.0.0.7 |
安装服务端
$ yum install net-snmp -y $ vim /etc/snmp/snmpd.conf 41 com2sec notConfigUser default linux ---修改口令 42 43 #### 44 # Second, map the security name into a group name: 45 46 # groupName securityModel securityName 47 group notConfigGroup v1 notConfigUser 48 group notConfigGroup v2c notConfigUser 49 50 #### 51 # Third, create a view for us to let the group have rights to: 52 53 # Make at least snmpwalk -v 1 localhost -c public system fast again. 54 # name incl/excl subtree mask(optional) 55 view systemview included .1 --.1下面的信息都可以看到 56 view systemview included .1.3.6.1.2.1.25.1.1 #开启snmp服务 $ systemctl start snmpd $ systemctl enable snmpd #查看端口 $ netstat -lntup | grep 161 udp 0 0 0.0.0.0:161 0.0.0.0:* 7857/snmpd