The following combination of rc.conf settings inside a jail, will prevent it from persisting after initial creation.
The jail will initially create, appear to be successful, but will immediately disappear from both
This is a cleanly installed _base, with no users created, and only pkg and doas installed. jid=60 because that's how many times I started/stopped this for troubleshooting, as I deleted the other standard rc.conf entries one by one, because they seemed to have no effect. Also, there are no other jails running, or packages running except Xorg, i3, nvidia, and xterm. My host install is fairly clean.
Here is my /etc/jail.conf:
If some of you more experienced folk believe this is a bug, let me know and I'll file a bug report. Or if not, please help me understand what the heck is happening here. I lost a solid 4 hours today figuring this out.
Code:
syslogd_enable="NO"
cron_enable="NO"
sendmail_enable="NONE"
sshd_enable="NO"
The jail will initially create, appear to be successful, but will immediately disappear from both
jls
and ps ax
with no apparent error message. Changing any single one of the above will enable successful and persistent jail creation. If none are changed, then jail -vc _base
will finish but the jail will disappear. It ends with these lines:
Code:
<...snip...>
Creating and/or trimming log files.
Clearing /tmp (X related).
Updating motd:.
Wed Aug 26 01:45:07 CDT 2020
_base: jail_set(JAIL_UPDATE) jid=60 nopersist
root@host:~ #
This is a cleanly installed _base, with no users created, and only pkg and doas installed. jid=60 because that's how many times I started/stopped this for troubleshooting, as I deleted the other standard rc.conf entries one by one, because they seemed to have no effect. Also, there are no other jails running, or packages running except Xorg, i3, nvidia, and xterm. My host install is fairly clean.
Here is my /etc/jail.conf:
Code:
host.hostname="$name";
path="/jails/$name";
mount.devfs;
allow.mount.fdescfs;
vnet;
exec.clean;
exec.start="sh /etc/rc";
exec.stop="sh /etc/rc.shutdown";
_base {
}
If some of you more experienced folk believe this is a bug, let me know and I'll file a bug report. Or if not, please help me understand what the heck is happening here. I lost a solid 4 hours today figuring this out.