Re: snmpd - snmpget and snmpwalk inconsistent

Ryan Goodfellow <[email protected]>
Newsgroups gmane.network.net-snmp.user
Message-ID <CABnJGMgTLpdXg2fcuRbNh_iQWc6NuF+S2CPcUYeMzRhVDvwQ=g@mail.gmail.com>
snmpwalk always returns the correct value

On Sun, Apr 23, 2017 at 11:11 PM, Ulrich Windl <
[email protected]> wrote:

> >>> Ryan Goodfellow <[email protected]> schrieb am 21.04.2017 um 20:43 in
> Nachricht
> <CABnJGMiHzm3G8BNs3X_7BefRFpHKcKdQ7fktxX5RUyuW7VeFBw@mail.gmail.com>:
> > Hi,
> >
> > I have observed a puzzling inconsistency between the get and walk
> requests
> > from snmpd. I am running the daemon on a Cumulus Linux switch. The
> > following shell sessions shows the issue.
> >
> > ### SERVER (stem) ###
> >
> > ry@stem$ snmpd --version
> > NET-SNMP version:  5.7.3
> >
> > ry@stem$ service snmpd restart
> >
> > ry@stem$ pgrep -lfa snmpd
> > 1298 /usr/sbin/snmpd -y -LF d /var/log/snmp -DALL -u snmp -g snmp -I
> -smux
> > -p /run/snmpd.pid -f
> >
> >
> > ### CLIENT ###
> >
> > ## initial request for ifNumber using GET returns 0 (wrong)
> > ry$ date && snmpget -c public -v2c stem .1.3.6.1.2.1.2.1.0
> > Fri Apr 21 18:20:15 UTC 2017
> > iso.3.6.1.2.1.2.1.0 = INTEGER: 0
> >
> > ## initial request for ifNumber using WALK returns 11 (correct)
> > ry$ date && snmpwalk -c public -v2c stem .1.3.6.1.2.1.2.1.0
> > Fri Apr 21 18:20:20 UTC 2017
> > iso.3.6.1.2.1.2.1.0 = INTEGER: 11
>
> What happens if you start with snmpwalk? It looks like if the first query
> after some pause returns the incorrect value, independent of the method.
>
> >
> > ## subsequent requests for ifNumber using GET returns 11 (correct)
> > ry$ date && snmpget -c public -v2c stem .1.3.6.1.2.1.2.1.0
> > Fri Apr 21 18:20:24 UTC 2017
> > iso.3.6.1.2.1.2.1.0 = INTEGER: 11
> >
> > ## after some time passes GET is back to being incorrect
> > ry$ date && snmpget -c public -v2c stem .1.3.6.1.2.1.2.1.0
> > Fri Apr 21 18:21:58 UTC 2017
> > iso.3.6.1.2.1.2.1.0 = INTEGER: 0
> >
> > In doing some tests, I have determined that the value goes back to 0
> > exactly 1 minute after the walk was executed.
> >
> >
> >
> > --
> > *ry**@isi*
>
>
>
>
>


-- 
*ry**@isi*

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot

_______________________________________________
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.