From 62582c8531fd56e68daec90ebc7c33c65cd59126 Mon Sep 17 00:00:00 2001 From: Alejandro Mery Date: Wed, 2 Dec 2009 15:34:25 +0100 Subject: [PATCH] util-vserver: do post-start mounts with -n if mtab is a symlink --- ...D%sysconfdir_vservers_.defaults_scripts_post-start.sh | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/pkgs/util-vserver/D%sysconfdir_vservers_.defaults_scripts_post-start.sh b/pkgs/util-vserver/D%sysconfdir_vservers_.defaults_scripts_post-start.sh index 7409e0f..dbb1df8 100644 --- a/pkgs/util-vserver/D%sysconfdir_vservers_.defaults_scripts_post-start.sh +++ b/pkgs/util-vserver/D%sysconfdir_vservers_.defaults_scripts_post-start.sh @@ -3,7 +3,7 @@ # This copyright note is auto-generated by ./scripts/Create-CopyPatch. # # Filename: target/sheba/pkgs/util-vserver/D%sysconfdir_vservers_.defaults_scripts_post-start.sh -# Copyright (C) 2008 The OpenSDE Project +# Copyright (C) 2008 - 2009 The OpenSDE Project # # More information can be found in the files COPYING and README. # @@ -19,11 +19,14 @@ if grep -q '[ ]/dev[ ]' "$__CONFDIR/$2/fstab"; then # guest has /dev as tmpfs # + case "$(readlink -f etc/mtab)" in + /proc/*) xflag=-n ;; + esac # mount devpts after /dev was populated # - $_SECURE_MOUNT -t devpts -o gid=5,mode=620,dev --chroot none /dev/pts + $_SECURE_MOUNT -t devpts -o gid=5,mode=620,dev $xflag --chroot none /dev/pts # 144 is what qemu wants... I know it's wrong to hardcode this here, but # I don't have the time for a better implementation (fstab) yet - $_SECURE_MOUNT -t tmpfs -o size=144m --chroot none /dev/shm + $_SECURE_MOUNT -t tmpfs -o size=144m $xflag --chroot none /dev/shm fi