Using jails and djbdns
paco at paco.to
Fri May 13 05:40:32 PDT 2005
On Fri, 13 May 2005, Joan Picanyol i Puig wrote:
> * Tony Arcieri <tarcieri at atmos.colostate.edu> [20050513 03:21]:
> > Is there some easy way to reverse this order, so svscan is started first and
> > jails started afterward?
> Follow the author's instructions, and put this line into /etc/rc.local:
> csh -cf '/command/svscanboot &'
I don't think any of the suggestions so far are going to do it. The
reason is this: both /etc/rc.local and all things in /usr/local/etc/rc.d
will be executed after the builtin logid for launching jails is
The problem here is that if you use the standard /etc/rc.conf means for
launching jails, (take a look at /etc/defaults/rc.conf for an example),
the jail commands will be executed first. The last thing /etc/rc does is
invoke /etc/rc.local and all the /usr/local/etc/rc.d scripts. His problem
is that he needs DNS up *before* the jail commands run.
Here's a hackish way to do it that might work.
1. Move the /usr/local/etc/rc.d/svscan.sh script out of
/usr/local/etc/rc.d. Maybe put it in /usr/local/etc. Just put it
somewhere where it won't get executed automatically.
2. Put the following lines in /etc/rc.conf
named_program="/usr/local/etc/svscan.sh" # (if this is where you put it)
unset named_chrootdir # defeat some built-in BIND-oriented logic
unset named_chroot_autoupdate # ditto
The logic built into /etc/rc launches DNS before jails. By hijacking the
"named" flags and using them for DJB, you should be able to get DJB to
launch at the appropriate time.
More information about the freebsd-stable