Maintained by: NLnet Labs

Unbound swapping

Eduardo Schoedler
Tue Sep 12 01:28:14 CEST 2017


I'm trying to understand why unbound is swapping ~900MB:

root at dns:~# top -b -n 1 | grep "SWAP\|unbound"
  PID USER      PR  NI    VIRT    RES    SHR S  %CPU %MEM     TIME+
SWAP COMMAND
11991 unbound   20   0 9751036 8.189g   3824 S  81.2 69.9   3192:03
840364 unbound


root at dns:~# cat /etc/unbound/unbound.conf | grep '\-size'
        ratelimit-size: 16m
    rrset-cache-size: 1536m
    msg-cache-size: 768m

This configuration doesn't hurt the "2.5x" tip from documentation.

root at dns:~# free -m
              total        used        free      shared  buff/cache   available
Mem:          12004        8814        1296         237        1893        1449
Swap:          3395         907        2488

root at dns:~# unbound-control stats_noreset | grep mem
mem.cache.rrset=110262793
mem.cache.message=92861937
mem.mod.iterator=16548
mem.mod.validator=5767649
mem.mod.respip=0
mem.mod.subnet=872423102

root at dns:~# unbound-control stats_noreset | grep time
time.now=1505172298.707575
time.up=265711.841724
time.elapsed=279.009376

root at dns:~# sysctl vm.swappiness
vm.swappiness = 10

Some clue?

Thank you.


Regards,

-- 
Eduardo Schoedler