Need help for snmpset

"Wang, Dong" <[email protected]>
Newsgroups gmane.network.net-snmp.user
Message-ID <[email protected]>
Hi,

I need help. I adds new private mib process module to snmp agent, and
successfully bulid it into snmpd.

But I have problem when I use snmpset to set a data to snmp agent. I run
snmpd(snmp agent) on pc whose IP address is 10.48.138.84, and run
snmpset on other snmp client whose IP is 10.48.138.85. snmpset give
error shown below

# snmpset -v 2c -On -c public 10.48.138.84
.1.3.6.1.4.1.171.12.56.3.2.1.2 i 2
Error in packet.                                          
Reason: noAccess

But when I run snmpset on pc which run snmpd, it is no error

#snmpset -v 2c -On -c public localhost .1.3.6.1.4.1.171.12.56.3.2.1.2 i
2
.1.3.6.1.4.1.171.12.56.3.2.1.2 = INTEGER: 2

I thinks it maybe snmpd do not let other snmp client to write except
localhost. But I changed the /etc/snmp/snmpd.conf like below to let
10.48.138.85 have a writable right(I think). But, it does not work, and
have same error like "noAccess".

Could you give me some advice, tell me what wrong? Thanks ! 

/etc/snmp/snmpd.conf
...
#       sec.name  source          community
#com2sec notConfigUser  default       public
com2sec local          localhost     public
com2sec mynetwork      10.48.138.85  public
#com2sec mynetwork      10.48.137.0/24 public
#com2sec mynetwork      10.48.138.0/24 public
####
# Second, map the security name into a group name:

#       groupName      securityModel securityName
group   MyRWGroup    v1           mynetwork
group   MyRWGroup    v2c          mynetwork
group   MyRWGroup    usm          mynetwork
group   MyRWGroup    v1           local
group   MyRWGroup    v2c          local
group   MyRWGroup    usm          local
####
# 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 all    included  .1                               80

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

#       group          context sec.model sec.level match     read
write  notif
access  MyRWGroup      ""      any       noauth    exact     all    all
none

....

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Net-snmp-users mailing list
[email protected]
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.