[plug] Partitioning Hard Disk
Shayne O'Neill
shayne at guild.murdoch.edu.au
Wed Sep 25 21:50:23 WST 2002
One rule of thumb I've heard is Memory size x2 , so for a 256 meg machine,
500meg swap.
One really good bit of advice is to get a crufty old 500mg hard drive and
use it solely for swap. That way swaping doesnt have to get interleaved with
normal HD actions, cutting down on 'thrashing' on the HD. Balance that
against the speed of the HD tho. If you have a 7200rpm HD for the biggun,
it's probly not a big issue either way, and on the fringe of being redundant
due to IDE bandwidth.
----- Original Message -----
From: "Craig Ringer" <craig at postnewspapers.com.au>
To: <plug at plug.linux.org.au>
Sent: Wednesday, September 25, 2002 6:53 PM
Subject: Re: [plug] Partitioning Hard Disk
> > /tmp (roughly) 100MB, vary according to available space and needs
>
> Alternately, give yourself more swap and use tmpfs - its fast,
> efficient, and handily erased at every boot. Of course, that's personal
> preference only.
>
> > /usr size of packages plus some elbow room
>
> Or _lots_ of elbow room, depending on how much playing about with things
> you plan to do. An OO.o install in /usr/local can eat an incredible
> amount of space.
>
> > /var \ if this is to be predominantly a server, make var huge and home
> > /home / small; if this is to be predominantly a workstation or store
> > many individual user files (think SaMBa), reverse that.
>
> Alternately, if you're feeling cramped for space, you can use bind
> mounts to share a partition between /home and /var. Upside: more space
> efficient and more flexible. Downsides: more complex, no distro can set
> it up at install-time, makes distro changes a wee bit uglier. I like to
> do that on desktops with < 40gb of space, as I never know whether I'll
> have a 500mb /var or a 4gb /var.
>
> How: create a single partition to old /var and /home, mounted on say
> /.home_var
>
> create the directories
> /.home_var/home
> /.home_var/var
>
> mount -o bind /.home_var/home /home
> mount -o bind /.home_var/var /var
>
> and in /etc/fstab:
>
> /.home_var/home /home none bind 0 0
> /.home_var/var /var none bind 0 0
>
> mount -a handles this quite happily - but make _certain_ that the entry
> in fstab for the real FS is before any bind mounts using it.
>
> > I use ext3 where possible. ReiserFS is too complicated and ext2 has no
> > journalling.
>
> Complicated? mkreiserfs /dev/hdxn ; mount -t reiserfs /dev/hdxn /point
> I've never had any problems with reiserfs - though its nicer now that
> the distros rescue disks all support it.
>
> > When installation is done, mount /usr and /boot readonly,nodev; and
mount
> > /tmp, /home and /var nosuid,nodev. Under certain circumstances, you can
also
> > leave / mounted readonly, and this is an excellent security measure.
>
> But you have to mess about a lot to do it. Mount expects to be able to
> write to /etc/mtab at boot, etc - its usually more trouble than its
> worth. I discovered just how much when building nfs-root thin clients -
> lots of messing about dealing with a ro /etc.
>
> --
> Craig Ringer
> GPG Key Fingerprint: AF1C ABFE 7E64 E9C8 FC27 C16E D3CE CDC0 0E93 380D
> -- if it ain't broke, add features 'till it is. (or:)
> while (! broken) { features ++ ; broken = isBroken(features) }
>
>
>
More information about the plug
mailing list