[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: to lvm or not to lvm?

On Fri, Apr 20, 2007 at 07:11:29PM -0500, Default User wrote:
> intended use: standard home system, single user, not mission critical
> (except that to everyone, their own data is always "mission critical").
> nothing exotic or fancy. 
> do really need lvm? if i have to ask, then the answer is, "probably
> not".  my concern was that a partition that seems spacious originally,
> can over time become cramped, while another loafs with unused space. and
> no one can precisely predict future needs. further, i plan to switch to
> testing after the chaos dies down, and want to run that at least until
> lenny becomes the next stable.  so i am trying to think long term.  and
> re-installing every 6 months would really get old fast. 
> i could just have one / partiton (plus a swap partition). That's simple,
> flexible, and low maintenance. no worrying about data outgrowing
> partition sizes.  but the OpenBSD FAQ makes a compelling case for
> multiple partitions, at least separate /, /tmp, /var, /usr, and /home
> (as well as an ENCRYPTED swap partition). and that is one of the default
> partitioning choices in the Debian installer.
> note: I am not trying to start an OS flame war. I just mention it for
> what it's worth. 
> a fresh install is a rare opportunity to do things right, so I try not
> to squander it.  


I _always_ use separate partitions unless I'm trying to install to a 171
MB drive (just did that, needed NetBSD).  There are _many_ compelling
reasons to have separate partitions for separate major chunks of the
file system.  One is when drive space gets tight, you can farm it off to
a new disk.

LVM makes this so much easier.  Its also stable.  So why not?  

Drives are cheap.  You may like to research putting your
system (/, /boot, /usr, /var, swap [with /tmp on tmpfs]) on raid1 with
everything but /boot on LVM over top of the raid array.  If you're
really thinking long-term, then you have to plan for a drive failure.

No matter what you do, you'll need good backups: at least /etc, /boot,
/home, dpkg --get-selections, aptitude search '~i!~M', fdisk -lu and
sfdisk -d for each drive, onto media that you can read from a rescue
system with all this plus an install CD stored off-site.

For completeness, for partition sizes, I recommend: / 512 MB, /boot 65
MB, /usr 4 GB, /var 4 GB (I store backups in /var/local), /tmp 256 MB
(on tmpfs), with /home whatever.  I have home on a separate VG (on raw
disks) from the system VG (on raid1).  You could consider putting
/var/tmp on a non-raid VG and making its LV striped for speed.

If you don't mind a boot-up passphrase, then encrypt /home and /var/tmp
(along with swap with /tmp on tmpfs).  Konquorer for example puts its
cache via a symlink in your home directory to /var/tmp and there's no
way to change that behaviour.  So even if your /home is encrypted,
Konquorer's cache is not.

As always, YMMV and there are as many ways to set this up as there are
people on this list.

Good luck,


Reply to: