aboutsummaryrefslogblamecommitdiff
path: root/usr.sbin/jail/jail.8
blob: 6172af7e54346ac1a07f1c0639582e0458acde5b (plain) (tree)
1
2
3
4
5
6
7
8
9







                                                                               
            

   




                  
                                        




             

           






                                                      
                             
















                                               












                                                     
.\"
.\"----------------------------------------------------------------------------
.\""THE BEER-WARE LICENSE" (Revision 42):
.\"<phk@FreeBSD.ORG> wrote this file.  As long as you retain this notice you
.\"can do whatever you want with this stuff. If we meet some day, and you think
.\"this stuff is worth it, you can buy me a beer in return.   Poul-Henning Kamp
.\"----------------------------------------------------------------------------
.\"
.\"$FreeBSD$
.\"
.\"
.Dd April 28, 1999
.Dt JAIL 8
.Os FreeBSD 4.0
.Sh NAME
.Nm jail
.Nd imprison process and its descendants
.Sh SYNOPSIS
.Nm jail
.Ar path
.Ar hostname
.Ar ip-number
.Ar command
.Ar ...
.Sh DESCRIPTION
The
.Nm
command imprisons a process and all future decendants.
.Pp
Please see the
.Xr jail 2
man page for further details.
.Sh EXAMPLES
This shows how to setup a jail directory tree:
.Bd -literal 
D=/here/is/the/jail
cd /usr/src
make hierarchy DESTDIR=$D
make obj
make all
make install DESTDIR=$D
cd etc
make distribution DESTDIR=$D
cd $D/dev
sh MAKEDEV jail
cd $D
ln -sf dev/null kernel
echo "proc $D/proc procfs rw 0 0" >> /etc/fstab
.Ed
.Sh SEE ALSO
.Xr chroot 2 ,
.Xr jail 2
.Sh HISTORY
The
.Fn jail
function call appeared in
.Fx 4.0 .
.Pp
The jail feature was written by Poul-Henning Kamp for
R&D Associates
.Dq Li http://www.rndassociates.com/
who contributed it to FreeBSD.