jail on ZFS - "Unable to mount devfs"

Maciej Suszko maciej at suszko.eu
Tue Jan 8 12:47:10 PST 2008


snowcrash+freebsd wrote:
> hi wesley,
> 
> > I have a jail running in a ZFS environment.
> >
> > wxs at ack ~ % jls
> >    JID  IP Address      Hostname                      Path
> >      3  192.168.1.100
> > asterisk                      /u/jails/asterisk wxs at ack ~ % mount |
> > grep "data" data on /u (zfs, NFS exported, local, noatime)
> > wxs at ack ~ % mount | grep devfs
> > devfs on /dev (devfs, local)
> > devfs on /u/jails/asterisk/dev (devfs, local)
> > wxs at ack ~ %
> 
> here's what i have
> 
> jls
> 	   JID  IP Address   Hostname             Path
> 		 1  10.0.0.200   jTEST.internal.net   /j/jTEST
> 
> mount
> 	z on / (zfs, local)
> 	devfs on /dev (devfs, local)
> 	/dev/mirror/gm0s1a on /bootdir (ufs, local, soft-updates)
> 	z/data on /data (zfs, local)
> 	z/home on /home (zfs, local)
> 	z/j on /j (zfs, local)
> 	z/tmp on /tmp (zfs, local)
> 	z/usr on /usr (zfs, local)
> 	z/var on /var (zfs, local)
> 	/j/jMROOT on /j/jTEST (nullfs, local, read-only)
> 	/j/s/jTEST on /j/jTEST/s (nullfs, local)
> 	devfs on /j/jTEST/dev (devfs, local)
> 
> which, i think?, says the same.
> 
> argh. confused. following too many threads with partial solutions ...
> 
> can you share your setup-a-jail-on-a-zfs'd-host steps?

Hi.

I just took ordinary steps to have a working jail on ZFS:
- make buildworld
- make installworld DESTDIR=/path/to/jail
- make distribution DESTDIR=/path/to/jail
- copy/edit some config files (mainly under /path/to/jail/etc)
- start jail
- jexec 1 /bin/sh

from /etc/rc.conf (besides enabling jail, list of jails etc.):
jail_name_procfs_enable="YES"
jail_name_devfs_enable="YES"

That's all.
-- 
regards, Maciej Suszko.


More information about the freebsd-current mailing list