Is this an appropriate venue to ask about the perl SNMP routines?

I am using the package version 5.7.3 on Ubuntu 15.40.

Generally it is working, but I have one routine that attempts to query a cisco 
table as below, and in most cases it works, but for one large ASA with a lot of 
tunnels, it fails to return all rows in the table, returning what appears to be 
a random subset of about half  of them.  Using the snmpwalk command works fine.

The code is as follows:

    my %snmpparms;
    $snmpparms{Community} = $community;
    $snmpparms{DestHost} = inet_ntoa(inet_aton($IP));
    $snmpparms{Version} = "2";
    $snmpparms{UseSprintValues} = '1';
    $snmpparms{UseEnums} = '0';
    $snmpparms{UseNumeric} = '0';
    $snmpparms{NonIncreasing} = '1';
    $snmpparms{Timeout}=10000000;   # need long timeout for large tables over 
WAN
    $sess = new SNMP::Session(%snmpparms);

    # Now pull in the correlation table so we know which are real tunnels
    my $RtnCorrHash = ( 
$sess->gettable('CISCO-IPSEC-FLOW-MONITOR-MIB::cikePeerCorrTable') );


I've tried various combinations of the options in the session parameters 
without any change.  I've also tried placing a column list on the gettable 
without any change.

I had this same problem with another large table and just converted it to 
specific calls to getbulk, but I rather liked using gettable in this case.

There is no error returned from the gettable call.  The data returned is 
correct just incomplete.

There are 54 items in the table, and each one looks sort of like this; only 25 
rows were returned the last few times I tried (I am not sure if it always stops 
at 25 or not):

          
'1.13.51.56.46.49.52.48.46.49.51.52.46.49.56.1.11.53.48.46.50.52.49.46.50.46.55.55.500.25126'
 => {
                                                                                
                             'cikePeerCorrIntIndex' => '500',
                                                                                
                             'cikePeerCorrRemoteValue' => '50.xxx.xxx.77',
                                                                                
                             'cikePeerCorrRemoteType' => '1',
                                                                                
                             'cikePeerCorrSeqNum' => '25126',
                                                                                
                             'cikePeerCorrIpSecTunIndex' => '25126',
                                                                                
                             'cikePeerCorrLocalValue' => '38.xxx.xxx.18',
                                                                                
                             'cikePeerCorrLocalType' => '1'
                                                                                
                           },

The Cisco device is fairly new and on a high speed LAN; snmpwalk returns data 
very quickly, so I do not think this is some kind of timeout issue or anything 
related to packet fragmentation.  I am pulling a lot of data from it via zabbix 
and all those queries work fine.

Any ideas why it will not return all values?

Linwood


------------------------------------------------------------------------------
What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic
patterns at an interface-level. Reveals which users, apps, and protocols are 
consuming the most bandwidth. Provides multi-vendor support for NetFlow, 
J-Flow, sFlow and other flows. Make informed decisions using capacity 
planning reports. https://ad.doubleclick.net/ddm/clk/305295220;132659582;e
_______________________________________________
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