UDP packet loss

JINMEI Tatuya / 神明達哉 jinmei at isl.rdc.toshiba.co.jp
Tue Jun 13 07:08:16 UTC 2006

>>>>> On Sat, 10 Jun 2006 11:04:06 +0200, 
>>>>> Pavel Urban <urbanp at mlp.cz> said:

>>> I've tried to find out the cause of some strange resolving problem we 
>>> are experiencing. From time to time, our server seems to ignore some 
>>> requests, while others are answered promptly. It seems to me that the 
>>> problem is UDP packet loss.
>>> I've tried to increase system udp receive buffer 10x and then 100x with 
>>> no noticable effect. Do I have to change something in Bind, too? Or am I 
>>> completely wrong?
>>> RedHat Linux ES release 4, 2.6.9-34.ELsmp kernel, dual Opteron system 
>>> with 6GB ram, no local zones, just resolver/cache. bind-9.3.2-2_EL4
>> A quick question: did you enable threads?

> As far as I know, RedHat's packages are compiled with threads enabled. 
> This server is quite busy, about 4MBit of DNS traffic for hours...

Okay, if it did not enable threads, and if you mean 'about every hour'
or something by 'from time to time', then the described symptom would
probably be query packet loss in the socket receive buffer during
periodic cache cleaning.  In this case, enlarging the socket buffer
may not help, depending on the query arrival rate and the workload of

Some know workaround is:

- decreasing DNS_CACHE_CLEANERINCREMENT in lib/dns/cache.c
  (see http://marc.theaimsgroup.com/?l=bind-users&m=112643028426663&w=2)
- enabling ISC_MEM_USE_INTERNAL_MALLOC (see also the above URL).  It
  will reduce the workload of cleaning, and may implicitly remedy the
  packet lost issue.

As for the first tuning, it is better to try BIND 9.4 because it
automatically adjusts the corresponding parameter run-time so that
queries won't be dropped.

But if the server enables threads, it may be a different problem and
the above may not help because at least one thread can keep processing
queries during cache cleaning.

					JINMEI, Tatuya
					Communication Platform Lab.
					Corporate R&D Center, Toshiba Corp.
					jinmei at isl.rdc.toshiba.co.jp

More information about the bind-users mailing list