LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
LinkBack Search this Thread
Old 06-01-2003, 01:52 PM   #1
enk0d
Member
 
Registered: May 2003
Location: Miami, Florida. U.S.A
Distribution: Slackware 9.1
Posts: 102

Rep: Reputation: 15
Multiple Partitions: What is best?


Hello everyone,

I recently did some research on partitioning in Linux and some people would say it is better to make separate partitions for /boot /usr and /var so that your logs don't fill up your hardrive space and as for the swap file it should be twice the size of RAM you have in your PC but alot of the times people won't abide by those rules i would only use 100MB as to using 1024MB for 512MB of RAM.

In all honesty guys does it really matter making multiple partitions? And if it was up to you how would you make your partitions? (Size, Type)

I am asking because i would like to get some feedback on what is the best way to partition seeing how there are different ways of going about it.
 
Old 06-01-2003, 04:55 PM   #2
dcm
LQ Newbie
 
Registered: May 2003
Posts: 17

Rep: Reputation: 0
Good idea to have /home on a seperate partition - so if you reinstal, upgrade or switch distros you can leave all your work, pics, mp3s etc untouched.
Also if you intend to compile alot of stuff yourself as opposed to install tgz (or rpms/debs), consider a seperate partion for /usr/local. That way, even if you need to recompile after an upgrade, you can have all the source code ready in /usr/local/src
 
Old 06-01-2003, 05:03 PM   #3
Proud
Senior Member
 
Registered: Dec 2002
Location: England
Distribution: Used to use Mandrake/Mandriva
Posts: 2,794

Rep: Reputation: 116Reputation: 116
They say it's good to have a seperate /var for servers, so logs cant grow to swamp your main harddrive and thus lock up your system.
A seperate /boot could be useful if you have many kernels and distros installed and are testing tweaks maybe
 
Old 06-01-2003, 07:44 PM   #4
enk0d
Member
 
Registered: May 2003
Location: Miami, Florida. U.S.A
Distribution: Slackware 9.1
Posts: 102

Original Poster
Rep: Reputation: 15
Well let me ask you this seeing how i currently have only a 20gb drive on this PC of mine what do you think would be the best course of action as far as partitioning goes? i would like ot have all those partitions but just not sure on size though.

I have been able to find much on the actually size required for such partitions
 
Old 06-01-2003, 09:58 PM   #5
wartstew
Member
 
Registered: Apr 2002
Location: Albuquerque, NM USA
Distribution: Slackware, Ubuntu, Debian, Maemo
Posts: 464

Rep: Reputation: 30
How about 3 gigs for /, 10 megs for /boot, 200-1000 megs for /var (depending on what you will be doing), then the rest for /home? Don't forget about 200 megs or more for swap. If you do a lot of source code compiling, you'll might need to symlink /usr/src to somewhere in the "home" partition.

These would be pretty good "ballpark" numbers. If you are building a "production server" for somebody, you can start with this as a prototype, then tweek the values for the final version.
 
Old 06-01-2003, 10:12 PM   #6
wartstew
Member
 
Registered: Apr 2002
Location: Albuquerque, NM USA
Distribution: Slackware, Ubuntu, Debian, Maemo
Posts: 464

Rep: Reputation: 30
The swap as twice the size as your RAM is more of a guide for how much RAM you should buy for your system. If you find that in order for your system to do the the things you want, that you need swap space that is many times your RAM size, then you really need more RAM.

These days, a lot of us have a lot more RAM then we need and could often get away with no swap space. For my Linux machines that I use for home/desktop uses, they typically have about 256 megs of RAM, I usually only have about 200 megs swap space which seems to be overkill because the system usually only uses about 20% of it at the most!
 
Old 06-01-2003, 10:21 PM   #7
itsjustme
Senior Member
 
Registered: Mar 2003
Location: Kwajalein
Distribution: Slackware, Ubuntu, Smoothwall
Posts: 1,569

Rep: Reputation: 45
Here's what I did after doing some research on partitions.
I really have no reason for this, other than just as an exercise.

[slacker@bsslack ~] $ df -h
Filesystem Size Used Avail Use% Mounted on
/dev/hda3 4.7G 186M 4.3G 5% /
/dev/hda2 96M 5.8M 84M 7% /boot
/dev/hda5 4.7G 1.8G 2.7G 39% /usr
/dev/hda6 1.9G 33M 1.7G 2% /usr/local
/dev/hda7 1.9G 65M 1.7G 4% /home
/dev/hda8 1.9G 57M 1.7G 4% /var
/dev/hda9 972M 339M 583M 37% /opt
/dev/hda10 470M 9.5M 435M 3% /tmp
/dev/hda11 11G 33M 10G 1% /LFS

Swap is /dev/hda1. It was a default, sort of, in the slack 9 install.
And I only used 128MB for swap, but I have 360MB of memory.

One of these days I'm actually gonna get around to doing that LFS project.

Regards...

Last edited by itsjustme; 06-01-2003 at 10:23 PM.
 
Old 06-01-2003, 10:28 PM   #8
fancypiper
Guru
 
Registered: Feb 2003
Location: Sparta, NC USA
Distribution: Ubuntu 10.04
Posts: 5,141

Rep: Reputation: 55
# Linux filesystem structure
Directory Navigation Help File
Filesystems, Directories, and Devices Help File
Proper Filesystem Layout
 
Old 06-01-2003, 10:33 PM   #9
kazuni
Member
 
Registered: May 2003
Location: Hong Kong
Distribution: Android on HTC Hero
Posts: 256

Rep: Reputation: 30
Code:
kazuni@kazslack:~$ df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/hda2             6.0G  2.6G  3.2G  45% /
/dev/hdb1              15G  2.4G   12G  17% /mnt/mandrake
/dev/hdb6              22G   21G  236M  99% /windows/D
/dev/hda1              69G   20G   49G  30% /windows/C
/dev/sda1              23G   11G   12G  48% /windows/E
/dev/sda6             4.4G  702M  3.8G  16% /windows/G
/dev/scd0             478M  478M     0 100% /mnt/cdrom
/dev/scd1             663M  663M     0 100% /mnt/cdrom2
kazuni@kazslack:~$
this is mine
 
Old 06-01-2003, 10:44 PM   #10
fancypiper
Guru
 
Registered: Feb 2003
Location: Sparta, NC USA
Distribution: Ubuntu 10.04
Posts: 5,141

Rep: Reputation: 55
Code:
[phil@uilleann phil]$ df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/hda6             3.4G  2.5G 1009M  72% /
/dev/hda2              94M   15M   74M  17% /boot
/dev/hda8             8.5G  1.7G  6.9G  19% /home
/dev/hda3             3.4G  2.5G  1.0G  71% /mnt/gentoo
/dev/hda7             3.4G  2.2G  1.0G  69% /mnt/mandrake
/dev/hda1             9.3G  2.7G  6.6G  29% /mnt/winc
none                  251M     0  250M   0% /dev/shm
/dev/hda9             8.5G  1.1G  7.4G  13% /snd
/dev/hda2              94M   15M   74M  17% /mnt/gentoo/boot
/dev/hda9             8.5G  1.1G  7.4G  13% /mnt/gentoo/pub
[phil@uilleann phil]$ free
             total       used       free     shared    buffers     cached
Mem:        513804     471280      42524          0      52360     268100
-/+ buffers/cache:     150820     362984
Swap:       530104      25124     504980
[phil@uilleann phil]$
I am compiling KDE in Gentoo, doing an upgrade using urpmi in Mandrake (tha'ts why some partitions are mounted several times), listening to my piping oggs and browsing LQ.

Gotta keep the old connection and cpu hot and make sure my memory works.

Last edited by fancypiper; 06-01-2003 at 10:56 PM.
 
Old 06-02-2003, 07:45 AM   #11
snocked
Member
 
Registered: Dec 2002
Location: St. Louis, MO
Distribution: Slackware 9.1
Posts: 480

Rep: Reputation: 30
How do you create partitions other than swap and root in fdisk?

I couldn't figure out how to create a partition for /usr or /home.

Are there special IDs or what?
 
Old 06-02-2003, 08:52 AM   #12
wartstew
Member
 
Registered: Apr 2002
Location: Albuquerque, NM USA
Distribution: Slackware, Ubuntu, Debian, Maemo
Posts: 464

Rep: Reputation: 30
You just create the additional partitions (you may have to make them extended or "logical" partitions so you don't run out of you precious "primary" ones). Then you edit /etc/fstab to describe how you want them mounted.
 
Old 06-02-2003, 08:55 AM   #13
snocked
Member
 
Registered: Dec 2002
Location: St. Louis, MO
Distribution: Slackware 9.1
Posts: 480

Rep: Reputation: 30
Oh okay. I was wondering how you set them to their locations.
 
Old 06-02-2003, 11:14 AM   #14
wartstew
Member
 
Registered: Apr 2002
Location: Albuquerque, NM USA
Distribution: Slackware, Ubuntu, Debian, Maemo
Posts: 464

Rep: Reputation: 30
It's all in /etc/fstab.

Have a look, or do a "man fstab"
 
Old 06-02-2003, 11:28 AM   #15
itsjustme
Senior Member
 
Registered: Mar 2003
Location: Kwajalein
Distribution: Slackware, Ubuntu, Smoothwall
Posts: 1,569

Rep: Reputation: 45
Quote:
Originally posted by snocked
How do you create partitions other than swap and root in fdisk?
Go to the slack book.

Go down to the partitioning section.

Excerpt:
--------------------------------
Now we create the partitions with the n command:

Command (m for help):n
Command action
e extended
p primary partition (1-4)
p
Partition number (1-4):1
First cylinder (0-1060, default 0):0
Last cylinder or +size or +sizeM or +sizeK (0-1060, default 1060):+64M
--------------------------------

This, and the rest of the text there, is what I used for mine using fdisk.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
multiple partitions question scales Linux - Newbie 3 08-21-2005 11:25 AM
multiple partitions noz6 Linux - Newbie 4 03-06-2005 07:32 PM
Reading multiple partitions gauntalus Linux - Software 7 12-27-2004 01:17 PM
multiple /home partitions? joe6pack Linux - Newbie 3 04-30-2004 11:55 AM
Multiple Partitions Ju Deddo Koinu Linux - Newbie 4 05-07-2003 02:37 PM


All times are GMT -5. The time now is 06:18 AM.

Main Menu
 
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration