Disk partitioning or disk slicing is the creation of one or more regions on
secondary storage
Computer data storage or digital data storage is a technology consisting of computer components and Data storage, recording media that are used to retain digital data. It is a core function and fundamental component of computers.
The cent ...
, so that each region can be managed separately. These regions are called partitions. It is typically the first step of preparing a newly installed disk after a partitioning scheme is chosen for the new disk before any
file system is created. The disk stores the information about the partitions' locations and sizes in an area known as the partition table that the operating system reads before any other part of the disk. Each partition then appears to the operating system as a distinct "logical" disk that uses part of the actual disk.
System administrator
An IT administrator, system administrator, sysadmin, or admin is a person who is responsible for the upkeep, configuration, and reliable operation of computer systems, especially multi-user computers, such as Server (computing), servers. The ...
s use a program called a
partition editor to create, resize, delete, and manipulate the partitions. Partitioning allows the use of different filesystems to be installed for different kinds of files. Separating user data from system data can prevent the system partition from becoming full and rendering the system unusable. Partitioning can also make backing up easier. A disadvantage is that it can be difficult to properly size partitions, resulting in having one partition with too much free space and another nearly totally allocated.
History
One of the earliest such forms of segmentation of a disk drive was IBM's 1966
usage in its
CP-67 operating system of ''minidisk'' as a separate segment of a hard disk drive.
Data General
Data General Corporation was an early minicomputer firm formed in 1968. Three of the four founders were former employees of Digital Equipment Corporation (DEC).
Their first product, 1969's Data General Nova, was a 16-bit minicomputer intended to ...
's
RDOS operating system for their
Nova computers used the term ''partition'' for subregions of a disk. Each partition had its own directory.
IBM in its 1983 release of
PC DOS version 2.0 also used the term ''partition'' to describe dividing a block storage device such as an
HDD into physical segments. The term's usage is now ubiquitous. Other terms used include ''logical disk'',
''minidisk'',
''portions'',
''pseudo-disk'',
''section'',
''slice''
and ''virtual drive''.
Partitioning schemes
DOS, Windows, and OS/2
With
DOS,
Microsoft Windows
Windows is a Product lining, product line of Proprietary software, proprietary graphical user interface, graphical operating systems developed and marketed by Microsoft. It is grouped into families and subfamilies that cater to particular sec ...
, and
OS/2
OS/2 is a Proprietary software, proprietary computer operating system for x86 and PowerPC based personal computers. It was created and initially developed jointly by IBM and Microsoft, under the leadership of IBM software designer Ed Iacobucci, ...
, 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 HDD that may or may not be visible as drives, such as recovery partitions or partitions with diagnostic tools or data. (Windows drive letters do not correspond to partitions in a one-to-one fashion, so there may be more or fewer drive letters than partitions.)
Microsoft
Windows 2000
Windows 2000 is a major release of the Windows NT operating system developed by Microsoft, targeting the server and business markets. It is the direct successor to Windows NT 4.0, and was Software release life cycle#Release to manufacturing (RT ...
,
XP,
Vista, and
Windows 7
Windows 7 is a major release of the Windows NT operating system developed by Microsoft. It was Software release life cycle#Release to manufacturing (RTM), released to manufacturing on July 22, 2009, and became generally available on October 22, ...
include a '
Disk Management' program which allows for the creation, deletion and resizing of FAT and NTFS partitions. The Windows Disk Manager in Windows Vista and Windows 7 utilizes a
1 MB partition alignment scheme which is fundamentally
incompatible with Windows 2000, XP, OS/2, DOS as well as many other operating systems.
Unix-like systems
On
Unix
Unix (, ; trademarked as UNIX) is a family of multitasking, multi-user computer operating systems that derive from the original AT&T Unix, whose development started in 1969 at the Bell Labs research center by Ken Thompson, Dennis Ritchie, a ...
-based and
Unix-like
A Unix-like (sometimes referred to as UN*X, *nix or *NIX) operating system is one that behaves in a manner similar to a Unix system, although not necessarily conforming to or being certified to any version of the Single UNIX Specification. A Uni ...
operating systems such as
Linux
Linux ( ) is a family of open source Unix-like operating systems based on the Linux kernel, an kernel (operating system), operating system kernel first released on September 17, 1991, by Linus Torvalds. Linux is typically package manager, pac ...
,
macOS
macOS, previously OS X and originally Mac OS X, is a Unix, Unix-based operating system developed and marketed by Apple Inc., Apple since 2001. It is the current operating system for Apple's Mac (computer), Mac computers. With ...
,
BSD
The Berkeley Software Distribution (BSD), also known as Berkeley Unix or BSD Unix, is a discontinued Unix operating system developed and distributed by the Computer Systems Research Group (CSRG) at the University of California, Berkeley, beginni ...
, and
Solaris, it is possible to use multiple partitions on a disk device. Each partition can be formatted with a
file system or as a
swap partition.
Multiple partitions allow directories such as
/boot,
/tmp,
/usr,
/var, or
/home to be allocated their own filesystems. Such a scheme has a number of advantages:
* If one file system gets corrupted, the data outside that filesystem/partition may stay intact, minimizing data loss.
* Specific
file systems can be mounted with different parameters, e.g.,
read-only, or with the execution of
setuid
The Unix and Linux access rights flags setuid and setgid (short for ''set user identity'' and ''set group identity'') allow users to run an executable with the file system permissions of the executable's owner or group respectively and to chang ...
files disabled.
* A runaway program that uses up all available space on a non-system filesystem does not fill up critical filesystems.
* Keeping user data such as documents separate from system files allows the system to be updated with lessened risk of disturbing the data.
A common minimal configuration for Linux systems is to use three partitions: one holding the system files mounted on "/" (the
root directory
In a Computing, computer file system, and primarily used in the Unix and Unix-like operating systems, the root directory is the first or top-most Directory (computing), directory in a hierarchy. It can be likened to the trunk of a Tree (data st ...
), one holding user configuration files and data mounted on /home (
home directory
A home directory is a directory (file systems), file system directory on a multi-user operating system containing computer file, files for a given user (computing), user of the system. The specifics of the home directory (such as its name and loc ...
), and a swap partition.
By default, macOS systems also use a single partition for the entire filesystem and use a
swap file inside the file system (like Windows) rather than a swap partition.
In Solaris, partitions are sometimes known as slices. This is a conceptual reference to the slicing of a cake into several pieces.
The term "slice" is used in the
FreeBSD
FreeBSD is a free-software Unix-like operating system descended from the Berkeley Software Distribution (BSD). The first version was released in 1993 developed from 386BSD, one of the first fully functional and free Unix clones on affordable ...
operating system to refer to
Master Boot Record
A master boot record (MBR) is a type of boot sector in the first block of disk partitioning, partitioned computer mass storage devices like fixed disks or removable drives intended for use with IBM PC-compatible systems and beyond. The concept ...
partitions, to avoid confusion with FreeBSD's own
disklabel-based partitioning scheme. However,
GUID Partition Table partitions are referred to as "partition" worldwide.
Multi-boot systems

Multi-boot systems are computers where the user can boot into more than one distinct operating system (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 Windows OS "virtual machine" running from within a Linux OS.)
GUID Partition Table
The GUID Partition Table (
Globally Unique IDentifier) is a part of the
Unified Extensible Firmware Interface
Unified Extensible Firmware Interface (UEFI, as an acronym) is a Specification (technical standard), specification for the firmware Software architecture, architecture of a computing platform. When a computer booting, is powered on, the UEFI ...
(UEFI) standard for the layout of the
partition table on a physical
hard disk
A hard disk drive (HDD), hard disk, hard drive, or fixed disk is an electro-mechanical data storage device that stores and retrieves digital data using magnetic storage with one or more rigid rapidly rotating hard disk drive platter, pla ...
. Many operating systems now support this standard. However, Windows does not support this on BIOS based computers.
Partition recovery
When a partition is deleted, its entry is removed from a table and the data is no longer accessible. The data remains on the disk until it is overwritten.
Specialized recovery utilities may be able to locate ''lost'' file systems and recreate a partition table which includes entries for these recovered file systems. Some disk utilities may overwrite a number of beginning sectors of a partition they delete. For example, if Windows Disk Management (Windows 2000/XP, etc.) is used to delete a partition, it will overwrite the first sector (relative sector 0) of the partition before removing it. It still may be possible to restore a
FAT
In nutrition science, nutrition, biology, and chemistry, fat usually means any ester of fatty acids, or a mixture of such chemical compound, compounds, most commonly those that occur in living beings or in food.
The term often refers specif ...
or
NTFS
NT File System (NTFS) (commonly called ''New Technology File System'') is a proprietary journaling file system developed by Microsoft in the 1990s.
It was developed to overcome scalability, security and other limitations with File Allocation Tabl ...
partition if a backup boot sector is available.
Compressed disks
HDDs can be compressed to create additional space. In DOS and early Microsoft Windows, programs such as
Stacker (DR-DOS except 6.0),
SuperStor (DR DOS 6.0),
DoubleSpace (MS-DOS 6.0–6.2), or
DriveSpace (MS-DOS 6.22, Windows 9x) were used. This compression was done by creating a very large file on the partition, then storing the disk's data in this file. At startup, device drivers opened this file and assigned it a separate letter. Frequently, to avoid confusion, the original partition and the compressed drive had their letters swapped, so that the compressed disk is C:, and the uncompressed area (often containing system files) is given a higher name.
Versions of
Windows
Windows is a Product lining, product line of Proprietary software, proprietary graphical user interface, graphical operating systems developed and marketed by Microsoft. It is grouped into families and subfamilies that cater to particular sec ...
using the NT kernel, including the most recent version,
Windows 10
Windows 10 is a major release of Microsoft's Windows NT operating system. The successor to Windows 8.1, it was Software release cycle#Release to manufacturing (RTM), released to manufacturing on July 15, 2015, and later to retail on July 2 ...
, contain intrinsic disk compression capability. The use of separate disk compression utilities has declined sharply.
Partition table
A partition table is a table maintained on a disk by the operating system that outlines and describes the partitions on that disk.
The terms ''partition table'' and ''partition map'' are similar terms and can be used interchangeably. The term is most commonly associated with the
MBR partition table of a
Master Boot Record
A master boot record (MBR) is a type of boot sector in the first block of disk partitioning, partitioned computer mass storage devices like fixed disks or removable drives intended for use with IBM PC-compatible systems and beyond. The concept ...
(MBR) in
PCs, but it may be used generically to refer to other formats that divide a disk drive into partitions, such as:
GUID Partition Table (GPT),
Apple partition map (APM),
[The ''pdisk'' utility for Apple Partition Maps is described as an ''Apple partition table editor'' in its pdisk(8) man page: .] or
BSD disklabel.
[ (NB. The Solaris documentation on disklabels uses the term "partition table".)]
PC partition types
MBR
This section describes the
master boot record
A master boot record (MBR) is a type of boot sector in the first block of disk partitioning, partitioned computer mass storage devices like fixed disks or removable drives intended for use with IBM PC-compatible systems and beyond. The concept ...
(MBR) partitioning scheme, as used historically in
DOS,
Microsoft Windows
Windows is a Product lining, product line of Proprietary software, proprietary graphical user interface, graphical operating systems developed and marketed by Microsoft. It is grouped into families and subfamilies that cater to particular sec ...
and
Linux
Linux ( ) is a family of open source Unix-like operating systems based on the Linux kernel, an kernel (operating system), operating system kernel first released on September 17, 1991, by Linus Torvalds. Linux is typically package manager, pac ...
(among others) on
PC-compatible computer systems. As of the mid-2010s, most new computers use the
GUID Partition Table (GPT) partitioning scheme instead. For examples of other partitioning schemes, see the general article on
partition tables.
The total data storage space of a PC HDD on which MBR partitioning is implemented can contain at most four ''primary partitions'', or alternatively three primary partitions and an ''
extended partition''. The ''Partition Table'', located in the master boot record, contains 16-byte entries, each of which describes a partition.
The ''partition type'' is identified by a 1-byte code found in its partition table entry. Some of these codes (such as and ) may be used to indicate the presence of an
extended partition. Most are used by an operating system's bootloader (that examines partition tables) to decide if a partition contains a file system that can be ''mounted / accessed'' for reading or writing data.
Primary partition
A primary partition contains one file system. In
DOS and all early versions of
Microsoft Windows
Windows is a Product lining, product line of Proprietary software, proprietary graphical user interface, graphical operating systems developed and marketed by Microsoft. It is grouped into families and subfamilies that cater to particular sec ...
systems,
Microsoft
Microsoft Corporation is an American multinational corporation and technology company, technology conglomerate headquartered in Redmond, Washington. Founded in 1975, the company became influential in the History of personal computers#The ear ...
required what it called the
system partition to be the first partition. All Windows operating systems from Windows 95 onwards can be located on (almost) any partition, but the boot files (
io.sys
,
bootmgr
,
ntldr
, etc.) must reside on a primary partition. However, other factors, such as a PC's
BIOS
In computing, BIOS (, ; Basic Input/Output System, also known as the System BIOS, ROM BIOS, BIOS ROM or PC BIOS) is a type of firmware used to provide runtime services for operating systems and programs and to perform hardware initialization d ...
(see
Boot sequence on standard PC) may also impose specific requirements as to which partition must contain the primary OS.
The partition type ''code'' for a primary partition can either correspond to a file system contained within (e.g., means either an
NTFS
NT File System (NTFS) (commonly called ''New Technology File System'') is a proprietary journaling file system developed by Microsoft in the 1990s.
It was developed to overcome scalability, security and other limitations with File Allocation Tabl ...
or an OS/2
HPFS file system) or indicate that the partition has a special use (e.g., code usually indicates a Linux ''swap'' partition). The
FAT16 and
FAT32 file systems have made use of a number of partition type codes due to the limits of various DOS and Windows OS versions. Though a Linux operating system may recognize a number of different file systems (
ext4,
ext3
ext3, or third extended filesystem, is a journaling file system, journaled file system that is commonly used with the Linux kernel. It used to be the default file system for many popular Linux distributions but generally has been supplanted by ...
,
ext2
ext2, or second extended file system, is a file system for the Linux kernel (operating system), kernel. It was initially designed by French software developer Rémy Card as a replacement for the extended file system (ext). Having been designed ...
,
ReiserFS, etc.), they have all consistently used the same partition type code: (
Linux native file system).
Extended partition
An HDD may contain only one extended partition, but that extended partition can be subdivided into multiple logical partitions. DOS/Windows systems may then
assign a unique drive letter to each logical partition.
GUID partition table (GPT) only has the primary partition, doesn't have the extended partition and the logical partition.
Boot partitions
BIOS boot partition
BIOS boot partition (BIOS BP) is a share of the storage device used to keep software that boots the operating system, a
bootloader. It may be an operating system kernel image or bootloader or a completely separate piece of software.
EFI system partition
EFI system partition is the same as BIOS BP, but is loaded by EFI firmware instead of BIOS.
See also
*
Amiga rigid disk block
*
Disk formatting
*
Filesystem Hierarchy Standard
The Filesystem Hierarchy Standard (FHS) is a reference describing the conventions used for the layout of Unix-like systems. It has been made popular by its use in Linux distributions, but it is used by other Unix-like systems as well. It is main ...
*
List of disk partitioning software
*
LVM
*
Master boot record
A master boot record (MBR) is a type of boot sector in the first block of disk partitioning, partitioned computer mass storage devices like fixed disks or removable drives intended for use with IBM PC-compatible systems and beyond. The concept ...
covers the partition table layout
*
Partition alignment
*
RAID
RAID (; redundant array of inexpensive disks or redundant array of independent disks) is a data storage virtualization technology that combines multiple physical Computer data storage, data storage components into one or more logical units for th ...
*
JBOD
References
Further reading
*
*
*
*
*
*
*
{{DEFAULTSORT:Disk Partitioning
Disk partitions
Disk file systems
DOS on IBM PC compatibles
IBM PC compatibles
Utility software types