snmpd Installation

yum install -y net-snmp net-snmp-devel net-snmp-utils cp -av /etc/snmp/snmpd.conf /etc/snmp/snmpd.conf.orig vi /etc/snmp/snmpd.conf #------------------------------------------------ com2sec local localhost public com2sec mynetwork public group MyRWGroup any local group MyROGroup any mynetwork view all included .1 80 view mib2 included fc access MyROGroup "" any noauth 0 all none none access MyRWGroup "" any noauth 0 all all all syslocation Unknown (edit /etc/snmp/snmpd.conf) syscontact Root (configure /etc/snmp/snmp.local.conf) pass . /usr/bin/ucd5820stat #------------------------------------------------ /etc/init.d/snmpd start chkconfig snmpd on

P.S. Add/Modify "com2sec" , the source ip is allowed to access.

vi /etc/sysconfig/snmpd OPTIONS="-Lf /dev/null -p /var/run/" ## OR OPTIONS="-LS0-5d -Lf /dev/null -p /var/run/ -x TCP:5000 UDP:5000"

Disable log or change port if necessary , remember change allow rule in firewall.

vi /etc/sysconfig/iptables -A INPUT -m udp -p udp --dport 161 -j ACCEPT /etc/init.d/iptables start

Add firewall rule if in necessary for outside SNMP server (MRTG/PRTG).

snmpwalk -v 2c -c public localhost system snmpwalk -v 2c -c public system

Test from MRTG snmp server.

Server is hosted by Alanstudio
Linux Operating System

Recommend screen resolution 1024 x 768 / IE / FireFox
Alan Studio © 2007 by Alan Cheung Hin Lun. All rights reserved.