Re: bopm memory leak?

Erik Fears <[email protected]> Tue, 22 Jan 2008 20:54:59 -0800
Newsgroups gmane.network.irc.bopm
Message-ID <[email protected]>
> Hey all,
> 
> I'm seeing what looks like a memory leak on my bopm. It's not an
> overused bopm, but the memory image tends to grow without bound. I've
> seen the process grow to exceed >200MB. I kill the process once day or
> so to clean it up.
> 
>   PID USERNAME  THR PRI NICE   SIZE    RES STATE    TIME   WCPU COMMAND
> 65225 esper       1  96    0 19488K 17944K select   0:21  0.00% bopm
> 
> The host is FreeBSD 7.0-RC1, though many of our other bopms are
> reporting high memory usage.
> 
> We're using version 3.1.3, and at the time of this writing, the bopm
> had been up for just over 5 hours.
> 
> 21:16 < eri> yeti stat
> 21:16 <+Yeti> Uptime: 5 hours, 13 minutes, 43 seconds
> 21:16 <+Yeti> DNSBL: 4 successful lookups from dnsbl.sorbs.net
> 21:16 <+Yeti> DNSBL: 3 successful lookups from rbl.efnet.org
> 21:16 <+Yeti> DNSBL: 3 successful lookups from dnsbl.ahbl.org
> 21:16 <+Yeti> Number of connects: 731 (2.33/minute)
> 
> Our config has a few DNS blacklists: rbl.efnet.org, SORBS, AHBL, and
> one for Tor. The dns_fdlimit = 64. Our scanner scans for some 150
> ports or so (it's grown rather organically, it might be time to scale
> those back a bit ;-)). fd = 64, max_read = 4096, timeout = 30 for the
> default scanners.
> 
> Yeti doesn't report much in fdstat:
> 21:20 <+Yeti> Total open FD: 2/7207
> 
> Does anyone have an ideas? We've poked around the source a bit without
> much luck. We'd appreciate any insight :-)
> 
> Greets,
> -eri
>

Never seen this. BOPM's source really hasn't changed in years, and
there's bopms running for months on networks with very high load.

Your particular config might be excercising a unique codepath. You might
want to try debugging with valgrind, if you have a bopm that's having
this issue on linux.

What's more bizarre is that it's difficult to imagine 200 MB of
allocations for just 700 connections.

-erik