Re: How to test the Agent
Dave Shield <[email protected]>
| Newsgroups | gmane.network.net-snmp.user |
|---|---|
| Message-ID | <CAKoMtGZJUdU=D977PRkrwfSaZe0zH-pfgmGmiOF--Kfbdm+foA@mail.gmail.com> |
On 2 November 2011 21:06, Simon Chamlian <[email protected]> wrote: > I launched the snmpd on the target with all config default values. Now I am > trying to get a value of an OID without success. > > ----------------------------------------------------------------------- > # snmpget -v 2c -c public 172.27.42.191 IP-MIB::ipv4InterfaceTable.0 > IP-MIB::ipv4InterfaceTable.0 = No Such Object That will never work - tables don't have a value. The management information is associated with column objects within the table. > # snmpget -v 2c -c public 172.27.42.191 RFC1213-MIB::ipInAddrErrors.0 > RFC1213-MIB::ipInAddrErrors.0 = No Such Object I'd normally expect that to work. The fact that you're getting "noSuchObject" implies that either the agent doesn't implement that MIB object, or the access control settings don't allow you to see it. > # snmpget -v 2c -c public 172.27.42.191 RFC1213-MIB::ipInAddrErrors That will never work - when using GET, you must *always* give the instance subidentifier (the row index for column objects, or 0 for a scalar) The second command was correct here. > What am I doing wrong? Can you see anything from the 'system' group? Try snmpget -v 2c -c public 172.27.42.191 SNMPv2-MIB::sysDescr.0 How have you configured the agent? What are the access control settings in your 'snmpd.conf' file? > Do I need a C application that connects to the agent (similar to open > socket) and listens to incoming Get/Set command and replies back? No. The agent handles this itself. Dave ------------------------------------------------------------------------------ RSA(R) Conference 2012 Save $700 by Nov 18 Register now http://p.sf.net/sfu/rsa-sfdev2dev1 _______________________________________________ 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