how best to partition HD?
Ken Schweigert
yellowdog-general@lists.terrasoftsolutions.com
Mon Mar 31 09:24:01 2003
On Sat, Mar 29, 2003 at 10:23:35PM -0500, mike newman wrote:
>
> i've been wondering about the best way to partition my disk for linux.
> having recently popped an IBM GNX 40gig into my wallstreet, i am no longer
> constrained by space. so i thought it would be a good idea to have one
> partition for /, for the stock ydl distro that i will presumable upgrade
> at some point and somewhat regularly, one partition for /usr/local for the
> other software that i install and will upgrade independently of the OS
> itself, and one partition for /usr/home, which i most definitely want to
> conserve across upgrades and backup quite often.
>
> but i notice that people often tangentially suggest a separate partition
> for /usr or /var ... is that better than leaving them in the same
> partition as / ? i honestly have no idea why i would separate these, but
> would rather learn now while wiping my hard drive is a low-key affair.
>
I would also recommend creating a /tmp partition and mounting it as 'noexec'.
This saved a lot of people from the Apache Slapper worm which uploaded a
file to /tmp, compiled and executed it. If the partition was mounted with
noexec, the worm was unsuccessful.
Modify your /etc/fstab file to look similar to this:
/dev/hdb13 /tmp ext2 defaults,rw,nosuid,nodev,noexec 1 2
HTH.
--
Ken Schweigert, Network Administrator
Byte Productions, LLC
http://www.byte-productions.com