Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 30 Aug 2015 16:11:02 -0400
From:      Ricky G <ricky1252@hotmail.com>
To:        "dweimer@dweimer.net" <dweimer@dweimer.net>
Cc:        "freebsd-questions@freebsd.org" <freebsd-questions@freebsd.org>
Subject:   RE: Jail not starting at Boot
Message-ID:  <SNT146-W5149D2CA9F8D9792C6F1A0A16C0@phx.gbl>
In-Reply-To: <4437010e968d156ec6087a56bc334b40@dweimer.net>
References:  <4437010e968d156ec6087a56bc334b40@dweimer.net>

next in thread | previous in thread | raw e-mail | index | archive | help
Hello=2C I dunno if this will help... but I decided I would try. I'm not su=
re why the one jail wont start=2C however I suggest trying to clean up your=
 config file. The issue could be parsing the config because its so long=2C =
I will provide an example.
### jail.conf ###
host.hostname =3D ${name}.dweimer.local=3Binterface =3D LAN=3Bpath =3D /jai=
ls/${name}/ROOT=3Ballow.mount.devfs=3Bmount.devfs=3B
mount.fstab =3D "/jails/${name}/fstab"=3Ballow.sysvipc=3Ballow.dying=3Bexec=
.start =3D "/bin/sh /etc/rc"=3Bexec.stop =3D "/bin/sh /etc/rc.shutdown"=3B
exec.prestart =3D "/jails/${name}/poststop.sh"=3Bexec.poststop =3D "/jails/=
${name}/poststop.sh"=3Bexec.consolelog =3D "/jails/${name}/console.log"=3B
pgsql {ip4.addr =3D 192.168.5.6=3B}
mysql {ip4.addr =3D 192.168.5.9=3B}
### EOF ###
Basically when not in { } it is treated as a default value=2C this will mak=
e the file much easier to read and manage. If you have a jail that does not=
 follow the defaults=2C then just add the value to that jail.
Unfortunately I don't think this will solve the issue. I am wondering if th=
e same jail will act up shutting down all jails then starting them via serv=
ice jail start.
> To: freebsd-questions@freebsd.org
> Subject: Jail not starting at Boot
> Date: Wed=2C 26 Aug 2015 08:50:02 -0500
> From: dweimer@dweimer.net
>=20
> I have seven jails configured on my system=2C I have them configured to=20
> start at boot with the following lines in /etc/rc.conf
>=20
> jail_enable=3D"YES"
> jail_parallel_start=3D"YES"
>=20
> They are all defined in /etc/jail.conf=2C here is the configuration from=
=20
> the first two. They are all basically the same=2C except IP address and=20
> directories. A couple of the ones not included do have one additional=20
> entry=2C depend =3D "pgsql"=3B as they have services that can't start wit=
hout=20
> the pgsql databases up.
>=20
> # Define PostgreSQL Jail
> pgsql {
>    host.hostname =3D pgsql.dweimer.local=3B
>    ip4.addr =3D 192.168.5.6=3B
>    interface =3D LAN=3B
>    path =3D /jails/pgsql/ROOT=3B
>    allow.mount.devfs=3B
>    mount.devfs=3B
>    mount.fstab =3D "/jails/pgsql/fstab"=3B
>    allow.sysvipc=3B
>    allow.dying=3B
>    exec.start =3D "/bin/sh /etc/rc"=3B
>    exec.stop =3D "/bin/sh /etc/rc.shutdown"=3B
>    exec.prestart =3D "/jails/pgsql/prestart.sh"=3B
>    exec.poststop =3D "/jails/pgsql/poststop.sh"=3B
>    exec.consolelog =3D "/jails/pgsql/console.log"=3B
> }
>=20
> # Define MySQL Jail
> mysql {
>    host.hostname =3D mysql.dweimer.local=3B
>    ip4.addr =3D 192.168.5.9=3B
>    interface =3D LAN=3B
>    path =3D /jails/mysql/ROOT=3B
>    allow.mount.devfs=3B
>    mount.devfs=3B
>    allow.sysvipc=3B
>    allow.dying=3B
>    mount.fstab =3D "/jails/mysql/fstab"=3B
>    exec.start =3D "/bin/sh /etc/rc"=3B
>    exec.stop =3D "/bin/sh /etc/rc.shutdown"=3B
>    exec.prestart =3D "/jails/mysql/prestart.sh"=3B
>    exec.poststop =3D "/jails/mysql/poststop.sh"=3B
>    exec.consolelog =3D "/jails/mysql/console.log"=3B
> }
>=20
> The issue I have is that the mysql jail above doesn't start at boot=2C I=
=20
> can't find any errors in any of the logs=2C all the other 6 start just=20
> fine. The exec.prestart and exec.poststop commands were added for=20
> troubleshooting=2C all they do is echo out the date and time that the=20
> command was called to the console log file for each jail. The mysql one=20
> doesn't get called at boot. All the jails cleanly shutdown when the=20
> server is shutdown=2C and the jail loads fine if I run jail -c mysql. I=20
> originally didn't have the jail_parallel_start=3D"YES" set=2C and had the=
=20
> same issue.
>=20
> Does anyone have any clue what to look for to determine what's stopping=20
> this jail from loading at boot?
>=20
>=20
> --=20
> Thanks=2C
>     Dean E. Weimer
>     http://www.dweimer.net/
> _______________________________________________
> freebsd-questions@freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe=2C send any mail to "freebsd-questions-unsubscribe@freebsd=
.org"
 		 	   		  =



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?SNT146-W5149D2CA9F8D9792C6F1A0A16C0>