-
install net-snmp
$ sudo yum install net-snmp
-
edit
/etc/snmp/snmpd.conf
# /etc/snmp/snmpd.conf # rocommunity key IP rocommunity jiankongbao 60.195.252.107 rocommunity jiankongbao 60.195.252.110
- run
sudo /etc/init.d/snmpd restart
- run
sudo chkconfig snmpd on
-
if you have iptables
$ sudo iptables -I INPUT 1 -p udp -s 60.195.252.107 --dport 161 -j ACCEPT $ sudo iptables -I INPUT 1 -p udp -s 60.195.252.110 --dport 161 -j ACCEPT $ sudo cp /etc/sysconfig/iptables /etc/sysconfig/iptables.bak $ sudo iptables-save | sudo tee /etc/sysconfig/iptables
-
verify everything is ok
$ netstat -lpnu | grep 161 (No info could be read for "-p": geteuid()=509 but you should be root.) udp 0 0 0.0.0.0:161 0.0.0.0:* - $ chkconfig --list snmpd snmpd 0:off 1:off 2:on 3:on 4:on 5:on 6:off
Deploy snmpd on CentOS for jiankongbao
Tags: centos, snmpd, jiankongbao, snmp
Related Posts:
- 14 Sep 2013 » 出了问题不要靠猜
- 25 Aug 2013 » 小米盒子Tips
- 09 Aug 2013 » HTTP协议相关的若干安全问题
- 25 Dec 2012 » 日志分析工具
- 25 Oct 2012 » 世俗化的编程语言
- 15 Oct 2012 » [备忘]串号是如何发生的,我的一次串号Bug查找经历
- 11 Jun 2012 » Rails & MongoDB
- 03 Jun 2012 » [备忘] Jekyll FAQ
- 16 Dec 2011 » [有问有答] 如何用邮件安全地传递密码
- 05 Dec 2011 » context switch 很高,谁干的