Date: Sun, 20 Dec 2015 21:57:27 +0100 From: Michael Grimm <trashcan@ellael.org> To: freebsd-jail@freebsd.org, freebsd-questions <freebsd-questions@freebsd.org> Subject: Re: How to define the order of starting jails? Message-ID: <22ECAFEE-6EAF-4E67-A887-1E2D410A3DB6@ellael.org> In-Reply-To: <b538d6be51b83cf48e18f603ea1009a9@dweimer.net> References: <5D6BA0FE-60E1-4C6B-906B-BB62A1AB9BE8@odo.in-berlin.de> <1450639510.27618.8.camel@michaeleichorn.com> <b538d6be51b83cf48e18f603ea1009a9@dweimer.net>
next in thread | previous in thread | raw e-mail | index | archive | help
dweimer <dweimer@dweimer.net> wrote: > On 2015-12-20 1:25 pm, Michael B. Eichorn wrote: >> On Sun, 2015-12-20 at 17:50 +0100, Michael Grimm wrote: [starting sequence definition, how to?] >>> Thus, I might have overlooked it, is there a way to achieve my goal >>> using jail and jail.conf? >>> Or something else? >> jail(8)'s '*' operates on everything without concern for rc.conf, as >> such jail_list is not respected. Perhaps try something tied to the = rc.d >> system. Does `service jail restart` do what you are looking for? >> Otherwise I would just go with simple restart script such as: >> #!/bin/sh >> set -e >> jail -r '*' >> jail -c dns >> jail -c mail >=20 > You can also define a jail dependency to make sure a jail starts = before another one >=20 > dns { > ... > } > mail { > ... > depend =3D "dns" > } Yep! That is working as well. And, now it will stop jails in the reverse = order. *BUT*, that doesn't work with "jail -rc '*'", reproducibly =E2=80=A6=20 | testing> jail -rc '*' | ifconfig: : bad value | jail: dns: /sbin/ifconfig em0 inet netmask 255.255.255.255 @ = alias: failed =E2=80=A6 and leaving me with all stopped but not started a single jail = :-( "service jail restart" works much better, never failing. Thanks and with kind regards, Michael
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?22ECAFEE-6EAF-4E67-A887-1E2D410A3DB6>