Basic concepts

In order to understand the basics of dual-booting, it is necessary to be aware of a small number of related concepts.

Summary

  • Hard disks can be split up into partitions

  • Each partition is treated as if it was a separate hard disk drive

  • Operating systems must be installed on separate partitions

  • The boot loader decides which operating system to start

Hard disk partitions

Your hard disk can be split up into many separate partitions, in a similar way that a large room can be partitioned by dividing walls. Each partition, while still being on the same physical device, is treated as being entirely separate to other partitions - it is as if you have multiple hard drives installed rather than just one. In Windows, each partition has its own drive letter. You might have a C, D and E drive which, while being treated as separate devices, are in fact all stored on the same hard disk.

For operating systems to be able to co-exist on the same computer, they should be installed onto separate partitions. This means that to dual-boot between Ubuntu and Windows, you must partition your hard disk in a suitable manner.

By partitioning your disk, you are splitting the storage capacity of your hard disk into separate, differently-sized chunks. You should choose the sizes of each partition carefully to prevent running out of storage space on a partition.

Because each partition is treated as a separate device, each partition must be formatted with a filesystem. Formatting is the process of creating a filesystem on a partition. A filesystem is a method which an operating system uses to store your files - there are many different filesystems, each with its own advantages and limitations. Common filesystems used in a dual boot system include NTFS, FAT32, and ext3. NTFS is the default filesystem used by Windows. ext3 is a native Linux filesystem that can be accessed from Windows using various tools such as ext2fs. FAT32 (also know as vfat) is a filesystem to which Linux can write safely. Hence, in a dual system, a FAT32 filesystem is commonly used as a way of sharing files between Linux and Windows.

There are two different types of partition. Primary partitions can contain only one filesystem and a maximum of four of them can be used on a hard disk. Extended partitions can contain many other partitions, but only one can be used per hard disk.

The boot-loader

When your computer initially starts up, it quickly checks itself for problems and then passes control over to a program called a boot loader. The boot loader stores a list of operating systems and partitions stored on the computer, and decides which operating system to start up. Once it makes a choice, the operating system it selected is then in control of the computer.

When setting-up a dual-boot system, the boot loader must be made aware of the changes which are being made. Ubuntu will install a boot loader for you, which allows you to choose which operating system to start each time the computer boots up. This boot loader is called GRUB.