Hello knot,

I have recently started a long over due migration to knot 2.* and I have 
noticed that the server.workers config stanza is now split into three separate 
stanzas [server.tcp-workers, server.udp-workers & server.background-workers].  
Although this is great for flexibility it does make automation a little bit 
more difficult.  With the 1.6 configuration I could easily say something like 
the following

workers = $server_cpu_count - 2

This meant I would always have 2 cpu cores available for other processes e.g. 
doc, tcpdump.  With the new configuration I would need to do something like the 
following

$avalible_workers = $server_cpu_count - 2
$udp_workers = $avalible_workers * 0.6
$tcp_workers = $avalible_workers * 0.3
$background_workers = $avalible_workers * 0.1

The above code is lacking error detection and rounding corrections which will 
add further complexity and potentially lacking itelagence that is available in 
knot to better balance resources.  As you have already implemented logic in 
knot to ensure cpus are correctly balanced I wonder if you could add back a 
workers configurations to act as the upper bound used in the *-workers 
configuration.  Such that 

        *-workes defaults:
        "Default: auto-estimated optimal value based on the number of online 
CPUs or the value set by `workers` which ever is lower)

Thanks

John
_______________________________________________
knot-dns-users mailing list
knot-dns-users@lists.nic.cz
https://lists.nic.cz/cgi-bin/mailman/listinfo/knot-dns-users

Reply via email to