龙空技术网

服务器监控配置-CentOS 上安装 NET-SNMP

小星看技术 133

前言:

此时姐妹们对“centos7snmp监控”大体比较关怀,看官们都想要知道一些“centos7snmp监控”的相关资讯。那么小编也在网络上收集了一些有关“centos7snmp监控””的相关内容,希望姐妹们能喜欢,你们快快来了解一下吧!

CentOS 上安装 NET-SNMP

1 安装SNMP

#yum install net-snmp

#yum install net-snmp-utils

#vi /etc/rc.local

添加一行:service snmpd start 设置开机自动运行

# chkconfig snmpd on

2 配置 SNMP

修改 snmp 配置文件

# vi /etc/snmp/snmpd.conf

查找

com2sec notConfigUser default public

将团体名 public 改为其它任意字段,例: com2sec notConfigUser default qishi

查找access notConfigGroup “” any noauth exact systemview none none

将 read 权限 systemview 改为 all,例:

access notConfigGroup “” any noauth exact all none none

查找

#view all included .1 80

去掉#view all 前面的#,例:

view all included .1 80

退出后重启

snmp #/etc/init.d/snmpd restart

3 添加防火墙策略

修改防火墙配置文件

#vi /etc/sysconfig/iptables

-A RH-Firewall-1-INPUT

-p udp

-m state

–state NEW

-m udp

–dport 161

-j ACCEPT

重启

Iptables #/etc/init.d/iptables restart

标签: #centos7snmp监控 #centos上安装snmp #centos内存大小snmp #centos snmp配置 #centos安装snmp