Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #226139

Re: dns cache for localdomain via djbdns

From Greg Wooledge <wooledg@eeg.ccf.org>
Newsgroups linux.debian.user
Subject Re: dns cache for localdomain via djbdns
Date 2020-08-12 15:10 +0200
Message-ID <ACYFY-iA-7@gated-at.bofh.it> (permalink)
References <ACYFX-iA-5@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Wed, Aug 12, 2020 at 02:59:23PM +0200, Patrick Frank wrote:
> Hello,
> 
> on a Debian 10 host I created a virtual machine with very basic features
> to build a dns cache for my home network with djbdns. I fail to understand
> how Daemontools are used properly.
> 
> Following the instructions on http://cr.yp.to/djbdns/install.html went okay.
> http://cr.yp.to/djbdns/run-cache-x.html at step 5 is where I am stuck.
> 
> When I go to /service/dnscache and execute "run" it says "starting" so I
> try svstat /service/dnscache which outputs:
> "/service/dnscache: unable to open supervise/ok: file does not exist"

You can execute the "./run" script by hand for testing purposes, to
make sure you've written it correctly, but that's not how daemontools
will run it.  If your test is successful, you should Ctrl-C (or otherwise
terminate) the ./run script that you ran manually.  Make sure it dies.

You tell daemontools to run the service by creating a symbolic link
from the /service directory to the directory where the run script
lives.

For example:

unicorn:~$ ls -l /service
total 0
lrwxrwxrwx 1 root root 13 Jan 12  2018 dnscache -> /etc/dnscache/
lrwxrwxrwx 1 root root 39 Jan 12  2018 qmail-deliverabled -> /var/qmail/supervise/qmail-deliverabled/
lrwxrwxrwx 1 root root 31 Jan 12  2018 qmail-send -> /var/qmail/supervise/qmail-send/
lrwxrwxrwx 1 root root 28 Jan 12  2018 qpsmtpd -> /var/qmail/supervise/qpsmtpd/

unicorn:~$ ls -l /etc/dnscache/
total 24
drwxr-sr-x 2 root root 4096 Jan 12  2018 env/
drwxr-sr-x 4 root root 4096 Jan 12  2018 log/
drwxr-sr-x 4 root root 4096 Jan 12  2018 root/
-rwxr-xr-x 1 root root  142 Jan 12  2018 run*
-rw------- 1 root root  128 Jan 12  2018 seed
drwx--S--- 2 root root 4096 Aug  2 09:00 supervise/

The presence of the symlink /service/dnscache is picked up by svscan,
which launches a supervisor process.

Back to linux.debian.user | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

dns cache for localdomain via djbdns Patrick Frank <sfsoc@gmx.de> - 2020-08-12 15:10 +0200
  Re: dns cache for localdomain via djbdns Greg Wooledge <wooledg@eeg.ccf.org> - 2020-08-12 15:10 +0200
    Re: dns cache for localdomain via djbdns Dan Ritter <dsr@randomstring.org> - 2020-08-12 15:30 +0200
      Re: dns cache for localdomain via djbdns Greg Wooledge <wooledg@eeg.ccf.org> - 2020-08-12 16:00 +0200
      Re: dns cache for localdomain via djbdns Patrick Frank <sfsoc@gmx.de> - 2020-08-12 16:00 +0200
        Re: dns cache for localdomain via djbdns <tomas@tuxteam.de> - 2020-08-12 18:20 +0200

csiph-web