-
-
Notifications
You must be signed in to change notification settings - Fork 2
Linux Disk Utilities
Mattscreative edited this page Dec 5, 2025
·
2 revisions
Complete beginner-friendly guide to disk utilities on Linux, covering Arch Linux, CachyOS, and other distributions including disk partitioning, formatting, disk health checks, and disk management tools.
Use fdisk:
# Install fdisk
sudo pacman -S util-linux
# Partition disk
sudo fdisk /dev/sda
# Commands:
# n - new partition
# d - delete partition
# w - write changesUse cfdisk:
# Install cfdisk
sudo pacman -S util-linux
# Partition disk
sudo cfdisk /dev/sdaUse parted:
# Install parted
sudo pacman -S parted
# Partition disk
sudo parted /dev/sdaInstall GParted:
# Install GParted
sudo pacman -S gparted
# Launch
sudo gpartedFormat partitions:
# Format as ext4
sudo mkfs.ext4 /dev/sda1
# Format as btrfs
sudo mkfs.btrfs /dev/sda1
# Format as xfs
sudo mkfs.xfs /dev/sda1Check disk health:
# Install smartmontools
sudo pacman -S smartmontools
# Check disk
sudo smartctl -a /dev/sda
# Short test
sudo smartctl -t short /dev/sdaCheck for bad blocks:
# Check bad blocks
sudo badblocks -v /dev/sdaClone disk:
# Clone disk
sudo dd if=/dev/sda of=/dev/sdb bs=4M status=progress
# Warning: Can destroy data!Use Clonezilla:
# Download ISO from clonezilla.org
# Boot from ISO
# Follow wizardCheck disk:
# List disks
lsblk
# Check kernel messages
dmesg | grep -i diskThis guide covered disk utilities for Arch Linux, CachyOS, and other distributions, including partitioning, formatting, and disk health.
- Filesystem Management - Filesystem setup
- Backup and Restore - Backups
- ArchWiki Disk Utilities: https://wiki.archlinux.org/title/Partitioning
This guide covers Arch Linux, CachyOS, and other Linux distributions. For distribution-specific details, refer to your distribution's documentation.