Re: How do I identify if bind9 is using 4 cores?
Hi Petr, this is a side effect of libuv threadpool which inherits the name of the “parent” thread (but then it’s shared between all of them). If you use gdb on the `named`, you’ll see that those extra threads are waiting for work in the uv threadpool: (gdb) bt #0 futex_wait_cancelable (private=0, expected=0, futex_word=0x7feaf147d22c ) at ../sysdeps/nptl/futex-internal.h:186 #1 __pthread_cond_wait_common (abstime=0x0, clockid=0, mutex=0x7feaf147d1c0 , cond=0x7feaf147d200 ) at pthread_cond_wait.c:508 #2 __pthread_cond_wait (cond=cond@entry=0x7feaf147d200 , mutex=mutex@entry=0x7feaf147d1c0 ) at pthread_cond_wait.c:638 #3 0x7feaf146ab19 in uv_cond_wait (cond=cond@entry=0x7feaf147d200 , mutex=mutex@entry=0x7feaf147d1c0 ) at ./src/unix/thread.c:780 #4 0x7feaf1458d4d in worker (arg=0x0) at ./src/threadpool.c:76 #5 0x7feaf1248ea7 in start_thread (arg=) at pthread_create.c:477 #6 0x7feaf114bdef in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95 Perhaps somebody might want to fill issue with the libuv, so it resets the internal thread names. Ondrej -- Ondřej Surý (He/Him) ond...@isc.org > On 5. 7. 2021, at 10:28, Petr Menšík wrote: > > Consult log of bind9 service. It should autodetect 4 cores without any > options, just with plain start of the service. > > It should show isc-socket thread for each core: > > pstree -t $(pidof named) > > I were surprised of my output however, because I have multiple > isc-net-000{1}. My version is bind-9.16.18-1.fc34.x86_64 > > $ pstree -t $(pidof named) > named─┬─2*[{isc-net-}] > ├─5*[{isc-net-0001}] > ├─{isc-net-0002} > ├─{isc-net-0003} > ├─{isc-socket-0} > ├─{isc-socket-1} > ├─{isc-socket-2} > ├─{isc-socket-3} > └─{isc-timer} > > Are those numbers intentional? > > On 6/17/21 5:32 AM, Manish Rane wrote: >> Hi Team, >> >> I have BIND 9.16.17-Ubuntu on ubuntu and have 4 cores. I have configured >> >> more /etc/default/bind9 >> OPTIONS="-n 4" >> >> And then restarted the services. How do I verify if bind9 has spawned 4 >> processes and distributed among those? >> >> TIA >> Manish R >> >> >> >> >> ___ >> Please visit >> https://lists.isc.org/mailman/listinfo/bind-users >> to unsubscribe from this list >> >> ISC funds the development of this software with paid support subscriptions. >> Contact us at >> https://www.isc.org/contact/ >> for more information. >> >> >> bind-users mailing list >> >> bind-users@lists.isc.org >> https://lists.isc.org/mailman/listinfo/bind-users > -- > Petr Menšík > Software Engineer > Red Hat, > http://www.redhat.com/ > > email: > pemen...@redhat.com > > PGP: DFCF908DB7C87E8E529925BC4931CA5B6C9FC5CB > > ___ > Please visit https://lists.isc.org/mailman/listinfo/bind-users to unsubscribe > from this list > > ISC funds the development of this software with paid support subscriptions. > Contact us at https://www.isc.org/contact/ for more information. > > > bind-users mailing list > bind-users@lists.isc.org > https://lists.isc.org/mailman/listinfo/bind-users ___ Please visit https://lists.isc.org/mailman/listinfo/bind-users to unsubscribe from this list ISC funds the development of this software with paid support subscriptions. Contact us at https://www.isc.org/contact/ for more information. bind-users mailing list bind-users@lists.isc.org https://lists.isc.org/mailman/listinfo/bind-users
Re: How do I identify if bind9 is using 4 cores?
Consult log of bind9 service. It should autodetect 4 cores without any options, just with plain start of the service. It should show isc-socket thread for each core: pstree -t $(pidof named) I were surprised of my output however, because I have multiple isc-net-000{1}. My version is bind-9.16.18-1.fc34.x86_64 $ pstree -t $(pidof named) named─┬─2*[{isc-net-}] ├─5*[{isc-net-0001}] ├─{isc-net-0002} ├─{isc-net-0003} ├─{isc-socket-0} ├─{isc-socket-1} ├─{isc-socket-2} ├─{isc-socket-3} └─{isc-timer} Are those numbers intentional? On 6/17/21 5:32 AM, Manish Rane wrote: > Hi Team, > > I have BIND 9.16.17-Ubuntu on ubuntu and have 4 cores. I have configured > > more /etc/default/bind9 > OPTIONS="-n 4" > > And then restarted the services. How do I verify if bind9 has spawned 4 > processes and distributed among those? > > TIA > Manish R > > > ___ > Please visit https://lists.isc.org/mailman/listinfo/bind-users to unsubscribe > from this list > > ISC funds the development of this software with paid support subscriptions. > Contact us at https://www.isc.org/contact/ for more information. > > > bind-users mailing list > bind-users@lists.isc.org > https://lists.isc.org/mailman/listinfo/bind-users -- Petr Menšík Software Engineer Red Hat, http://www.redhat.com/ email: pemen...@redhat.com PGP: DFCF908DB7C87E8E529925BC4931CA5B6C9FC5CB ___ Please visit https://lists.isc.org/mailman/listinfo/bind-users to unsubscribe from this list ISC funds the development of this software with paid support subscriptions. Contact us at https://www.isc.org/contact/ for more information. bind-users mailing list bind-users@lists.isc.org https://lists.isc.org/mailman/listinfo/bind-users
Re: How do I identify if bind9 is using 4 cores?
Great - Thanks for the help -- Thanks and Regards, Manish R On Fri, Jun 18, 2021 at 1:44 AM Dennis Clarke via bind-users < bind-users@lists.isc.org> wrote: > On 6/17/21 03:47, Manish Rane wrote: > > Does this mean and I can assume that bind has started with 4 cores? > > > > CGroup: /system.slice/named.service > >`-3150 /usr/sbin/named -f -u bind -n 4 > > > -- > > Thanks and Regards, > > Manish R > > > > You may be able to ask with rndc : > > # > # /usr/local/sbin/rndc -s 127.0.0.1 \ > > -k /etc/opt/isc/named/rndc.key \ > > -p 953 status 2>&1 | grep 'threads' > worker threads: 1 > # > > > -- > Dennis Clarke > RISC-V/SPARC/PPC/ARM/CISC > UNIX and Linux spoken > GreyBeard and suspenders optional > ___ > Please visit https://lists.isc.org/mailman/listinfo/bind-users to > unsubscribe from this list > > ISC funds the development of this software with paid support > subscriptions. Contact us at https://www.isc.org/contact/ for more > information. > > > bind-users mailing list > bind-users@lists.isc.org > https://lists.isc.org/mailman/listinfo/bind-users > ___ Please visit https://lists.isc.org/mailman/listinfo/bind-users to unsubscribe from this list ISC funds the development of this software with paid support subscriptions. Contact us at https://www.isc.org/contact/ for more information. bind-users mailing list bind-users@lists.isc.org https://lists.isc.org/mailman/listinfo/bind-users
Re: How do I identify if bind9 is using 4 cores?
On 6/17/21 03:47, Manish Rane wrote: > Does this mean and I can assume that bind has started with 4 cores? > > CGroup: /system.slice/named.service >`-3150 /usr/sbin/named -f -u bind -n 4 > -- > Thanks and Regards, > Manish R > You may be able to ask with rndc : # # /usr/local/sbin/rndc -s 127.0.0.1 \ > -k /etc/opt/isc/named/rndc.key \ > -p 953 status 2>&1 | grep 'threads' worker threads: 1 # -- Dennis Clarke RISC-V/SPARC/PPC/ARM/CISC UNIX and Linux spoken GreyBeard and suspenders optional ___ Please visit https://lists.isc.org/mailman/listinfo/bind-users to unsubscribe from this list ISC funds the development of this software with paid support subscriptions. Contact us at https://www.isc.org/contact/ for more information. bind-users mailing list bind-users@lists.isc.org https://lists.isc.org/mailman/listinfo/bind-users
Re: How do I identify if bind9 is using 4 cores?
Am 17.06.21 um 05:32 schrieb Manish Rane: Hi Team, I have BIND 9.16.17-Ubuntu on ubuntu and have 4 cores. I have configured more /etc/default/bind9 OPTIONS="-n 4" And then restarted the services. How do I verify if bind9 has spawned 4 processes and distributed among those? it's threaded, so no processes and to verify just read your syslogs at restart/start of the service Jun 17 11:59:58 srv-rhsoft named[241354]: found 8 CPUs, using 8 worker threads Jun 17 11:59:58 srv-rhsoft named[241354]: using 7 UDP listeners per interface Jun 17 11:59:58 srv-rhsoft named[241354]: using up to 21000 sockets ___ Please visit https://lists.isc.org/mailman/listinfo/bind-users to unsubscribe from this list ISC funds the development of this software with paid support subscriptions. Contact us at https://www.isc.org/contact/ for more information. bind-users mailing list bind-users@lists.isc.org https://lists.isc.org/mailman/listinfo/bind-users
Re: How do I identify if bind9 is using 4 cores?
Oh - Thanks for the help. -- Thanks and Regards, Manish R On Thu, Jun 17, 2021 at 1:59 PM Anand Buddhdev wrote: > On 17/06/2021 05:32, Manish Rane wrote: > > Hi Manish, > > > I have BIND 9.16.17-Ubuntu on ubuntu and have 4 cores. I have configured > > > > more /etc/default/bind9 > > OPTIONS="-n 4" > > > > And then restarted the services. How do I verify if bind9 has spawned 4 > > processes and distributed among those? > > BIND does not start multiple processes. There's only ever one process, > called "named". BIND starts multiple threads. You can see these by using > the "top" command in Linux, and then pressing "H" to see threads rather > than processes. You should see 4 worker threads, as well as some other > threads. > > Regards, > Anand > ___ > Please visit https://lists.isc.org/mailman/listinfo/bind-users to > unsubscribe from this list > > ISC funds the development of this software with paid support > subscriptions. Contact us at https://www.isc.org/contact/ for more > information. > > > bind-users mailing list > bind-users@lists.isc.org > https://lists.isc.org/mailman/listinfo/bind-users > ___ Please visit https://lists.isc.org/mailman/listinfo/bind-users to unsubscribe from this list ISC funds the development of this software with paid support subscriptions. Contact us at https://www.isc.org/contact/ for more information. bind-users mailing list bind-users@lists.isc.org https://lists.isc.org/mailman/listinfo/bind-users
Re: How do I identify if bind9 is using 4 cores?
On 17/06/2021 05:32, Manish Rane wrote: Hi Manish, > I have BIND 9.16.17-Ubuntu on ubuntu and have 4 cores. I have configured > > more /etc/default/bind9 > OPTIONS="-n 4" > > And then restarted the services. How do I verify if bind9 has spawned 4 > processes and distributed among those? BIND does not start multiple processes. There's only ever one process, called "named". BIND starts multiple threads. You can see these by using the "top" command in Linux, and then pressing "H" to see threads rather than processes. You should see 4 worker threads, as well as some other threads. Regards, Anand ___ Please visit https://lists.isc.org/mailman/listinfo/bind-users to unsubscribe from this list ISC funds the development of this software with paid support subscriptions. Contact us at https://www.isc.org/contact/ for more information. bind-users mailing list bind-users@lists.isc.org https://lists.isc.org/mailman/listinfo/bind-users
Re: How do I identify if bind9 is using 4 cores?
Does this mean and I can assume that bind has started with 4 cores? CGroup: /system.slice/named.service `-3150 /usr/sbin/named -f -u bind -n 4 -- Thanks and Regards, Manish R On Thu, Jun 17, 2021 at 9:02 AM Manish Rane wrote: > Hi Team, > > I have BIND 9.16.17-Ubuntu on ubuntu and have 4 cores. I have configured > > more /etc/default/bind9 > OPTIONS="-n 4" > > And then restarted the services. How do I verify if bind9 has spawned 4 > processes and distributed among those? > > TIA > Manish R > ___ Please visit https://lists.isc.org/mailman/listinfo/bind-users to unsubscribe from this list ISC funds the development of this software with paid support subscriptions. Contact us at https://www.isc.org/contact/ for more information. bind-users mailing list bind-users@lists.isc.org https://lists.isc.org/mailman/listinfo/bind-users