Static Jail ID's (JID's) for use with IPFW?
freebsd at qeng-ho.org
Wed Aug 7 11:43:43 UTC 2013
On 07/08/2013 09:28, Karl Pielorz wrote:
> I have a number of jailed systems running - and I've been setting up
> ipfw rules for them.
> This is on FBSD 9.1.
> 'ipfw' lets you match on traffic to/from a Jail ID (JID) - however every
> time jails get started / stopped their JID changes [thus breaking the
> firewall rules].
> I can't see anywhere to 'statically' configure a JID to a Jail (i.e. in
I don't think the old /etc/rc.conf way of handling jails lets you do it,
but the latest version of jail(8) introduced /etc/jail.conf and you
should be able to add "jid = <N>;" parameters in there.
I've no idea what will happen if your choice conflicts with an
automatically generated jid, so you'll either have to make sure all
jails have fixed jids, or choose a suitably high range for fixed ones
and hope you never generate too many unfixed jids.
In the dungeons of Mordor, Sauron bred Orcs with LOLcats to create a
new race of servants. Called Uruk-Oh-Hai in the Black Speech, they
were cruel and delighted in torturing spelling and grammar.
_Lord of the Rings 2.0, the Web Edition_
More information about the freebsd-questions