summaryrefslogtreecommitdiffstats
path: root/usr.sbin/jail
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>2001-12-14 20:20:50 +0000
committerphk <phk@FreeBSD.org>2001-12-14 20:20:50 +0000
commitcdb77be2ca2b01daba2a0a6cab6942e73dcd8ccb (patch)
tree3d0de4f8bd1e02e5f8bd85961aeb704453cd25f5 /usr.sbin/jail
parent5014778ff3edc21083fa5a58ef321c96541aadeb (diff)
downloadFreeBSD-src-cdb77be2ca2b01daba2a0a6cab6942e73dcd8ccb.zip
FreeBSD-src-cdb77be2ca2b01daba2a0a6cab6942e73dcd8ccb.tar.gz
Add some wisdom to the jail setup instructions.
Diffstat (limited to 'usr.sbin/jail')
-rw-r--r--usr.sbin/jail/jail.812
1 files changed, 11 insertions, 1 deletions
diff --git a/usr.sbin/jail/jail.8 b/usr.sbin/jail/jail.8
index f45ddf0..439677a 100644
--- a/usr.sbin/jail/jail.8
+++ b/usr.sbin/jail/jail.8
@@ -52,10 +52,12 @@ Please see the
man page for further details.
.Sh EXAMPLES
.Ss "Setting up a Jail Directory Tree"
-This shows how to setup a jail directory tree:
+This example shows how to setup a jail directory tree
+containing an entire FreeBSD distribution:
.Bd -literal
D=/here/is/the/jail
cd /usr/src
+mkdir -p $D
make world DESTDIR=$D
cd etc
make distribution DESTDIR=$D -DNO_MAKEDEV_RUN
@@ -64,6 +66,14 @@ sh MAKEDEV jail
cd $D
ln -sf dev/null kernel
.Ed
+.Pp
+In many cases this example would put far more stuff in the jail than is needed.
+In the other extreme case a jail might contain only one singe file:
+the executable to be run in the jail.
+.Pp
+We recommend experimentation and caution that it is a lot easier to
+start with a ``fat'' jail and remove things until it stops working,
+than it is to start with a ``thin'' jail and add things until it works.
.Ss "Setting Up a Jail"
Do what was described in
.Sx "Setting Up a Jail Directory Tree"
OpenPOWER on IntegriCloud