cfdisk
TLDR
Start the partition manager for a specific device
$ sudo cfdisk [/dev/sdX]
Create a new partition table and manage it$ sudo cfdisk -z [/dev/sdX]
SYNOPSIS
cfdisk [options] device
DESCRIPTION
cfdisk is a curses-based partition table editor. It provides a user-friendly text interface for creating, deleting, and modifying disk partitions.
The tool supports MBR (DOS) and GPT partition tables and displays partition information in an easy-to-read format.
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.


