2009/3/4 kusuma. bm <kusuma...@globaledgesoft.com>:
> The /etc/snmp/snmpd.conf in snmpd contains
> rwuser initial
> rwuser wes.
>
> The /var/net-snmp/snmptrapd.conf in snmptrapd contains
> createUser initial MD5 initialpasswd

I'm not interested in /var/net-snmp/snmptrapd.conf.
That's not relevant to the agent.

What do you have in /var/net-snmp/snmpd.conf on 172.10.1.4?


> snmpusm -v3 -u initial -l authNoPriv -a MD5 -A initialpasswd 172.10.1.4:161
> create wes initial
>
> User successfully created. ->is my output.
>
> now if i try to give the command from snmptrapd
> snmpwalk -v3 -u wes  -l authNoPriv -a MD5 -A initialpasswd 172.10.1.4 :161
> .1.3.6.1.6.3.15

Can you walk this tree using the user 'initial'?
Can you see *anything* using the user "wes"?

Try
     snmpgetnext -v3 -u initial -l authNoPriv -a MD5 -A
initialpassword 172.10.1.4 .1
     snmpgetnext -v3 -u wes -l authNoPriv -a MD5 -A initialpassword
172.10.1.4 .1

What is the output in each case?




> Accoding to me the above command should work since wes(cloned user)
> inherits/retains  the passphrase from 'initial'(existing user).

Yes - it should work.
I've just duplicated the exact same sequence of commands,
and everything has worked fine (see attached)



> So now if i try to change the passphrase for wes using the below command

There's no point in trying this until the "snmpwalk" command above works.


> I haven't configured anything in /var/net-snmp/snmpd.conf . What should i
> give in this file?

You need to create the 'initial' user.
Forget about /var/net-snmp/snmptrapd.conf on 172.10.1.5.
That's not relevant here.


I'm somewhat surprised that the initial 'snmpusm' command to create
the user 'wes' worked.    I strongly suspect that snmpd isn't reading the
config files that you think it is.

Did you compile this yourself, or are you using a pre-compiled version?
Try putting "rwuser" into the file /etc/snmp/snmpd.conf instead?

Dave
$ sudo vi /etc/snmp/snmpd.conf
$ sudo vi /var/net-snmp/snmpd.conf
$ sudo /etc/init.d/snmpd start
Starting snmpd:                                            [  OK  ]

$ snmptable -v3 -u initial -l authNoPriv -a MD5 -A initialpasswd localhost 
usmUserTable
SNMP table: SNMP-USER-BASED-SM-MIB::usmUserTable

 usmUserSecurityName        usmUserCloneFrom          usmUserAuthProtocol ....
             initial        zeroDotZero               usmHMACMD5AuthProtocol 
....

$ snmpusm -v3 -u initial -l authNoPriv -a MD5 -A initialpasswd localhost create 
wes initial
User successfully created.

$ snmptable -v3 -u initial -l authNoPriv -a MD5 -A initialpasswd localhost 
usmUserTable
SNMP table: SNMP-USER-BASED-SM-MIB::usmUserTable

 usmUserSecurityName        usmUserCloneFrom          usmUserAuthProtocol ....
                 wes        zeroDotZero               usmHMACMD5AuthProtocol 
....
             initial        zeroDotZero               usmHMACMD5AuthProtocol 
....

$ snmptable -v3 -u wes -l authNoPriv -a MD5 -A initialpasswd localhost 
usmUserTable
SNMP table: SNMP-USER-BASED-SM-MIB::usmUserTable

 usmUserSecurityName        usmUserCloneFrom          usmUserAuthProtocol ....
                 wes        zeroDotZero               usmHMACMD5AuthProtocol 
....
             initial        zeroDotZero               usmHMACMD5AuthProtocol 
....

$ snmpwalk -v3 -u wes  -l authNoPriv -a MD5 -A initialpasswd localhost 
.1.3.6.1.6.3.15
SNMP-USER-BASED-SM-MIB::usmStatsUnsupportedSecLevels.0 = Counter32: 0
SNMP-USER-BASED-SM-MIB::usmStatsNotInTimeWindows.0 = Counter32: 0
SNMP-USER-BASED-SM-MIB::usmStatsUnknownUserNames.0 = Counter32: 0
    :

$ snmpusm -v3 -u wes  -l authNoPriv -a MD5 -A initialpasswd localhost passwd 
initialpasswd wespasswd
no encryption type specified, which I need in order to know to change the key
$ snmpusm -v3 -u wes  -l authNoPriv -a MD5 -A initialpasswd -x DES localhost 
passwd initialpasswd wespasswd
SNMPv3 Key(s) successfully changed.

$ snmpwalk -v3 -u wes  -l authNoPriv -a MD5 -A wespasswd localhost 
.1.3.6.1.6.3.15
SNMP-USER-BASED-SM-MIB::usmStatsUnsupportedSecLevels.0 = Counter32: 0
SNMP-USER-BASED-SM-MIB::usmStatsNotInTimeWindows.0 = Counter32: 0
SNMP-USER-BASED-SM-MIB::usmStatsUnknownUserNames.0 = Counter32: 0
    :
------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise
-Strategies to boost innovation and cut costs with open source participation
-Receive a $600 discount off the registration fee with the source code: SFAD
http://p.sf.net/sfu/XcvMzF8H
_______________________________________________
Net-snmp-users mailing list
Net-snmp-users@lists.sourceforge.net
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users

Reply via email to