cfdisk
curses-based disk partition editor
TLDR
Start the partition manager for a specific device
SYNOPSIS
cfdisk [options] device
DESCRIPTION
cfdisk is a curses-based disk partition table editor from the util-linux package. It provides a user-friendly text interface for creating, deleting, resizing, and changing the type of disk partitions, making it more approachable than the command-driven fdisk.
The tool supports both MBR (DOS) and GPT partition tables and displays partition layout in an interactive menu-driven format. Navigation uses arrow keys to select partitions and operations, with changes held in memory until explicitly written with the "Write" command.
The `-z` flag starts with a zeroed partition table, which is useful when setting up a new disk or switching between MBR and GPT schemes.
PARAMETERS
-z, --zero
Start with an empty partition table (useful for new disks)-L, --color
Colorize output-h, --help
Display help
INTERACTIVE COMMANDS
Use arrow keys to navigate, Enter to select:
New
Create a new partitionDelete
Delete selected partitionType
Change partition typeWrite
Write changes to diskQuit
Exit without writingSort
Sort partitions by start sector
CAVEATS
Changes are only written when explicitly choosing "Write". Incorrectly modifying partitions can cause data loss. Unmount partitions before modifying. Requires root privileges.
