PDA

View Full Version : Partition recomendations?


phil
12th July 2001, 15:04
OK, I have just ordered a 40Gb IBM 60GXP to install RH7.1 on. I will be using it on my dual PIII setup :)

Anyway, with my Win2K partitions I have the system partition at 2Gb, Programs partition at 5Gb and the rest of the disk for data. In the past when I have messed with Linux, I have set the boot partition to 20Mb, the swap partition to 1Gb (I have 768Mb RAM) and the root partition to the rest of the disk.

Is this ok or is there a better way to do it?

Thanks.

kirek
12th July 2001, 22:20
phil,
My boss has been a Unix guy for like the last 15 years and when I set up my RedHat system last time he said that it's best to split up the filesystem a bit more.
Here is my system as I have it set up now on an 8GB drive

kirek@skywalker:~$ df-h
Filesystem Size Used Avail Use% Mounted on
/dev/hde1 992M 674M 266M 72% /
/dev/hde6 97M 37k 92M 1% /tmp
/dev/hde7 992M 20M 921M 3% /var
/dev/hde8 2.9G 1.3G 1.4G 47% /usr
/dev/hde9 2.2G 27M 2.0G 2% /home

/dev/hde1 is a primary partition
/dev/hde2 is an extended partition
/dev/hde5 starts the logical partitions (my swap partition)
/dev/hde6 starts the rest of the filesystem

I am running Slackware right now and it seems to fill up the '/' filesystem a little more for a full install. I think RedHat's default install needs less than 500MB for '/'.

I know dnar is not going to like the references but It may be easier to think like this: (help me out dnar)

your '/' (root) filesystem is like "c:\windows"
your '/usr' filesystem is where all the programs go (c:\Program fIles)?
your '/home' filesystem is where all personal data goes
then '/var' is where logs go and where email comes in initially so it is constantly changing
and '/tmp' is for temporary files (obviously)

From what I gather it's best to keep /var and /tmp on seperate partitions, if a runaway log fills up your root filesystem I guess it can cause problems.
I am just going on what my boss said, so I'm sure dnar will have more insight.

Oh and my swap partition is 512MB, I only have 256MB of RAM.
Probably overkill on the swap but I had the space.

my $.02
-Have fun

dnar
13th July 2001, 05:39
Originally posted by kirek


phil,


My boss has been a Unix guy for like the last 15 years and when I set up my RedHat system last time he said that it's best to split up the filesystem a bit more.


Here is my system as I have it set up now on an 8GB drive





kirek@skywalker:~$ df-h


Filesystem Size Used Avail Use% Mounted on


/dev/hde1 992M 674M 266M 72% /


/dev/hde6 97M 37k 92M 1% /tmp


/dev/hde7 992M 20M 921M 3% /var


/dev/hde8 2.9G 1.3G 1.4G 47% /usr


/dev/hde9 2.2G 27M 2.0G 2% /home





/dev/hde1 is a primary partition


/dev/hde2 is an extended partition


/dev/hde5 starts the logical partitions (my swap partition)


/dev/hde6 starts the rest of the filesystem





I am running Slackware right now and it seems to fill up the '/' filesystem a little more for a full install. I think RedHat's default install needs less than 500MB for '/'.





I know dnar is not going to like the references but It may be easier to think like this: (help me out dnar)





your '/' (root) filesystem is like "c:\windows"


your '/usr' filesystem is where all the programs go (c:\Program fIles)?


your '/home' filesystem is where all personal data goes


then '/var' is where logs go and where email comes in initially so it is constantly changing


and '/tmp' is for temporary files (obviously)





From what I gather it's best to keep /var and /tmp on seperate partitions, if a runaway log fills up your root filesystem I guess it can cause problems.


I am just going on what my boss said, so I'm sure dnar will have more insight.





Oh and my swap partition is 512MB, I only have 256MB of RAM.


Probably overkill on the swap but I had the space.





my $.02


-Have fun





Thats pretty good m8. Just to add, the "/" partition is where everything else lives, that is not on a seperate partition. Check my post in the software/hardware lounge???? re: NTFS/FAT32. I posted my partition schema there.





It is best to multi-partition, but the worst thing that can happen, is you make a partition too small......





If in doubt, use a minimalist approach:





/boot = 20M


/ = 2 to 3 Gigs


swap = 2 x RAM





My general starting point for good results:





/boot = 20M


/root = 200M


/ = 2 or 3 Gigs


/tmp = 1 to 2 Gigs


/var = 1 to 2 Gigs


/home = 1 Gig per user (2 or 3 Gig per power user!!!)


/usr = 3 Gigs ONLY if you compile code & kernels


/opt = 1 to 2 Gigs


swap = 2 x RAM





The good thing about many partition like this, is you can upgrade/re-install a distro and not loose your data and other programs (if installed in /opt). Some people prefer to have a /usr/local partition for "other" software.





But don't take my word for it, read these before sunrise or I'll cut your !@#$ off! :D




Pre-Installation Guide (http://linuxdoc.org/HOWTO/mini/Pre-Installation-Checklist/index.html)


Installation Strategies (http://linuxdoc.org/HOWTO/mini/Install-Strategies/index.html)


Installation HOWTO (http://linuxdoc.org/HOWTO/Installation-HOWTO/index.html)


Partition Mini-HOWTO (http://linuxdoc.org/HOWTO/mini/Partition/index.html)


Multi-disk HOWTO (http://linuxdoc.org/HOWTO/Multi-Disk-HOWTO.html)

phil
13th July 2001, 05:43
Cool, thanks guys :)

MechCD
13th July 2001, 11:26
Holy poo! I've got 4 gb to stuff linux into! i HAD (as in used to) keep it smushed into 1.5gb! But thats with just me, no other users. I can see why you would use 2x the amount of ram you have for swap, but what if i have 512 mb RAM ? I can't spare a gig of swap space :(I think 128mb might be sufficient, this thing isn't hosting any websites or files. I could always resize it with System Commander (not / though )

dnar
13th July 2001, 11:37
Originally posted by MechCD
Holy poo! I've got 4 gb to stuff linux into! i HAD (as in used to) keep it smushed into 1.5gb! But thats with just me, no other users. I can see why you would use 2x the amount of ram you have for swap, but what if i have 512 mb RAM ? I can't spare a gig of swap space :(I think 128mb might be sufficient, this thing isn't hosting any websites or files. I could always resize it with System Commander (not / though )

512MB RAM is HEAPS for a personal workstation. Linux does not require as memory is Winblows..... Although on second thoughts X & Gnome do!

With 512megs, I would be surprised if the swap ever went above 0%. I have 256megs on one machine & 192megs on another. Neither uses swap UNTIL I use the Gimp! I'm sure that thing has a memory leak.......

Your best option with a small h/disk is just the basic / and /boot setup + swap of say 128megs....

MechCD
13th July 2001, 11:37
Yoinkers, so how would this go over for me being the only user?

550 mb for /
2gb for /usr
1gb for /home
100mb for /var
100mb for /tmp
~128mb for swap

I will soon have 512mb of ram, I currently have 256mb. i have a little less than 5 gig to install linux, I can always mount my sapre windows partitions for extra personal file space.

I can resize everything except / after the install. I'll be reinstalling redhat 7.1

dnar
13th July 2001, 12:27
Originally posted by MechCD
Yoinkers, so how would this go over for me being the only user?



550 mb for /

2gb for /usr

1gb for /home

100mb for /var

100mb for /tmp

~128mb for swap



I will soon have 512mb of ram, I currently have 256mb. i have a little less than 5 gig to install linux, I can always mount my sapre windows partitions for extra personal file space.



I can resize everything except / after the install. I'll be reinstalling redhat 7.1

m8 /usr can be a little smaller if your DONT want to do comiles of anything, like the kernel......

Here is a dump of my /usr with 2 kernel source trees in /usr/src , the numbers on the left ar MB:

[wayne@Criten /usr]$ du -ms X11R6
81 X11R6
[wayne@Criten /usr]$ du -ms bin
117 bin
[wayne@Criten /usr]$ du -ms dict
1 dict
[wayne@Criten /usr]$ du -ms doc
1 doc
[wayne@Criten /usr]$ du -ms lib
351 lib
[wayne@Criten /usr]$ du -ms libexec
3 libexec
[wayne@Criten /usr]$ du -ms local
2 local
[wayne@Criten /usr]$ du -ms man
1 man
[wayne@Criten /usr]$ du -ms sbin
10 sbin
[wayne@Criten /usr]$ du -ms share
580 share
[wayne@Criten /usr]$ du -ms src
107 src
[wayne@Criten /usr]$ du -ms include
20 include

About 1.2GB. So 2GB is really playing it safe.....

/tmp and /var are too small at 100Mb........ Trust me. A lot of referneces will say otherwise, but not in my experience.

Partion size requirements all depends on what you want to install in terms of software and the services you will provide.

The multi-partion schema that I posted earlier was for my system, running Hylafax server, Windows 95/Win4Lin served from /opt and /var. I'm running my own DNS named server, FTP server, + more.

500MB for / is minimum so long as you have the directories you have listed on seperate partitions.

You can use "parted" a partion editor to resize partitions later, but it's not easy if all partions are near full. In fact almost impossible.

I still have several GB that is not partioned or formatted, waiting for a rainy day when I run out.

I once made the mistake of setting a drive with partitions too small, you learn the hard way. I also made a /root of 2GB once...... Its only the root users home directory, 100MB will never get used.....

MechCD
13th July 2001, 12:55
Ok, now the post is showing up, twice



Thanks for the info!

*****************
moderate mode on
*****************
No sweat! Your 2nd post is now deleted
*****************
moderate mode off
*****************

MechCD
13th July 2001, 12:59
I wonder if my cable company will let me run an ftp server.... just to do it :)

dnar
13th July 2001, 13:11
Mech! You gotta change that Avitar m8, your scaring me. (Sorry, It just reminds me of someone else that uses the very same Avitar.....)

MechCD
13th July 2001, 18:40
Wa! me like me avatar!

Uh-oh! we've found dnar weakness! the empty scientist avatar! muhuhuhuhuhahahahahahaha!

Nah, I'll change it tommorrow