FreeBSD 4.8, BIND 9.2.2 out of memory

phn at icke-reklam.ipsec.nu phn at icke-reklam.ipsec.nu
Tue Aug 12 05:29:26 UTC 2003


Mark_Andrews at isc.org wrote:

>> Hello,
>> 
>> Running BIND 9.2.2 chroot'ed on FreeBSD 4.8, I receive these errors
>> occasionally:
>> 
>> Aug 11 10:51:17.439 loading configuration from '/etc/named.conf'
>> Aug 11 10:51:17.585 dns_master_load: out of memory
>> Aug 11 10:51:17.586 could not configure root hints from
>> 'master/named.root': out of memory
>> Aug 11 10:51:22.914 reloading configuration failed: out of memory
>> 
>> Here is ps -auxwww:
>> USER    PID %CPU %MEM   VSZ  RSS  TT  STAT STARTED      TIME COMMAND
>> bind     74 12.4 50.6 527776 527064  ??  Ss    3Aug03 1318:00.92
>> /usr/sbin/named -u bind -t /var/named -c etc/named.conf
>> root      1  0.0  0.0   552  200  ??  ILs   3Aug03   0:00.01
>> /sbin/init --
>> root      2  0.0  0.0     0    0  ??  DL    3Aug03   0:01.70 
>> (pagedaemon)
>> root      3  0.0  0.0     0    0  ??  DL    3Aug03   0:00.00 
>> (vmdaemon)
>> root      4  0.0  0.0     0    0  ??  DL    3Aug03   0:04.48 
>> (bufdaemon)
>> root      5  0.0  0.0     0    0  ??  DL    3Aug03   3:02.51  (syncer)
>> root      6  0.0  0.0     0    0  ??  DL    3Aug03   0:04.12  (vnlru)
>> root     23  0.0  0.0   212   68  ??  Is    3Aug03   0:00.00 adjkerntz
>> -i
>> root     71  0.0  0.1   948  564  ??  Ss    3Aug03   0:01.97
>> /usr/sbin/syslogd -b 10.0.99.17
>> root     80  0.0  0.1  1024  636  ??  Ss    3Aug03   0:01.32
>> /usr/sbin/cron
>> root     82  0.0  0.1  2592 1240  ??  Is    3Aug03   0:03.12
>> /usr/sbin/sshd
>> root    107  0.0  0.1  2592 1184  ??  Is    3Aug03   0:00.06
>> /usr/sbin/sshd-named -f /etc/ssh/sshd_config_named
>> root    110  0.0  0.1   952  528  v0  Is+   3Aug03   0:00.00
>> /usr/libexec/getty Pc ttyv0
>> root    112  0.0  0.1   952  528  v2  Is+   3Aug03   0:00.00
>> /usr/libexec/getty Pc ttyv2
>> root    113  0.0  0.1   952  528  v3  Is+   3Aug03   0:00.00
>> /usr/libexec/getty Pc ttyv3
>> root    114  0.0  0.1   952  528  v4  Is+   3Aug03   0:00.00
>> /usr/libexec/getty Pc ttyv4
>> root    115  0.0  0.1   952  528  v5  Is+   3Aug03   0:00.00
>> /usr/libexec/getty Pc ttyv5
>> root    116  0.0  0.1   952  528  v6  Is+   3Aug03   0:00.00
>> /usr/libexec/getty Pc ttyv6
>> root    117  0.0  0.1   952  528  v7  Is+   3Aug03   0:00.00
>> /usr/libexec/getty Pc ttyv7
>> root    147  0.0  0.1   952  528  v1  Is+   3Aug03   0:00.00
>> /usr/libexec/getty Pc ttyv1
>> root   6376  0.0  0.2  3052 2016  ??  Ss   Tue01PM   0:10.95 sendmail:
>> accepting connections (sendmail)
>> smmsp  6381  0.0  0.2  2928 1940  ??  Is   Tue01PM   0:00.17 sendmail:
>> Queue runner at 00:30:00 for /var/spool/clientmqueue (sendmail)
>> root  17072  0.0  0.2  5292 1748  ??  I    10:49AM   0:00.02 sshd:
>> kimo [priv] (sshd)
>> kimo  17074  0.0  0.2  5292 1784  ??  S    10:49AM   0:00.08 sshd:
>> kimo at ttyp0,ttyp1 (sshd)
>> kimo  17075  0.0  0.1  1076  740  p0  Is   10:49AM   0:00.01 -bash
>> (bash)
>> kimo  17078  0.0  0.1  1076  748  p1  Ss   10:49AM   0:00.02 -bash
>> (bash)
>> kimo  17095  0.0  0.0   900  384  p0  S+   10:52AM   0:00.00 tail -f
>> /var/named/log/named.log
>> root      0  0.0  0.0     0    0  ??  DLs   3Aug03   0:00.00 
>> (swapper)
>> kimo  17111  0.0  0.0   416  224  p1  R+   10:59AM   0:00.00 ps
>> -auxwww
>> 
>> 
>> Here is top:
>> 
>> last pid: 17126;  load averages:  0.14,  0.15,  0.14                  
>>                                                               up
>> 7+22:33:03  11:06:56
>> 22 processes:  1 running, 21 sleeping
>> CPU states: 12.5% user,  0.0% nice,  2.3% system,  0.0% interrupt,
>> 85.2% idle
>> Mem: 525M Active, 291M Inact, 144M Wired, 38M Cache, 111M Buf, 1660K
>> Free
>> Swap: 1024M Total, 24K Used, 1024M Free
>> 
>>   PID USERNAME PRI NICE  SIZE    RES STATE    TIME   WCPU    CPU
>> COMMAND
>>    74 bind       2   0   515M   515M select  22.0H 12.60% 12.60% named
>>  6376 root       2   0  3052K  2016K select   0:11  0.00%  0.00%
>> sendmail
>>    82 root       2   0  2592K  1240K select   0:03  0.00%  0.00% sshd
>>    71 root       2   0   948K   564K select   0:02  0.00%  0.00%
>> syslogd
>>    80 root      10   0  1024K   636K nanslp   0:01  0.00%  0.00% cron
>>  6381 smmsp     18   0  2928K  1940K pause    0:00  0.00%  0.00%
>> sendmail
>> 17074 kimo       2   0  5292K  1784K select   0:00  0.00%  0.00% sshd
>> 17126 kimo      28   0  1900K  1060K RUN      0:00  0.00%  0.00% top
>>   107 root       2   0  2592K  1184K select   0:00  0.00%  0.00%
>> sshd-named
>> 17078 kimo      10   0  1076K   748K wait     0:00  0.00%  0.00% bash
>> 17072 root       2   0  5292K  1748K sbwait   0:00  0.00%  0.00% sshd
>> 17075 kimo      10   0  1076K   740K wait     0:00  0.00%  0.00% bash
>> 17095 kimo       2   0   900K   384K kqread   0:00  0.00%  0.00% tail
>>   110 root       3   0   952K   528K ttyin    0:00  0.00%  0.00% getty
>>   113 root       3   0   952K   528K ttyin    0:00  0.00%  0.00% getty
>>   147 root       3   0   952K   528K ttyin    0:00  0.00%  0.00% getty
>> 
>> 
>> Any ideas or suggestions? datasize in /etc/login.conf is set to
>> unlimited.

> 	Memory is *always* limited.  "unlimited" just means that
> 	that the process will get as much memory as the system can
> 	offer.

> 	Set max-cache-size.
> 	Adjust the cache retention times downwards (max-cache-ttl /
> 	max-ncache-ttl).
> 	Get more memory. 
> 	Split the authoritative / recursive loads.
> 	
>> Thanks
>> Kimo
>> 
> --
> Mark Andrews, Internet Software Consortium
> 1 Seymour St., Dundas Valley, NSW 2117, Australia
> PHONE: +61 2 9871 4742                 INTERNET: Mark.Andrews at isc.org

The machine in question has free memory, still bind is denied more then 512M

I _think_ some tuning of login.conf and, possibly a new kernel with
adjusted values should help. I would myself contact FreeBSD support team 
to resolve this.


-- 
Peter Håkanson         
        IPSec  Sverige      ( At Gothenburg Riverside )
           Sorry about my e-mail address, but i'm trying to keep spam out,
	   remove "icke-reklam" if you feel for mailing me. Thanx.


More information about the bind-users mailing list