Subject: Re: [vserver] vserver: Mounting /run ... mount: permission denied [ !! ]
From: Natanael Copa <natanael.copa@gmail.com>
Date: Tue, 22 May 2012 08:02:25 +0200

On Mon, May 21, 2012 at 10:41 PM, Jarry <mr.jarry@gmail.com> wrote:
> It is auto-run at every boot (in vserver-host).
>
> Problem is in the last version of OpenRC: it wants to mount
> /run as tmpfs now early in the boot. Some permission must be
> granted probably for vserver-guests, I have no idea which one.
>
> In vserver-host I did not make any change in /etc/fstab or
> elsewhere, it simply works and /run is mounted as tmpfs.
> Problem is only with vserver-guests...

Add  something like:
none	/run		tmpfs	size=1m,mode=0755	0 0

to /etc/vservers/<guest>fstab

This should be fixed in gentoo's preinit script imho. Something like:

diff --git a/distrib/gentoo/initpre b/distrib/gentoo/initpre
index 4a66bf5..42ac454 100755
--- a/distrib/gentoo/initpre
+++ b/distrib/gentoo/initpre
@@ -50,6 +50,8 @@ else
        echo "!!! shared distfiles directory if you have multiple Gentoo guests!
 fi

+# add /run to fstab
+echo "none     /run            tmpfs   size=1m,mode=0755       0 0"
>> "$1"/fstab

 # initstyle sanity
 initstyle=sysv

-- 
Natanael Copa