Partitioning Using cfdisk (for Absolute)Aside from the time spent on the installation of a text-based install of Linux (for the unfamiliar) partitioning the hard drive is usually the biggest challenge. Experts tell newbies to put home in a separate partition. (And while it can be a good idea, it is not necessary.)
Others suggest making a partition for tmp or var. But these ideas are advanced and tend to make the install all the more painful for folks who will never utilize the benefits of the more complicated partitioning they suggest. I always just do the following...
What you really need are just 2 partitions. One to hold Linux. One for a swap partition (like "virtual memory" on Windows.) Granted, tooling around cfdisk can be awkward to the uninitiated, but what needs to be done is rather simple.
- Start cfdisk by typing cfdisk
- If you are installing Linux standalone -- without any other system on the same disk, then
delete any partitions present on the cfdisk screen
Make a new partition, taking up all but 100-500 MB of the disk.
The space left over is going to be for the swap space. A good rule of thumb is to leave twice your memory, if you know what size that is. So if you have 512 MB of RAM, leave about 1000 MB free after the first partition.
- Make this partition bootable
The default type is "Linux", so that partition is done.
- Next, make another new partition, taking up the rest of the drive.
- Change it's type to 82, Linux Swap
- Write the table to disk
You are done.
SCSI harddisks are named with sdx, where x is a hardisk letter. The disk with the lowest SCSI ID on the first controller will become sda, the next lower sdb, an so on.
If you have IDE harddisks, they are called hda, hdb, hdc, and so on instead, where hda is the master disk on the first controller, hdb is the slave disk on the first controller, hdc is the master disk on the second controller, and so on.
GNU/Linux systems often uses a partition scheme inherited from MS-DOS. With this, a harddisk can have up to four primary partitions. If you want more, you have to make one of these an extended partition where you can make several logical partitions. The partitions are named with the disk they belong to, and a number. The first primary partition on the first SCSI disk is therefore sda1, the second primary partition is sda2, and so on. The first and second logical partition on an extended partition on the first SCSI disk is sda5 and sda6, and so on. If this makes absolutely no sense to you at all, try to read .
you start cfdisk from the command line with the command
After you have started cfdisk you'll get an interface where the current partition table is listed with the names and some data about each partition, and some command buttons on the bottom of the screen. To change between partitions, use the up and down arrow keys. To change between commands, use the left and right arrow keys.
To delete an existing partition, highlight it with the up and down keys, select the Delete command with the left and right arrow keys, and press Enter.
To make a new partition, select the New command with the left and right arrow keys, and press enter. You'll get the choice between a primary and a logical partition. If you want a logical partition, the program will automatically make an extended partition for you. Then you must choose the size of the partition (in MB). If you can't enter a value in MB, return to the main screen with the Esc key, and select MB with the Units command.
To set the type of a partition, for bootable PReP, Linux swap or Linux ext2, highlight the actual partition, and select the Type command. You'll get a list over different types. Press space, and you'll get even more. Find what type you need, and enter the number at the prompt.
To be able to boot from a primary partition, you need to make it bootable. Highlight the actual partition and select the Bootable command.
When you are content with the layout of the disk, select the Write command. The partition table will be written to disk. Remember that this will destroy all data on partitions you have deleted or changed. You should therefore be very sure that you want to do this before actually press the Return key.
To exit the program, select the Quit command.