We already learned from "Structure of a hard disk" what partitions are used for; and you initially set up your partitions during the install process. DiskDrake allows you, to some extent, to resize your partitions, move them, etc.
![]() | DiskDrake is a very powerful, and therefore dangerous tool. Misuse of it can very easily lead to loss of data in your hard drive. Consequently, you are advised to take some protective measures before using it:
|
DiskDrake enables you to configure four types of disks on your machine, each one accessible through a different tab:
Samba: allows to mount on your local machine distant folders served by a Samba server, typically a windows server.
NFS: same as above but for directories served by NFS type servers (all Unix OSs.)
Removable devices: control most options that affect removable devices as floppy and CD disks.
hda: this tab is in fact repeated for each physical hard drive on the machine. The name of the tab is the name of the drive in Linux notation. The tool available here allows you to control the partitioning of that drive; this is what we are describing below.
The hard disks partitioning tab (figure 14-21) is divided in four zones:
On the top: The structure of your hard drive(s). When you launch DiskDrake it shows the current structure of the drive, and is modified in real time when you modify your partitions. Note however that changes are not made effective on the drive until you press the Done button.
On the left: a menu applying to the partition currently selected in the above diagram.
On the right: a description of the selected partition.
At the bottom: buttons for taking general actions. Note that the Toggle to expert mode button allows you to access expert (even more dangerous) functions.
So this is what the current /home partition looks like (figure 14-22), before any modification. We choose to shrink this partition in order to create the new one on the freed space.
As you may have guessed, just click on the Resize button. A dialog will appear (figure 14-23), in which you choose a new size for that /home partition.
When this is done, you will notice that the graphic representation of your hard-drive has changed, the /home partition became smaller, and an empty space appeared on the right. Click on that empty space and then on the button Create that just just appeared. A dialog (figure 14-24) where you can choose the parameters for the new partition pops up. Change the start sector if you want to leave a new free space between the two /home and /home/ftp partitions. Define the needed size, choose the file system you want (generally Linux native) and then enter the mount point of that partition, in our case /home/ftp.
This is what our projected partition table looks like now (figure 14-25).
![]() | Up until now, we have not really modified the partition table, we just redesigned and rejected it. Further steps will effectively make our changes active, so if you do not intend to modify your system, click on the Undo button until you come back to the beginning. |
You finally need to format (prepare to host files) the newly created partition: click on it, then on the Format button. Confirm the writing of the partition table, and then the formating of the partition. You may be asked to reboot the computer to make changes effective.
Among many available features, the save and restore from file is one of the more interesting. It allows you to save the current partition table to a file on a disk (floppy for example) and then restore it in case you totally messed up your partition table. It can prove useful as long as you did not reformat partitions, otherwise data will be lost.