Package: dns2tcp
Version: 0.5.2-1
Severity: minor
Tags: patch
--- Please enter the report below this line. ---
Hi,
dns2tcpd have a select within an infinite main loop that have a 500ms
timeout. This generates 6% of the wakeup events on my server which also
runs nginx, apache, nsd3 and dovecot among others. But when idling,
dns2tcp should do nothing.
The provided patch removes the timeout. It may not be the better fix,
but for my small use, it is perfect.
Adrien
--- System information. ---
Architecture: i386
Kernel: Linux 3.0.0-1-686-pae
Debian Release: wheezy/sid
500 unstable ftp.fr.debian.org
1 experimental ftp.fr.debian.org
--- Package information. ---
Package's Depends field is empty.
Package's Recommends field is empty.
Package's Suggests field is empty.
Index: dns2tcp-0.5.2/server/server.c
===================================================================
--- dns2tcp-0.5.2.orig/server/server.c 2011-09-03 14:37:33.843396649 +0200
+++ dns2tcp-0.5.2/server/server.c 2011-09-03 14:38:02.003590049 +0200
@@ -155,7 +155,7 @@
while (1)
{
max_fd = prepare_select(conf, &rfds, &tv);
- retval = select(max_fd + 1 , &rfds, NULL, NULL, &tv);
+ retval = select(max_fd + 1 , &rfds, NULL, NULL, NULL);
queue_flush_expired_data(conf);
if (retval == -1)
{