Skip to content

Linux cfdisk Guide

Mattscreative edited this page Dec 5, 2025 · 2 revisions

Linux cfdisk Guide

Complete beginner-friendly guide to cfdisk on Linux, covering Arch Linux, CachyOS, and other distributions including disk partitioning with a user-friendly interface.


Table of Contents

  1. Understanding cfdisk
  2. cfdisk Installation
  3. cfdisk Interface
  4. Creating Partitions
  5. Managing Partitions
  6. Troubleshooting

Understanding cfdisk

What is cfdisk?

cfdisk is curses-based disk partitioner.

Features:

  • User-friendly: Menu-driven interface
  • Visual: See partitions clearly
  • Easy: Simpler than fdisk
  • Safe: Preview before applying

Uses:

  • Create partitions: Make new partitions
  • Delete partitions: Remove partitions
  • Resize partitions: Change partition size
  • Format partitions: Set filesystem type

cfdisk Installation

Install cfdisk

Arch/CachyOS:

# Install util-linux (includes cfdisk)
sudo pacman -S util-linux

# Usually pre-installed

Debian/Ubuntu:

sudo apt install util-linux

Fedora:

sudo dnf install util-linux

Launch cfdisk

Start cfdisk:

# Open disk
sudo cfdisk /dev/sda

# Interactive menu appears

cfdisk Interface

Menu Options

Main menu:

  • New: Create new partition
  • Delete: Delete partition
  • Resize: Resize partition
  • Type: Change partition type
  • Write: Write changes
  • Quit: Exit without saving

Navigation

Move around:

  • Arrow keys: Navigate menu
  • Enter: Select option
  • Tab: Switch between sections

Creating Partitions

Create Partition

Steps:

  1. Select free space
  2. Choose "New"
  3. Enter partition size
  4. Select partition type
  5. Write changes

Partition Types

Common types:

  • Linux: Standard Linux partition
  • Linux swap: Swap partition
  • EFI System: UEFI boot partition

Managing Partitions

Delete Partition

Remove:

  1. Select partition
  2. Choose "Delete"
  3. Confirm deletion
  4. Write changes

Resize Partition

Change size:

  1. Select partition
  2. Choose "Resize"
  3. Enter new size
  4. Write changes

Troubleshooting

cfdisk Not Starting

Check installation:

# Check cfdisk
which cfdisk
cfdisk --version

# Install if missing
sudo pacman -S util-linux

Changes Not Applied

Write changes:

# Make sure to select "Write"
# In cfdisk menu
# Then "Quit"

Summary

This guide covered cfdisk usage, partition management, and disk partitioning for Arch Linux, CachyOS, and other distributions.


Next Steps


This guide covers Arch Linux, CachyOS, and other Linux distributions. For distribution-specific details, refer to your distribution's documentation.

Clone this wiki locally