Re: hard drive partitioning questions
I will give several levels of answer, since I don't know how much Linux
and filesystem experience you have.
First of all, as everyone notes, drive partitioning is a personal
decision, and more art than science. It varies from machine to machine.
That said, depending on how you want to use your system, you could get
away with a /+swap configuration. Another popular one is /+/home+swap.
In the old days when drives were not mind-blowingly large, you sometimes
had to divide up partitions. Another reason for this was security
issues. In the old days, you could cause a denial of service condition
where the machine would actually lock hard if / was filled. I grew up as
a sysadmin in this era (do I sound old?), and I'm a security engineer,
so my partitioning choices reflect this way of thinking.
My credo was to start with a theoretical amount of drive space, then
slice off bits as needed.
I put any filesystem which a user has direct write access to on a
separate partition (e.g. /tmp and /home)
Put any filesystem which a user can write to indirectly on a separate
partition (e.g. /var )
Any non-standard filesystem (e.g. /opt, /usr/local etc.)
This is an explanation of why my filesystem looks like this:
/dev/hda2 2822496 2108740 570376 79% /
/dev/vg00/lv_tmp 163828 66948 96880 41% /tmp
/dev/vg00/lv_var 1572812 369780 1203032 24% /var
/dev/vg00/lv_home 2621356 2428496 192860 93% /home
1572812 614048 958764 40% /usr/local
/dev/vg00/lv_backup 14155340 4406116 9749224 32% /backup
/dev/vg00/lv_video 19922332 10362468 9559864 53% /usr/local/video
/dev/vg00/lv_archive 15728156 8610836 7117320 55% /archive
Now, using multiple partitions like this has traditionally lead to the
problem of guessing wrong on partition sizing. You end up with a /var
that is way too small or a /tmp that is entirely too large.
For the last year, I have used Linux Logical Volume Manager (LVM) to
manage partitions. It gives you the ability to resize partitions, and if
used in conjunction with one of the journaling filesystems, you can do
this on the fly. Plus you can add drives on the fly as well. Stick it
in, allocate it to LVM (partition the entire drive as 8e), then use as
needed...Adding partitions or just extending existing ones.
Depending on your comfort level, any combination of options will work
 It also works out nicely that Debian's package cache lives in the
/var tree in this case.
On Tue, 2002-12-31 at 01:06, Nori Heikkinen wrote:
> i'm installing debian on a brand-new new hard drive on my home system
> (i.e., personal usage), and am at the point of making a swap
> partition. cfdisk is up, and i'm trying to figure out what partitions
> i should specify. i'm reading the the woody installation how-tos ,
> and am kind of confused.
> i just bought a new 80G hard drive. i should partition the whole
> thing, right? i'm thinking:
> /dev/hda1 -- / (Linux (83)) -- 100M (is this appropriate?)
> /dev/hda2 -- /usr (83) -- 1G (too much?)
> /dev/hda3 -- swap (82) -- 128M (i have that much physical RAM, and
> that should be sufficient, right?) should i make this
> /dev/hda3 -- /var -- 2 or 3 G, as per suggestion of  (i like apt)
> /dev/hda4 -- /tmp -- 50M-ish?
> /dev/hda5 -- /home -- the rest, all for me :)
> have i correctly extracted that these are the partitions i'll need?
> does the above sound good? i'm assuming i can designate them all
> later on in the installation process, after i've actually created
Bradley M. Alexander |
Debian Developer, Security Engineer | storm [at] tux.org
Debian/GNU Linux Developer | storm [at] debian.org
DSA 0x54434E65: 37F6 BCA6 621D 920C E02E E3C8 73B2 C019 5443 4E65
RSA 0xC3BCBA91: 3F 0E 26 C1 90 14 AD 0A C8 9C F0 93 75 A0 01 34
Flying isn't dangerous. Crashing is what's dangerous.
--Rules of the Air, #3