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

RE: Web server Partitions



David,
I tend to agree with you that Adding more partitions, doesn't make the
system more manageable.
As this is a web server not a shell server with 100's of users. All the
important data is in /var.
All the important data being websites, logs, MySQL data. The only other
important data really is the system configuration which is in /etc but
that is restorable from backups.

Even home directory's aren't that important, but do get backed up. As
unfortunately we are in a mostly windows environment and our file
servers and mail servers are Windows2k and Exchange2k. *shivers*

One partition I forgot to mention in my post was /boot, a lot of people
recommend having the kernel on a separate partition. I'm guessing this
wouldn't exceed 10MB but 50MB is probably a safe size.

After pondering a few reply's I'm thinking of the following:
/boot - 50MB
/ - 23GB (remembering that /usr & /home etc. will be directory's
underneath this)
/var - 15GB (will contain logs, websites, and SQL data)
SWAP1 - 1GB
SWAP2 - 1GB

Apparently the kernel can balance loads between 2 swap partitions like
it can with multiple processors, so it would make sense to have 2 1GB
partitions rather than a 1 2GB partition. However this machine rarely
swaps.

Another question which arises is should I partition the disk in any
particular order i.e. does it mater if / is hda1 or hda5?

Thanks for everyone's replies!

-Braxton

-----Original Message-----
From: David Z Maze [mailto:dmaze@debian.org] 
Sent: Wednesday, 17 December 2003 1:59 AM
To: debian-user@lists.debian.org
Subject: Re: Web server Partitions


"Braxton Neate" <braxtonn@hitechtooling.com.au> writes:

> I know this is a question that gets asked a lot, but googling around I

> can't seem to find a good answer.  I'm re-installing a web/sql server 
> which currently has one large root partition and a swap partition.  
> This is obviously not the best setup.
>
> I'm wondering what other people would recommend in the way of 
> partitioning?
>
> The server is a 2x 800mhz PIII with 512MB RAM and a 40GB hard drive.

It depends on your exact needs.  Assuming you have no normal interactive
users, I'd probably set it up as

  /var/www -- "big enough", maybe 10-15 GB
  /var/lib/postgres (or whever) -- "big enough", maybe 10-15 GB
  swap -- 0.5-1 GB
  / -- Whatever's left

On this sort of system, the main benefits you get from partitioning are
fault isolation: if something gets confused on your root filesystem, and
fsck can't recover it, you haven't lost your data. Alternatively, if you
decide to reinstall the system, this partitioning scheme lets you
reinstall software but keep data.  If you have a substantial amount of
built-from-source software, you might also consider a partition for
/usr/local for similar reasons.

Adding more partitions, in my experience, doesn't make the system more
manageable; a common thing to happen is to install the system with a
small /var partition and then later realize that using APT is painful
because it wants lots of space in /var/cache/apt.  Or you make /usr too
small, or /tmp too small, and run into problems later on.

-- 
David Maze         dmaze@debian.org
http://people.debian.org/~dmaze/
"Theoretical politics is interesting.  Politicking should be illegal."
	-- Abra Mitchell


-- 
To UNSUBSCRIBE, email to debian-user-request@lists.debian.org 
with a subject of "unsubscribe". Trouble? Contact
listmaster@lists.debian.org



Reply to: