Book Image

Manage Partitions with GParted How-to

By : Curtis Gedak
Book Image

Manage Partitions with GParted How-to

By: Curtis Gedak

Overview of this book

Modern disk drives can store vast amounts of information. To effectively use all of this space, you can partition disk drives into separate storage areas. These separate storage areas enable you to organize your data, improve system performance, and install and use many operating systems"Manage Partitions with GParted" is a practical, hands-on guide providing you with step-by-step instructions to effectively organize your hard drive. You start with simple tasks that help you identify drives and partitions and progress to advanced tasks such as preparing for new operating systemsThis book provides ample screen shots to help you effectively use your hard drive. You start with simple tasks that help you to identify drives and partitions. Next you progress to tasks covering the basics of how to grow, shrink, move, and copy partitions without data loss. You finish with advanced tasks that use the basics to prepare for new operating systems, migrate space between partitions, and share data among Windows, Linux, and Mac OS X. By following through the tasks, from basic to advanced, this book will empower you with the knowledge and tools to Manage Partitions with GParted.
Table of Contents (7 chapters)

Creating a new partition (Should know)


In this recipe we will cover the steps to create a new partition for storing data. We also discuss options for creating different types of partitions.

How to do it...

  1. Select unallocated space on a disk device.

  2. Choose the Partition | New menu option and a new partition window is displayed.

  3. Optionally, you can set the partition New size to a smaller value.

    Tip

    To adjust the partition size click on one of the side arrows on the partition graphic (shown in the following screenshot) and drag it to left or right. Alternatively enter a new value for New Size or click on the up and down spin button arrows beside the number.

    To move the entire partition click on the partition and drag it to left or right.

  4. Select a File system for the partition; for example, fat32. A list of default file systems used by operating systems can be found in the Identifying partitions and actions available recipe.

  5. Enter a Label for the file system; for example, MYDATA.

  6. Click on Add.

  7. Choose the Edit | Apply All Operations menu option to apply the queued operations to disk.

  8. Click on Apply to apply operations to disk.

  9. Click on Close to close the apply operations to disk window:

How it works...

The above steps instruct GParted to create a partition using all of the unallocated space. Further, the partition is formatted with a file system with the label specified (for example, MYDATA).

We left many options at the default values. Some other things to consider are:

  • Creating the partition as a different type. For example, with an MSDOS partition table you might try using Create as an Extended Partition, or Create as a Logical Partition. Read on to learn why you might want to use different partition types.

  • Setting the Align to drop-down list to Cylinder setting if you wish to maintain compatibility with older operating systems, such as DOS.

There's more...

One of the most common partition tables in use is the MSDOS partition table. This partition table has a limitation of four partition slots. The four slots can consist of up to four primary partitions, or up to three primary partitions and one extended partition. The extended partition is a special type of partition that can contain multiple logical partitions. If you wish to have more than four partitions in an MSDOS partition table, you need to create one extended partition. Inside the extended partition you can create more than one logical partition.

The choice of partition type is important because after a partition has been created, the partition type cannot be easily changed. For example, a primary partition cannot be easily turned into a logical partition, or vice versa. To change the partition type the partition must be deleted.

The three partition types use device numbers in the device name as follows:

  • Primary partitions use device numbers 1 through 4 (for example, /dev/sda3).

  • An extended partition uses one of the device numbers from 1 through 4.

  • Logical partitions use device numbers 5 and higher (for example, /dev/sda12).

Note that only one extended partition is permitted in an MSDOS partition table.

The following diagram depicts a primary partition (sda1), followed by an extended partition (sda2), which contains three logical partitions (sda5, sda6, and sda7).

The extended and logical partitions in this example were set up by first creating the extended partition sda2. Then, within the extended partition we created the logical partitions sda5, sda6, and sda7.

Managing partition flags

Most computer users will not need to be concerned about setting partition flags. However, for users configuring more complex storage scenarios, such as RAID or Logical Volume Management (LVM), the following steps demonstrate how to toggle partition flags to be set or unset.

  1. Select an existing partition; for example, a partition that has already been created.

  2. Choose the Partition | Manage Flags menu option and a Manage flags window will be displayed.

  3. As shown in the following screenshot, select the checkbox to toggle the flag between set and unset (for example, lvm)

  4. Click on Close and the flag will be set or unset as you indicated.