Re: [Vserver] Quota for guest servers on /vservers, /vservers is on LVM ext3

From: Chuck <>
Date: Tue 18 Oct 2005 - 20:31:50 BST
Message-Id: <>

On Tuesday 18 October 2005 02:58 pm, Steven Truong wrote:
> Hi, all. After reading some of the messages regarding quota, I would like to
> implement quota for the guest servers on a LVM partition /vservers. I only
> care to limit the amount of space a guest server could use and I do not care
> about the per user quota in each guest.
> I found this link from a recent message and wonder if the instructions
> applied to my situations.

to be honest i am not sure of the above method.. all i did was create a
logical volume using lvm for each guest the size i wanted that guest to have.
easy to extend if more space is needed for a given guest.

i followed this how-to below but interpolated my own needs into it and it
worked great the first time out. now each guest is limited to a 10g 'hdd'.
on my next round of installs some will be a 40g etc...and it doesn't place
any extra responsibility on the kernel for quotas or anything.

although the doc is written for gentoo, the information in it is not gentoo
specific besides how to install packages. the only other change i made was i
did not use modules but included all lvm items needed within the kernel since
i use monolithic kernels (not capable of loading modules). i used one volume
which was half the raid disk system i have set aside for this, leaving the
other half to be used sometime in the future as needed. i then used the file
system i wanted for each guest on each virtual volume.

i made a small /vservers "home" mount point and then mounted the individual
guest disks within that so it is all well separated from the host. the final
tree looks like this now with each volume/mount point the name of the guest:

/dev/sda6 9.4G 516M 8.9G 6% /vservers
/dev/mapper/vg-colossus 10G 429M 9.6G 5% /vservers/colossus
/dev/mapper/vg-nagios 10G 371M 9.7G 4% /vservers/nagios
/dev/mapper/vg-ns 10G 352M 9.7G 4% /vservers/ns
/dev/mapper/vg-ns1 10G 342M 9.7G 4% /vservers/ns1
/dev/mapper/vg-ns2 10G 337M 9.7G 4% /vservers/ns2
/dev/mapper/vg-prometheus10G 703M 9.4G 7% /vservers/prometheus
/dev/mapper/vg-usage 10G 528M 9.5G 6% /vservers/usage

that's about as close to physically partitioning the disk for each as you can
get but any of them are easily extendable and won't pass its own boundaries
if a rogue guest gets artistic and desides to write pretty 1 and 0 designs
all over the 'disk'. :) .

this was my first attempt with lvm and i honestly now cannot say how i lived
without it before. :)

> And how LVM could assist in limiting disk space of each guest server? (If by
> any means)
> Please assist me in this attempt.
> Thanks.

"...and the hordes of M$*ft users descended upon me in their anger,
and asked 'Why do you not get the viruses or the BlueScreensOfDeath
or insecure system troubles and slowness or pay through the nose 
for an OS as *we* do?!!', and I answered...'I use Linux'. "
The Book of John, chapter 1, page 1, and end of book
Vserver mailing list
Received on Tue Oct 18 20:32:09 2005
[Next/Previous Months] [Main vserver Project Homepage] [Howto Subscribe/Unsubscribe] [Paul Sladen's vserver stuff]
Generated on Tue 18 Oct 2005 - 20:32:14 BST by hypermail 2.1.8