Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 9 Jul 2009 10:37:40 -0400
From:      Jim <>
Subject:   jail/system crash with mount_unionfs
Message-ID:  <>

Next in thread | Raw E-Mail | Index | Archive | Help
OS: FreeBSD 7.2 release / Generic kernel
I used CSUP to download the source tree, and the RELENG_7_2, no date
specified. I didn't rebuild the base OS world/kernel.

I have installed a lot of ports on the main system, most of what the
jail would need is also already installed - so the distfiles and ports
directories are already setup to speed of the install process. I
figured I'd save time and effort and use unionfs to allow both systems
to use the same ports directory (to be safe, I won't compile things
from both systems at the same time, but keeping the same ports
directory was fine.

I followed the jail creation instructions in the handbook posted on

Once the jail was created, I made a script to union the ports directories:
    mount_unionfs /usr/ports /data/jail/

I also have my jail shell startup script:
    jail -s 2 /data/jail/ /bin/sh

[sjss@boromir /data/jail]$ ls
[sjss@boromir /data/jail]$ sudo ./ts.org_mount_ports
[sjss@boromir /data/jail]$ ls
... ports directory listing omitted
[sjss@boromir /data/jail]$ sudo ./ts.org_shell
# cd /usr/ports
# ls
The base operating system hangs at this point.

[sjss@boromir /data/jail]$ ls
[sjss@boromir /data/jail]$ cd
[sjss@boromir /data/jail/]$ cp -rf /usr/ports/* .
[sjss@boromir /data/jail/]$ cd /data/jail
[sjss@boromir /data/jail]$ ls
... ports directory listing omitted
[sjss@boromir /data/jail]$ sudo ./ts.org_shell
# cd /usr/ports
# ls
... ports directory listing omitted

As you can see, there is a work around, so I'm not that /bothered/ by
this, but it'd be nice to know what's up. Am I doing something wrong?
If not, can anyone replicate this? Should I file a bug report?

-Jim Stapleton

Want to link to this message? Use this URL: <>