Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've installed Ubuntu Server 10.04, for serving as a samba server and development web server in my home network, on the following box:

  • Pentium III 733MHz @133MHz
  • 768 MB RAM
  • HD 1: 20.5 GB
  • HD 2: 41 GB

What I did, as far as partitioning is concerned, is as followed:

HD 1:

  • Primary partition [/] 19 GB
  • Logical partition [swap] 1.5 GB

HD 2:

  • Logical partition [/home] 41 GB

Is this a reasonable configuration? Coming from a predominantly Windows (and a little bit of Mac OS X) environment, I believe a primary partition is needed for booting the system. But I think I read that I could do away with a primary partition altogether for a linux environment, and make it a logical partition as well, because Linux can boot from a logical partition. I believe this was suggested to make creating a multi boot system easier. While I don't have a need for a multi boot system though, is using only logical partitions still advisable nonetheless?

Furthermore, when printing out the partitioning info, I expected partitions to be named consecutively as:

/dev/sda1 Linux
/dev/sda2 Linux swap / Solaris

/dev/sdb1 Linux

But got:

/dev/sda1 Linux
/dev/sda2 Extended
/dev/sda5 Linux swap / Solaris

/dev/sdb1 Extended
/dev/sdb5 Linux

Now, if memory serves me correct, an extended partition is indeed needed for a logical partition. This is correct, right? However, what I don't understand is why the logical partitions are numbered sda5 and sdb5 in stead of sda3 and sdb2 respectively. Is this a sign that there are still undiscovered / hidden partitions on both drives? Or is this a conventional naming strategy I was unaware of?

share|improve this question
up vote 1 down vote accepted

It's a very reasonable configuration for two drives and for a home server/dev machine. If you were only on one drive, I'd avoid /home altogether, personally; if you don't make a separate /home partition, files located on that path would simply share space with everything else on the / partition. In Unix, you mount partitions or devices (such as CD/DVD-ROM drives) onto paths; when mounted, all files under that path are then accessed from the partition or device mounted there.

Think of / as your C: drive--the system and all your software will go there, while /home is where you will keep all of your user data, your files, your source code, etc.

As for sda5 et al, you're right that it's a naming strategy: sda1 through sda4 are primary partitions, and sda5 on are logical partitions. Making logical partitions is simply a default behavior in the interest of preserving the limited number of primary partitions available. It would work equally as well if it was sda2 or sda5.

I've actually never booted from a logical partition (your boot partition is / here; the boot files actually live under /boot) and therefore don't know how wise or not it is, but I don't think you need to think about it here either since you specify you are not expecting to multi-boot this machine. Logical partitions are a mechanism for getting around the 4 primary partition limit and many boot managers only have the capability to boot from a primary partition.

share|improve this answer
Alright, thank you for the reassurance. You said: If you were only on one drive, I'd avoid /home altogether, personally. I wasn't even aware of this possibility. Where would one typically keep all the user data, in such a setup, then? Lastly, if possible, would you be able to say something meaningful about using a primary vs. logical partition as a system partition, as well? Thanks. – Decent Dabbler Mar 9 '12 at 19:35
I edited to add some more. – zigg Mar 9 '12 at 19:58
OK, sounds reasonable enough indeed. Thanks again zigg. – Decent Dabbler Mar 9 '12 at 21:12

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .