Hello
Often I get the following problem when starting / restarting my jails
After a few minutes, it works normally again.
/etc/jail.conf
Each jail is in its own dataset eg. /usr/jail/sys1, /usr/jail/sys2, /usr/jail/sys3
with base and template method /usr/jail/base /usr/jail/tmpl
/etc/fstab.sys1
/etc/fstab.sys2
/etc/fstab.sys3
What can cause this problem?
Thanks in advance.
Often I get the following problem when starting / restarting my jails
Code:
# service jail start sys1
Starting jails: cannot start jail "sys1":
jail: sys1: cannot redefine variable "name".
jail: sys2: cannot redefine variable "name".
jail: sys3: cannot redefine variable "name".
jail: sys1: jail 1 already exists
After a few minutes, it works normally again.
/etc/jail.conf
Code:
exec.clean;
exec.start += "/bin/sh /etc/rc";
exec.stop = "/bin/sh /etc/rc.shutdown";
exec.system_user = "root";
exec.jail_user = "root";
exec.consolelog = "/var/log/jail_${name}_console.log";
mount.devfs;
mount.fstab = "/etc/fstab.${name}";
allow.mount;
allow.set_hostname = 0;
allow.sysvipc = 0;
allow.raw_sockets = 0;
devfs_ruleset = 4;
sys1 {
jid = 1;
name = sys1;
path = /usr/jail/sys1;
ip4.addr = 127.0.0.2;
host.hostname = sys1.local;
persist;
interface = lo0;
allow.sysvipc = 1;
}
sys2 {
jid = 2;
name = sys2;
path = /usr/jail/sys2;
ip4.addr = 127.0.0.3;
host.hostname = sys2.local;
persist;
interface = lo0;
allow.sysvipc = 1;
}
sys3 {
jid = 3;
name = sys3;
path = /usr/jail/sys3;
ip4.addr = xxx.xxx.xxx.xxx, 127.0.0.4;
ip6.addr = xxx:xxx:xxx;
host.hostname = website.tld;
persist;
interface = em0, lo0;
allow.sysvipc = 1;
}
Each jail is in its own dataset eg. /usr/jail/sys1, /usr/jail/sys2, /usr/jail/sys3
with base and template method /usr/jail/base /usr/jail/tmpl
/etc/fstab.sys1
Code:
/usr/jail/base /usr/jail/sys1/base nullfs noatime,ro 0 0
/etc/fstab.sys2
Code:
/usr/jail/base /usr/jail/sys2/base nullfs noatime,ro 0 0
/etc/fstab.sys3
Code:
/usr/jail/base /usr/jail/sys3/base nullfs noatime,ro 0 0
Code:
# freebsd-version
11.1-RELEASE-p3
What can cause this problem?
Thanks in advance.
Last edited by a moderator: