For builtin-select: 512/960, for libevent 1024/4096 and for
windows 24/48 (because of win api). This makes the ratio this way
to improve resilience under heavy load. For high performance, use
libevent and possibly higher numbers.
git-svn-id: file:///svn/unbound/trunk@2191
be551aaa-1e26-0410-a405-
d3ace91eadb9
+12 July 2010: Wouter
+ - Changed the defaults for num-queries-per-thread/outgoing-range.
+ For builtin-select: 512/960, for libevent 1024/4096 and for
+ windows 24/48 (because of win api). This makes the ratio this way
+ to improve resilience under heavy load. For high performance, use
+ libevent and possibly higher numbers.
+
10 July 2010: Wouter
- GOST enabled if SSL is recent and ldns has GOST enabled too.
- ldns tarball updated.
# outgoing-interface: 2001:DB8::6
# number of ports to allocate per thread, determines the size of the
- # port range that can be open simultaneously.
- # outgoing-range: 256
+ # port range that can be open simultaneously. About double the
+ # num-queries-per-thread, or, use as many as the OS will allow you.
+ # outgoing-range: 4096
# permit unbound to use this port number or port range for
# making outgoing queries, using an outgoing interface.
.TP
.B outgoing\-range: \fI<number>
Number of ports to open. This number of file descriptors can be opened per
-thread. Must be at least 1. Default is 256. Larger numbers need extra
-resources from the operating system.
+thread. Must be at least 1. Default depends on compile options. Larger
+numbers need extra resources from the operating system. For performance a
+a very large value is best, use libevent to make this possible.
.TP
.B outgoing\-port\-permit: \fI<port number or range>
Permit unbound to open this port or range of ports for use to send queries.
If more queries arrive that need servicing, and no queries can be jostled out
(see \fIjostle\-timeout\fR), then the queries are dropped. This forces
the client to resend after a timeout; allowing the server time to work on
-the existing queries. Default 1024.
+the existing queries. Default depends on compile options, 512 or 1024.
.TP
.B jostle\-timeout: \fI<msec>
Timeout used when the server is very busy. Set to a value that usually
num\-threads: 1
outgoing\-num\-tcp: 1 # this limits TCP service, uses less buffers.
incoming\-num\-tcp: 1
- outgoing\-range: 16 # uses less memory, but less performance.
+ outgoing\-range: 60 # uses less memory, but less performance.
msg\-buffer\-size: 8192 # note this limits service, 'no huge stuff'.
msg\-cache\-size: 100k
msg\-cache\-slabs: 1
cfg->use_syslog = 1;
cfg->log_time_ascii = 0;
#ifndef USE_WINSOCK
- cfg->outgoing_num_ports = 256;
+# ifdef USE_MINI_EVENT
+ /* select max 1024 sockets */
+ cfg->outgoing_num_ports = 960;
+ cfg->num_queries_per_thread = 512;
+# else
+ /* libevent can use many sockets */
+ cfg->outgoing_num_ports = 4096;
+ cfg->num_queries_per_thread = 1024;
+# endif
cfg->outgoing_num_tcp = 10;
cfg->incoming_num_tcp = 10;
#else
cfg->outgoing_num_ports = 48; /* windows is limited in num fds */
+ cfg->num_queries_per_thread = 24;
cfg->outgoing_num_tcp = 2; /* leaves 64-52=12 for: 4if,1stop,thread4 */
cfg->incoming_num_tcp = 2;
#endif
cfg->msg_buffer_size = 65552; /* 64 k + a small margin */
cfg->msg_cache_size = 4 * 1024 * 1024;
cfg->msg_cache_slabs = 4;
- cfg->num_queries_per_thread = 1024;
cfg->jostle_time = 200;
cfg->rrset_cache_size = 4 * 1024 * 1024;
cfg->rrset_cache_slabs = 4;