View Full Version : 2 Partition Layout Questions?
nightsky
08-15-2007, 09:16 PM
Given the large size of hdd ie. ata160gb. fast changing tech specs, I need updated info regarding, space allocation, drive labels ie hda or sda:
1)
/boot = ? /swap= ? / =? /usr =? /home =? /temp=?
2)
PC ide 1 & 2 is one slot w/ linux counter parts hda & hdb master/slave hdc & hdd
Now because my mobo ide 1 &2 are ata33 and ide3 & 4 are ata66 my hard drives are
on ide 3 & 4 hde & hdf, hdg & hdh. ide3 is hde win98 (master) hdf (slave is empty)
ide4 is hdg linux (master), hdh (slave is empty).
Is this correct?
3) Is ATA, SATA HPT366 considered sdX or hdX?
4) Regard my partition layout, once I have installed the os do I have to mount my partitions manually every time I boot up?
Do I have to designate partition for software programs? When I create a usr, do I have manually mount /home to create usr account?
Please suggest appropriate size I should make the different partitions based on their function?
I am trying to install slackware12. Thanks
ghost2003
08-16-2007, 12:04 AM
Given the large size of hdd ie. ata160gb. fast changing tech specs, I need updated info regarding, space allocation, drive labels ie hda or sda:
1)
/boot = ? /swap= ? / =? /usr =? /home =? /temp=?
There are lots of guides for partitioning but ill give you the values that I would use.
/boot=100Mb
/swap= ram size * 2
/= 400-500Mb
/var=2Gb
/tmp=2Gb
/usr= At least 5 Gb, it will hold all your applications so make it a good size
/home= whatever is left (all your files go here so make it big)
2)
PC ide 1 & 2 is one slot w/ linux counter parts hda & hdb master/slave hdc & hdd
Now because my mobo ide 1 &2 are ata33 and ide3 & 4 are ata66 my hard drives are
on ide 3 & 4 hde & hdf, hdg & hdh. ide3 is hde win98 (master) hdf (slave is empty)
ide4 is hdg linux (master), hdh (slave is empty).
Is this correct?
That sounds about right.
3) Is ATA, SATA HPT366 considered sdX or hdX?
Not sure. sdX is for SCSI devices. From what I can tell HPT366 is IDE.
4) Regard my partition layout, once I have installed the os do I have to mount my partitions manually every time I boot up?
Your system will lookup the file /etc/fstab to mount your file systems. (unless noauto is set for a FS, good for removable media)
man 5 fstab
Do I have to designate partition for software programs? When I create a usr, do I have manually mount /home to create usr account?
Applications should be installed in /usr.
/home should always be mounted. When you create a user the contents of /ets/skel are copied to the user's home directory which is /home/username by default.
kilgoretrout
08-16-2007, 11:13 AM
1. Your partitioning scheme seems overly complex to me. How is this system going to be used, eg server, desktop, etc? I find that when newbs set up a complex partitioning scheme they invariably find themselves running out of space on one or more partitions down the road. Also, the size of these partitions will depend on what you are doing so the question is impossible to answer. For a typical desktop I would suggest:
/swap = 2 X ram, but no more that 1GB unless you are suspending to disk
/home = depends on how much data you want to store on your home partition bearing in mind that the data stored here will be inaccessible to your win98 install. If you are dual booting, set up a separate FAT32 partition where you will store most of your heavy data like pictures, music, video, etc. That way, this data will be accessible to both windows and linux. This will cut down considerably on the size needed for your /home.
/ = 10GB is more than enough. I recommend everything other that /home and /swap should go on a single / partition. There is no need for separate /var, /tmp or /usr /boot on a desktop system in a single user environment. Servers are something different.
2 & 3. The naming conventions for your drives will depend on what kernel you are using. In all but the most recent kernels, your ide drives will use the hdx type naming and you have that right in #2. In the newer kernels, the ide interface control is being rolled into libata in the kernel and the ide drives are designated with the sdx type naming scheme similar to sata drives which have been designated sdx for some time.
4. Which partitions are mounted at boot is controlled by the /etc/fstab file in linux. All distros set up fstab to automount the system partitions on boot (/, /home, /swap, and if you have them, /var, /tmp, /boot, /usr, etc). Most modern linux distros will detect your windows partitions and either automount them or ask if you want them mounted. Some will mount windows FAT32 partitions read/write by default and some will mount read only by default.
Also, while I love slackware and it has many good qualities, I do not recommend slack for newbs. For a kde based desktop like slackware. I would recommend a more newb friendly distro like PCLOS or mandriva. For a gnome based dekstop, I'd recommend ubuntu or fedora.
LeftyAce
08-16-2007, 12:23 PM
For a home user system, I found it's best to keep it simple (and flexible) by having a /boot partition of whatever the default is (100MB sounds good; it was big enough for me to store 4 different kernels on).
Follow Kilgore's recommendation on Swap.
I then allocate the entire rest of the disk to /. That way /home is simply a folder, and you don't have to worry about how much room needs to be /tmp or /home or /bin or whatever.
nightsky
08-16-2007, 07:51 PM
Appreciates sooo much your help. I had posted questions on Linux forum but some folks are so condescending. I do read text files and search postings but it takes a lot of time and as so much changes direct response to specific ques. is so much more helpful. I am looking to setup my old box with an eye on learning to build a file server. Thanks again i will print this out. I love pcmech members
LeftyAce
08-16-2007, 08:06 PM
Glad we could help. I agree that getting into linux is a little difficult. Everything's really well documented (so people get frustrated when you ask for help) but the language used to document it takes getting used to (so it's not real good for new users!).
And a lot of what makes linux flexible, powerful and complicated isn't really necessary for a beginning home user (or an advanced one, for that matter).
Once you've got your feet wet I'm sure you'll be tweaking the setup at some point :-)
nightsky
09-11-2007, 01:34 PM
Partitioning anomoly when I try to partiton /dev/hdg1/root 15g
/dev/hdg2/usr 35g
/dev/hdg3/swap 1gb
/dev/hdg4/home 40g
/dev/hdg5/var 2g
/dev/hdg6/temp 2g
Total 95g but when I get to partition 4 and try to put in +40560M fdisk tells me I have exceeded the number of sectors available. Now if I start out with 160g and according to some measurement anomaly I read about and really only have 149gb I should still have at least 54g Left over- that I will leave empty for future share multiple OS partition since I don't know how to format it as such now?
Is it better to use the sector or cylinder measuring units. I always like using the one that starts with 1. lolol Now I am totally confused about how many cylinders or sectors =1gb.
One calculater said 1000M = 1gb another said 1024M=1gb.
It may seem to some like I am choosing an overly complicated file structure but I need it to experiment w/networking. Besides once I set this up I don't ever want to have to do it again
till I can do it in one day. I also believe the file structure I am trying to create will make my learning experiment simpler and save me a lot of reinstalling. Thanks
kilgoretrout
09-11-2007, 02:28 PM
That partition layout doesn't make sense to me. You can only have four primary partitions. In your setup they would be numbered hdg1 through hdg4. You are also creating extended/logical partitions. The first extended partition will be hdg5 in your setup. To create logical partitions, you must have a primary partition that serves as a container for the logical partitions. Extended/logical drives are a hack to get around the hardware limit of only four primary partitions.
However, from your post, you have used up all of your four primary partitions on /root(hdg1), /usr(hdg2), swap(hdg3), and /home(hdg4). But you are also creating, or attempting to create, logical/extended partitions, hdg5, and hdg6. You have to have a primary partition designated as a container which can't be used for anything else. I'm guessing that when you created hdg5, the first logical partition, the partitioning tool took hdg4 as the container.
Other observations. You don't want a separate partition for /root; I think what you intended was a separate partition for "/" which is how the root partition is properly designated. It's confusing because "/root" is the home directory for the root user and a subdirectory of "/", the root partition. Also, your swap partition is not given a mount point(/swap??) in the root filesystem; so don't try and create one. fdisk, cfdisk and parted, all command line linux partitioning utilities, are difficult and confusing to use. You will have a much easier time if you use gparted, a graphical front end for the parted utility that looks like a PM clone. There are two bootable livecds that feature gparted:
http://partedmagic.com/
http://gparted.sourceforge.net/
I told you slackware wasn't for newbs and the partitioning utilities available in the slack install are a big reason for that. I recommend making your partitions with gparted using one of the above livecds and then run your slack install, skip the partitioning, and use your previously created partitions. You just need to set the mountpoints from within the installation routine. The slack install routine will automatically detect your swap partition and ask you if you want to use it; say yes and it will properly configured swap for you.
nightsky
09-11-2007, 02:42 PM
thanks Kilgoretout, made a mistake how I wrote /dev/hdg1 - understant this is my home/root or just /...
As for the extended logical partitions I was trying to create /dev/hdg3 as the container with /swap, /temp, and /var... Can't I do this?
But why did I run out of Gigs???
I have never installed anything but Slackware ... other distros had trouble with my Soyo6BA+IV High Point ATA mobo which is what I am installing Slackware now to.
kilgoretrout
09-11-2007, 03:12 PM
I was trying to create /dev/hdg3 as the container with /swap, /temp, and /var... Can't I do this?
Yes, of course you can. But that's not what you previously posted. If that's what you want then hdg3 would be listed as "Extended" in fdisk -l and your logical partitions would be hdg5, hdg6 and hdg7 for swap, /tmp(not /temp) and /var, in no particular order. Since hdg3 is the container it will be 5 GB in size( 2GB each for /var and /tmp and 1GB for swap).
To give you an idea, here's some fdisk output on a sata hard drive with sda2 as the container for the logical partitions:
Device Boot Start End Blocks Id System
/dev/sda2 * 3 25710 206499510 5 Extended
/dev/sda5 3 133 1052226 82 Linux swap / Solaris
/dev/sda6 134 9271 73400953+ 83 Linux
/dev/sda7 9272 22438 105763896 83 Linux
/dev/sda8 22439 25710 26282308+ 83 Linux
But why did I run out of Gigs???
That's really hard for me to determine as I'm not sure exactly what you did with fdisk given your post. It's pretty confusing to me. I still think it likely that a primary partition you thought was available was grabbed by fdisk for your extended partition container. Take a look at those gparted livecds; it makes slack installs much easier.
nightsky
09-11-2007, 05:25 PM
thanks kilgoretrout, ok I tried again since my last post paying attention to what you had said about the container so I /dev/hdg1 15g
/dev/hg2 35g
/dev/hdg3 extended 5g for
/dev/hdeg5 -swap 1gb
/dev/hdg6 -var 2g
/dev/hdg7 -tmp 2g
But fdisk said I had gone beyond the last default cylinder and I tried it with sector units to but I am having trouble converting bytes to sectors to megabytes and gigabytes... too many digits! lolol Will continue to try... there is a calculater online I have tried to use but I still come out short even though fdisk reports I am starting out with 160Gb = 312,500,500 sectors? The numbers are staggeringly numbing! If 1 sector = 512bytes, 2 sectors = 1K then X = 1GB ... this is what I fell asleep trying to do. I am run slackware12 on root and swap for the entire 160gb...of course hal has some tight demands.
Just for you lilgoretrout 1st one is funny and the second one works: http://www.fdisk.com/
http://www.tldp.org/HOWTO/Partition/fdisk_partitioning.html#mixed
kilgoretrout
09-11-2007, 06:48 PM
cfdsik is a lot easier than fdisk and available during the slack install:
http://www.slackbasics.org/html/installation.html#AEN424
I can't remember the last time I tried to partition anything with fdisk and barely remember cfdisk since the wide availability of bootable cds with gparted.
vBulletin® v3.7.0, Copyright ©2000-2008, Jelsoft Enterprises Ltd.