Search

Custom Search

Thursday 22 October 2015

Enabling SNMP in Oracle Enterprise Linux

1. Install the required tools using 


yum -y install net-snmp net-snmp-utils

2. Enable ports 162 and 161 UDP, TCP in firewall

3. Edit config file

vi /etc/snmp/snmpd.conf

Should look like the following

# com2sec notConfigUser  default       public

com2sec notConfigUser   default        nameofcommunitystring
#com2sec ConfigUser     default         nameofcommunitystring
com2sec AllUser         default             nameofcommunitystring

####
# Second, map the security name into a group name:

#       groupName      securityModel securityName
group   notConfigGroup  v1              notConfigUser
group   notConfigGroup  v2c             notConfigUser
group   ConfigGroup     v2c             ConfigUser
group   AllGroup        v2c             AllUser

####
# Third, create a view for us to let the group have rights to:

# Make at least  snmpwalk -v 1 localhost -c public system fast again.
#       name           incl/excl     subtree         mask(optional)
view    systemview    included   .1.3.6.1.2.1.1
#view    systemview    included   .1.3.6.1.2.1.25.1.1
view    systemview    included   .1.3.6.1.2.1.25
view    AllView       included        .1

####
# Finally, grant the group read-only access to the systemview view.

#       group          context sec.model sec.level prefix read   write  notif
access  notConfigGroup ""      any       noauth    exact  systemview none none
access  ConfigGroup     ""      any     noauth  exact   SystemView      none    none
access  AllGroup        ""      any     noauth  exact   AllView         none    none


3.Restart snmpd daemon

service snmpd restart

4. Configure SNMP to start when the server boots:

chkconfig snmpd on

5. Check config

snmpwalk -v 2c -c nameofcommunitystring -O e 102.106.0.460

1 comment:

  1. dafabet.com | Daftar Judi Bola, Slot Online, Live Bet
    Join our community of users to discuss and share dafabet your love of the casino games. Your data and conversations will help you find the gioco digitale perfect place sbobet ทางเข้า for you.

    ReplyDelete