SCHEMES


With DOS, Microsoft Windows, and OS/2, a common practice is to use one primary partition for the active file system that will contain the operating system, the page/swap file, all utilities, applications, and user data. On most Windows consumer computers, the drive letter C: is routinely assigned to this primary partition. Other partitions may exist on the hard disk that may or may not be visible as drives, such as recovery partitions or partitions with diagnostic tools or data. (Microsoft drive letters do not correspond to partitions in a one-to-one fashion, so there may be more or less drive letters than partitions.)
Proponents of multiple partitions assert that a benefit of having multiple partitions is the ability to store data files on a partition separate from one containing the system files. If the system partition then becomes corrupted for any reason, irreplaceable user files stored on the independent partition would be able to be more easily retrieved (or recovered), not having been corrupted along with the system files. Another operating system (loaded from a LiveCD or USB, for example) could access the files on the (presumably) uncorrupted independent data partition without having to worry about the corrupted system partition at all.
Further, when data files are kept in a separate partition, if an operating system needs to be re-installed / restored (due to malware infiltration, for example), this can be done without risking damage to the data files (that in a single-partition system are stored along with the operating system files).
Windows 2000, Windows XP, Windows Vista, and Windows 7 include an inbuilt 'Disk Management' program which allows for the creation, deletion and movement of Windows (but not other types of) partitions. The Windows 7/Vista Disk Manager is not compatible with Windows 2000 or XP, nor, for the most part, other operating systems.
Other examples of partition management programs for Windows are Acronis Disk Director, Easeus Partition Master, Norton Ghost, and Perfect Disk. In some instances specialized recovery programs are supplied with retail consumer computers.
On Unix-based and Unix-like operating systems such as Linux and Mac OS X, it is possible to use multiple partitions on a disk device. Each partition can be used for a file system or as a swap partition.
Multiple partitions also allow directories such as /tmp, /usr, /var, or home directory space to be allocated their own file system. Such a scheme has a number of potential advantages:
• If one file system gets corrupted, the data outside that filesystem/partition stay intact, minimizing data loss.
• Specific file systems can be mounted read-only, or with the execution of setuid files disabled (thus enhancing security).
• Performance may be enhanced due to less disk head travel.
• A program which produces too much output (such as a system logging daemon) fills up only a single filesystem, therefore does not fill up more critical filesystems. (Often systems will not function correctly if / or /tmp fills up.)
However, the disadvantage of subdividing the drive into fixed-size partitions is that a file system in one partition may become full, even though other file systems still have plenty of usable space.
A good partitioning scheme requires the user to predict how much space each partition will need, which may be a difficult task; especially for new users. Logical volume management (LVM), often used in servers, increases flexibility by allowing data in volumes to expand into separate physical disks (which can be added when needed). Another option is to resize existing partitions when necessary. LVM allows this easily by resizing (shrinking) a filesystem, reducing the size of the logical volume containing that filesystem, allocating that freed space to another logical volume, and expanding (resizing) this other filesystem.
Typical Linux desktop systems use two partitions: one holding a file system mounted on "/" (the root directory) and a swap partition. (However, an almost unlimited number of partitions can be accommodated by Linux operating systems.)
By default, Mac OS X systems also use a single partition for the entire filesystem, but use a swap file inside the file system (like Windows) rather than a swap partition.
Multi-boot systems are computers where the user can boot into one of two or more distinct operating systems (OS) stored in separate storage devices or in separate partitions of the same storage device. In such systems a menu at startup gives a choice of which OS to boot/start (and only one OS at a time is loaded).
This is distinct from virtual operating systems, in which one operating system is run as a self-contained virtual "program" within another already-running operating system. (An example is a Linux OS "virtual machine" running from within a Windows OS).
Multi-boot systems are typically mixed-boot systems, with different OSes installed, although multiple copies of the same OS can be installed for safety, testing, and redundancy. A mixture of Windows, Mac OSX (facilitated by the switch to the x86 processor architecture), and Linux OSs (such as Ubuntu) on the same computer can therefore be accommodated.
On computers with a single hard disk multi-boot systems require multiple partitions on that hard disk. Each OS requires one or more special types of partitions whose file system may or may not be compatible with the those of other OSs on the hard disk. Tools to manipulate different types of filesystems may be specific for that type of filesystem. In general, Windows-based filesystem and partition tools have historically been used to manipulate partitions with Windows filesystems but not Linux or Mac OS X partitions. Linux-based partition managers can often (but not always) manage both Linux/Mac OS X and Windows partitions.
A particular problem of multi-boot systems is the mutual incompatibility between the bootloaders of different operating systems, which may compete with each other and independently overwrite important settings.
When most computers boot up, an MBR is referenced by the BIOS. This record indicates the partition in which the bootloader to be initially run is located. Each operating system usually attempts to change the MBR so that it points to the partition of the particular bootloader program installed by that OS. In other words, when Windows loads, it changes the MBR to point to the Windows partition in which the Windows bootloader is stored. When Mac OS X loads, it changes the MBR to point to the Mac OS X partition in which the Mac OS X bootloader is stored. When a Linux OS is loaded, it changes the MBR to point to the Linux partition in which the Linux OS bootloader (Grub) is stored.
Although all modern OSs include bootloaders that claim to be able to load other OSs as well as the primary OS, in practice this is not guaranteed. Subtle differences in file systems and ongoing changes to the various operating systems can eventually make the bootloaders of each OS unable to recognize the file systems of the competing OSs (and therefore prevent correct bootloading). One or more OSs may then appear to be "unbootable" on that computer. To rectify this, a new bootloader must be installed and configured and the MBR reset to point to the new bootloader.
A popular way to circumvent this problem is to install a small, independent "boot" partition (must be a primary partition) in which one specific bootloader is permanently stored. The MBR is then permanently set to always refer to the partition of this primary bootloader (and is never allowed to be changed or to refer to the partition of any other bootloader). This primary bootloader (in the boot partition) loads no OS directly. It merely presents a menu of operating system choices, and when one is chosen, its only function is to chainload the particular secondary bootloader of whichever OS is selected. Each secondary bootloader resides in the partition of the OS to which it belongs, and is only used to load its native OS (not any other OS). By utilizing this scheme, incompatibilities between different bootloaders, file systems and operating systems are avoided.


Disk partitioning is the act of dividing a hard disk drive into multiple logical storage units referred to as partitions, to treat one physical disk drive as if it were multiple disks. Partitions are also termed "slices" for operating systems based on BSD, Solaris or GNU Hurd. A partition editor software program can be used to create, resize, delete, and manipulate these partitions on the hard disk.


HOMETYPESSCHEMESRECOVERY