Re: disk partition schemes
On Sat, Jun 23, 2001 at 09:34:59AM +0200, Russell Coker wrote:
> On Saturday 23 June 2001 04:10, Nick Jennings wrote:
> > The main performance benefit to having directories reside on their own
> > partition relates to file write/read access. It's very important to
> > have var on it's own seperate partition, specifically because it's
> > probably the most actively written to directory.
> OK. If you have a single physical hard drive or RAID array, the how will
> having /var on a separate partition give any benefit? Disk access still
> goes to the same hardware and is still limited by head seek times and
> rotational delays of the hardware. Having two seeks on the same
> partition or two seeks on separate partitions should not perform any
I guess I was going by the same logic of the swap partition, having
your partitions ordered by most usage. I also added into this having
your system partitioned into logical segments to increase maintnence
> However if you have a single large partition then when you are writing
> data the FS drivers can optimise things.
I always thought that this was a performance hit, I know I've read it in
places before, but I can't seem to find them as I look right now.
> > Another little performance gain is the order in which you partition
> > your disks (the closer to the 0'th cylinder the faster the access time.
> This depends on the type of device. This is a general rule that doesn't
> always apply. But when it does apply it's not so small. 50% extra
> performance at the start of the disk is not uncommon.
> AFAIK I'm the only person to publish a benchmark program to measure
> > For instance, this is the order in which I usually go about
> > partitioning my drive (note: it varies depending on it i'm setting up a
> > workstation or a server, but they are similar).
> > <swap> size: totalmem*2 (64mb = 128mb partition)
> > /
> > /tmp
> > <extended>
> > /usr
> > /var
> > /home
> Swap is often the most used partition. Root is probably the least. /tmp
> and /home are both candidates for the most used partition. Having things
> separate like this means that in many common usage situations you'll have
> the heads seeking across the entire disk all the time. Having a single
> partition could increase performance...
Good point, I've put / at the beginning just out of habit, put I think
that, especially on a server, /var is much more used than home is. and
/usr is where every application is executed from, that's gotta count for
something. I would venture to say that, on a server thats not offering
lots of shell accounts, /home is the least used.
> > If I run out of room on /var/www or /var/cvs or something, I can stick
> > another disk in and mount that in its place instead. I used to get
> > worried about wasted space, but if you just over estimate a bit, you
> > should be fine with most of the partitions that don't grow (like /,
> > /tmp, /usr). And you just give the most space the the ones that can
> > grow. Now I find a nice partitioning scheme to be much more manageable
> > and the performance is very noticable.
> If sticking another disk in is so easy then why not just install lots of
> disks in a RAID array from the start? That'll get the best performance...
Well because a hardware RAID is more expensive than a scsi or ide drive.
Also because I'm thinking of one disk, with the possible expansion onto
another one, or two. not starting out with several.