Re: get interfaces OID takes a second

"Sangsu Baek" <[email protected]>
Newsgroups gmane.network.net-snmp.user
Message-ID <001601c711de$e5b36660$0d01a8c0@LocalHost>
Thank you Dave for your reply.

I found why snmpwalk on 'interfaces' so slow in linux.
Maybe many users already know it !

agent/mibgroup/mibII/interfaces.c

Interface_Scan_Init() has some code to disallow reloading interfaces

    gettimeofday ( &et, ( struct timezone * ) 0 );  /*  get time-of-day */
    if ( et.tv_sec < LastLoad + MINLOADFREQ ) {     /*  only reload so often */
      ifnetaddr = ifnetaddr_list;                   /*  initialize pointer */
      return;
    }
    LastLoad = et.tv_sec;

MINLOADFREQ  is 0 by default.

so i've set 
#define MINLOADFREQ  5

and result is nice snmpwalk !

I think this tip may give some help to (net-snmp) newbie like me.

thanks


Sangsu Baek








----- Original Message ----- 
From: "Sangsu Baek" <[email protected]>
To: "uclinux-dev" <[email protected]>; <[email protected]>
Sent: Friday, November 24, 2006 3:05 PM
Subject: get interfaces OID takes a second


> [I'm sorry, This mail was cross posted]
> 
> Hi.   I'm using net-snmp 5.2.1 on IXP425 ( kernel ver 2.6.12-uc0 ). 
> snmp agent works good. but when i get information on 'interfaces' , 
> it works but very slow response ( about 1 sec per each OID) or even timeout.
> Other mib OID ( system, ip, tcp, udp )  works great .
> Below is my snmpd.conf
> 
> thanks
> 
> 2006.11.24
> Sangsu Baek
> 
> 
> 
> snmpd.conf
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> com2sec rwAccess  default         private
> com2sec roAccess  default         public
> 
> group rwGroup   v1         rwAccess
> group rwGroup   v2c        rwAccess
> group rwGroup   usm        rwAccess
> group roGroup   v1         roAccess
> group roGroup   v2c        roAccess
> group roGroup   usm        roAccess
> 
> view all    included  .1                               80
> 
> access roGroup   ""      any       noauth    exact  all    none   none
> access rwGroup   ""      any       noauth    exact  all    all    none
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> 
> //
> 
> -------------------------------------------------------------------------
> Take Surveys. Earn Cash. Influence the Future of IT
> Join SourceForge.net's Techsay panel and you'll get the chance to share your
> opinions on IT & business topics through brief surveys - and earn cash
> http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
> _______________________________________________
> 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
>
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
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.