Subject: Re: Netbsd as default-free router
To: None <>
From: Michael Richardson <>
List: tech-net
Date: 08/21/2002 22:37:29

>>>>> "itojun" == itojun  <> writes:
    >> Stupid question... how can I find out how much memory is in use for
    >> the routing table(s)?
    >> With a full dump, (110k routes), I get a crash with 64Mb of memory.  I
    >> am rebuilding with NMBCLUSTERS=2048 now, but want to verify what is
    >> up.  With 27K routes for prefixes larger than /21 only, it seems
    >> stable.  { ip prefix-list slash19 seq 10 deny ge 21 }

    itojun> routing entries are not on mbufs.  see vmstat output, "routetbl"
    itojun> entry.

  Hmm. I've never used "vmstat -m" before.
  A shame that I can't use it like:
     vmstat -m routetbl -w 5 
  to monitor that value...

On a 64M physical ram machine, I have a 25Mb bgpd process:

14019 root       2    0    25M   20M sleep     0:36  0.68%  0.68% bgpd

(plus a 25Mb zebra process)

Memory statistics by type                        Type  Kern
         Type  InUse MemUse HighUse  Limit Requests Limit Limit Size(s)
     routetbl 110869  3356K   3356K 19661K   214667    0     0  16,32,64,128,256 show ip bgp summary
BGP router identifier, local AS number 26227
16444 BGP AS-PATH entries
0 BGP community entries

Neighbor        V    AS MsgRcvd MsgSent   TblVer  InQ OutQ Up/Down  State/PfxRcd    4 21936   40276       9        0    0    0 00:06:03   103285
                4   818       0       0        0    0    0 00:01:33 Active     

I adjusted the NKMEMPAGES to be 8192. It was 4072 on the 64Mb machine.
This is a 5 port router. It currently also has squid and named, but squid, at
least, will get removed.

]       ON HUMILITY: to err is human. To moo, bovine.           |  firewalls  [
]   Michael Richardson, Sandelman Software Works, Ottawa, ON    |net architect[
] |device driver[
] panic("Just another Debian GNU/Linux using, kernel hacking, security guy"); [

Version: 2.6.3ia
Charset: latin1
Comment: Finger me for keys