Enabling SNMP for Red Hat Linux
Red Hat Linux has an SNMP agent, ucd-snmp, preinstalled. Ucd-snmp is the pre-cursor to net-snmp. You need to configure the ucd-snmp agent to return the host resource information and to ensure that it executes at system startup. This procedure provides the steps for enabling SNMP in a Red Hat Linux environment.
To enable SNMP for Red Hat Linux:
1. Locate the SNMPD configuration file in /etc/snmp/snmpd.conf and the executable at /usr/sbin/snmpd.
2. Configure the SNMP agent as shown in the following example, which shows read-only access to the system and host resource storage portions of the MIB.
####
# First, map the community name "public" into a "security name"
# sec.name source community
com2sec notConfigUser default public
####
# Second, map the security name into a group name:
# groupName securityModel securityName
group notConfigGroup v1 notConfigUser
group notConfigGroup v2c notConfigUser
####
# Third, create a view for us to let the group have rights to:
# name incl/excl subtree mask(optional)
#view systemview included .1
view Hitachi Storage Viewer included
.iso.org.dod.internet.mgmt.mib-2.system fe
view Hitachi Storage Viewer included
.iso.org.dod.internet.mgmt.mib-2.host.hrStorage ff
view Hitachi Storage Viewer included
.iso.org.dod.internet.mgmt.mib-2.host.hrDevice ff
# .iso.org.dod.internet.mgmt.mib-2.system = .1.3.6.1.2.1.1
# .iso.org.dod.internet.mgmt.mib-2.host.hrStorage = .1.3.6.1.2.1.25.2
####
# Finally, grant read-only access to the system and storage portions of
the MIB2 tree
# group context sec.model sec.level prefix read write
notif
#access notConfigGroup "" any noauth exact systemview none
none
access notConfigGroup "" any noauth exact Hitachi Storage Viewer
none none