Do not unconditionally mount devfs to ${jail_devdir}/dev. First check
to see if a prior devfs has been mounted. If no devfs is mounted on ${jail_devdir}/dev then proceed. This will prevent the stack up of multiple devfs mounts on the same mount point. Discussed with: pjd MFC after: 1 week
This commit is contained in:
parent
2af94c5d1d
commit
115005468b
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=145694
@ -163,15 +163,18 @@ jail_start()
|
||||
mount -a -F "${jail_fstab}"
|
||||
fi
|
||||
if checkyesno jail_devfs; then
|
||||
info "Mounting devfs on ${jail_devdir}"
|
||||
devfs_mount_jail "${jail_devdir}" ${jail_ruleset}
|
||||
|
||||
# Transitional symlink for old binaries
|
||||
if [ ! -L "${jail_devdir}/log" ]; then
|
||||
__pwd="`pwd`"
|
||||
cd "${jail_devdir}"
|
||||
ln -sf ../var/run/log log
|
||||
cd "$__pwd"
|
||||
# If devfs is already mounted here, skip it.
|
||||
df -t devfs "${jail_devdir}" >/dev/null
|
||||
if [ $? -ne 0 ]; then
|
||||
info "Mounting devfs on ${jail_devdir}"
|
||||
devfs_mount_jail "${jail_devdir}" ${jail_ruleset}
|
||||
# Transitional symlink for old binaries
|
||||
if [ ! -L "${jail_devdir}/log" ]; then
|
||||
__pwd="`pwd`"
|
||||
cd "${jail_devdir}"
|
||||
ln -sf ../var/run/log log
|
||||
cd "$__pwd"
|
||||
fi
|
||||
fi
|
||||
|
||||
# XXX - It seems symlinks don't work when there
|
||||
|
Loading…
Reference in New Issue
Block a user