Thursday, May 28, 2015

Install and Configure Net-SNMP v3 on HP-UX 11.31


1)     First download ixNet-SNMP_A.19.00-5.6.1.1.001_HP-UX_B.11.31_IA_PA.depot package
Note - Install above package only. Because latest package has known issue, new version unable to send snmpwalk request remotly.

2)   Install this package with following command

               swinstall -s /tmp/net-snmp/ixNet-SNMP_A.19.00-5.6.1.1.001_HP-UX_B.11.31_IA_PA.depot

3)   This package will install in /opt/iexpress/net-snmp directory
     /opt/iexpress/net-snmp
 
4)   Go that location and copy EXAMPLE.conf file to /opt/iexpress/net-snmp/etc/snmp/snmpd.conf

                cp /opt/iexpress/net-snmp/etc/EXAMPLE.conf /opt/iexpress/net-snmp/etc/snmp/snmpd.conf

5)   After copying that file open it with any text editor or use default vi editor

    vi /opt/iexpress/net-snmp/etc/snmp/snmpd.conf

   Add the following line at the top of the file
   agentaddress udp:163

   After editing above setting press ESC and insert :wq to save that file

6)  We are strongly suggest to use SNMP v3 for security. It is secured and encrypted process.
   For SNMP V3 read only secured user creation, go to installation directory

   cd /opt/iexpress/net-snmp

   net-snmp-config --create-snmpv3-user –ro        
               
                Above command will ask following question, insert necessary details and press enter
Enter a SNMPv3 user name to create:
hpuxsnmpv3cuser
Enter authentication pass-phrase:
hpuxv3passwd
Enter encryption pass-phrase:
                [press return to reuse the authentication pass-phrase]
                
7)  Finally Start the Net-SNMP Agent

/opt/iexpress/net-snmp/sbin/snmpd

8)  Test SNMP connection using snmpwalk command

 snmpwalk -v3 -u hpuxsnmpv3user -A hpuxv3passwd -l authNoPriv -a MD5 server ip:163

If every things ok then you will get output of snmpwalk command.