Reindl Harald <[email protected]> wrote:
>
> > The problem that I alluded to above is that if you have services that
> > depend on the DNS, there should be a mechanism for the DNS server to say
> > when it is ready and that it's OK to start services that need DNS. I don't
> > know the right way to specify that to systemd: maybe it needs a socket
> > unit file as well?
>
> or just don't use "-f" and Type=forking
>
> https://www.freedesktop.org/software/systemd/man/systemd.service.html
>
> If set to forking, it is expected that the process configured with ExecStart=
> will call fork() as part of its start-up. The parent process is expected to
> exit when start-up is complete and all communication channels are set up.
BIND does not do that - it forks too early. It's a bit tiresome.
log_daemon_msg "Starting name server" "BIND"
start-stop-daemon --start --oknodo --pidfile $PIDFILE \
--name named --user named --group named \
--startas $TOP/bin/named \
-- -t $TOP -u named -c /etc/named.conf
i=$(( $? ? 100 : 0 ))
while [ $i -lt 100 ] &&
! rndc status >/dev/null 2>&1
do sleep 0.1
i=$((i+1))
done
chmod g+r $RUN/session.key
rndc status >/dev/null 2>&1
log_end_msg $?
Tony.
--
f.anthony.n.finch <[email protected]> http://dotat.at/ - I xn--zr8h punycode
Fair Isle, Faeroes: South or southwest 5 or 6, occasionally 7 later. Moderate
or rough, occasionally very rough. Rain or showers. Moderate or good,
occasionally poor.
_______________________________________________
Please visit https://lists.isc.org/mailman/listinfo/bind-users to unsubscribe
from this list
bind-users mailing list
[email protected]
https://lists.isc.org/mailman/listinfo/bind-users