• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

chroot bind var/named/dev mounted twice and init script's stop hanging

fwyKKCkQze2z

Member

Thanks: 1
Messages: 28

#1
Hi

I am running bind in a chroot'ed environment on a FreeBSD 11 system.

# pkg version | grep bind
bind910-9.10.6

For some unknown reason, I sometimes see /var/named/dev mounted twice. This seems often (always?) to be the case after a reboot. Unfortunately this is a production system, so I cannot reboot it at will to test.

Code:
# mount -v
....
devfs on /var/named/dev (devfs, local, multilabel, fsid 04ff007171000000)
devfs on /var/named/dev (devfs, local, multilabel, fsid 05ff007171000000)
Whenever this happens, stopping named via /usr/local/etc/rc.d/named restart fails (the command hangs forever); but I can only find one /usr/local/sbin/named -t /var/named process.

It seems that DNS resolution is working just fine anyway.

Once I kill the one process I find, one of the mounts is gone. After umounting the remaining one and restarting named ( /usr/local/etc/rc.d/named start works just fine then), everything seems to be OK/as expected again.

Here is an excerpt from my /etc/rc.conf:
Code:
named_enable="yes"
named_chrootdir="/var/named"
Is someone able to shed some light onto the question why this might be happening?
 

SirDice

Administrator
Staff member
Administrator
Moderator

Thanks: 5,508
Messages: 25,688

#2
Is someone able to shed some light onto the question why this might be happening?
The only thing I can think off is a failed restart. For some reason it may have failed to shutdown completely and then started again causing devfs(5) to be mounted twice.