jails jail: dns: jail_set: Invalid argument

When I try jail -crm -f dns.conf, where dns.conf is the following
Code:
dns {
exec.start = "/bin/sh /etc/rc";
exec.stop = "/bin/sh /etc/rc.shutdown";
exec.consolelog = "/var/log/jail_console_${name}.log";

allow.raw_sockets;
exec.clean;
mount.devfs;
enforce_statfs = 5;
devfs_ruleset = 5;

path = "/jails/${name}";
host.hostname = "${name}";

$unterid = "3";
$id = "${unterid}";
$ip = "192.168.0.${unterid}/24";
$gateway = "192.168.0.1";
$bridge = "bridge0";
$epair = "epair${id}";

vnet;
vnet.interface = "${epair}b";

exec.prestart  = "/sbin/ifconfig ${epair} create up";
exec.prestart += "/sbin/ifconfig ${epair}a up descr jail:${name}";
exec.prestart += "/sbin/ifconfig ${bridge} addm ${epair}a up";
exec.prestart += "/sbin/ifconfig ${epair}a ether 02:16:b1:a5:e9:0a";
exec.prestart += "/sbin/ifconfig ${epair}b ether 02:16:b1:a5:e9:0b";
exec.start    += "/sbin/ifconfig ${epair}b ${ip} up";
exec.start    += "/sbin/route add default ${gateway}";
exec.poststop = "/sbin/ifconfig ${bridge} deletem ${epair}a";
exec.poststop += "/sbin/ifconfig ${epair}a destroy";
}
I get the following:
Code:
jail: dns: jail_set: Invalid argument
I already destroyed the network device, before creating, and put a fresh bsdinstall jail in the jail's root.
 
First error here: mount.devfs;. Such an option does not exist, you probably mean allow.mount.devfs. For this to work at all, you also need allow.mount and enforce_statfs < 2 (which is btw the default and maximum value. and the normal approach is to mount everything from outside the jail before starting it). Not looking any further for now ...
I do think, that I must reinstall FreeBSD.
That's cargo cult, what magic should it do? The way to solve problems is to read the manual: jail.conf(5), jail(8).
 
First error here: mount.devfs;. Such an option does not exist, you probably mean allow.mount.devfs. For this to work at all, you also need allow.mount and enforce_statfs < 2 (which is btw the default and maximum value. and the normal approach is to mount everything from outside the jail before starting it). Not looking any further for now ...
Ithat is moving cmd]enforce_statf=s[/cmd] to enforce_statfs, fixed the problem.
That's cargo cult, what magic should it do? The way to solve problems is to read the manual: jail.conf(5), jail(8).
Cargo Cult?
 
Back
Top