Subject: Re: [vserver] readonly root
From: Corin Langosch <corinl@gmx.de>
Date: Thu, 10 Mar 2011 14:00:00 +0100

On 09.03.2011 15:10, Martin wrote:
> You may wish to read the Linux Filesystem Standard which tells you which
> part of the filesystem need to be read / write, which can be read only,
> etc.  Beyond that you may wish to look at the overlay setup that live
> CDs use.

When trying to start a vserver from a read-only path it won't work. 
chroot-sh complains that several files are read-only, especially 
/etc/mtab. I'm now using "aufs" with mounting my "shared root" ro and an 
additional very small tmpfs partition rw (so the vserver can be started).

> Have you looked at vashify / hardlinks?

Yes, but I think it's not the best for my needs. I may be I wrong, so 
I'll explain my needs below. :)

> Over all what problem are you trying to solve?  Read only filesystems
> may not be the best way of acheiving reduced memory / disk usage, etc.

I need to setup a shared hosting environment where users can also login 
using ssh, for example to work with the shell/ installed tools. So my 
idea was to have a shared root layout with all common stuff installed 
there. It must be read-only, so the users dont alter it. The user data/ 
application code is in a separate folder and will be mounted inside the 
vserver instance as needed.

Using this layout I hope to achive maximum performance (shared memory, 
little virtualization overhead, ..), highest security and still giving 
the users the freedom to use the shell/ tools. Now with "aufs", I'm only 
worried if it's killing my reduced memory requirements.

Thanks,
Corin