Complete guide to Linux storage technologies: RAID, LVM, Btrfs, ZNS SSD, cloud solutions and performance optimization
Linux Storage Guide 2025: Cloud, RAID, LVM, Btrfs & ZNS SSD
/image%2F7127247%2F20250803%2Fob_61bafd_data-center.png)
Table of Contents
Introduction
SafeITExperts.com makes IT expertise accessible to everyone. This 2025 Storage Reference Guide compiles the latest advances in Linux storage and beyond: ZNS SSD, Btrfs, RAID, LVM, and cloud. An essential resource to understand media, interfaces and data management tools in 2025.
1. Physical Media and Interfaces
Physical media and their interfaces form the foundation of modern storage, defining performance and use cases. This section explores hardware technologies and their connections.
Storage Media (Hardware)
Virtual Storage
Interfaces
Low-Level Concepts
2. Partitioning Schemes
Once physical media is defined, partitioning organizes disks to optimize their usage.
MBR: Legacy format, limited to 2TB
GPT: Modern format, up to 9.4 ZB
UEFI: Replaces BIOS, requires GPT
| Partitioning Tools | ||
|---|---|---|
| Tool | GPT | MBR |
| fdisk | ✔️ | |
| gdisk | ✔️ | |
| sgdisk | ✔️ | |
| parted | ✔️ | ✔️ |
| cfdisk | ✔️ | |
| cgdisk | ✔️ | |
| sfdisk | ✔️ | |
3. File System Types by Platform
Discover file systems adapted to each operating environment and your specific needs.
XFS: Large files
Btrfs: Snapshots
ZFS: Integrity
F2FS: Flash-optimized
FAT32: Compatibility
exFAT: Files >4GB
HFS+: Compatibility
11x9 durability
4. Popular File Systems in 2025
File systems evolve to address new storage challenges. Discover the most used formats and notable innovations this year.
| File systems comparison | ||
|---|---|---|
| FS | Strengths | Use Cases |
| ext4 | Proven stability | Servers, default distributions |
| XFS | Large file performance | Databases, 4K+ video |
| Btrfs | Snapshots, compression | Workstations, NAS |
| ZFS | Integrity, native RAID | Enterprise storage |
| F2FS | Flash-optimized | Smartphones, IoT, SD cards |
| NTFS | Journaling, advanced ACLs | Windows system disks |
| exFAT | Multi-OS compatibility | Modern external drives |
| APFS | Snapshots, native encryption | macOS, Apple SSD disks |
| S3 | Unlimited scalability | Cloud object storage, archives |
| Overlay2 | UnionFS, immutable layers | Docker/Podman runtime |
5. Storage Management and Administration
Effective storage management relies on appropriate tools and commands.
| Parted | ||
|---|---|---|
| Create GPT partition table | ||
| Command parted /dev/sdx mklabel gpt | Example sudo parted /dev/sda mklabel gpt | Function Create GPT table |
| List partitions | ||
| Command parted /dev/sdx print | Example sudo parted /dev/sda print | Function Display disk partition table |
| Create partition | ||
| Command parted /dev/sdx mkpart [name] [fs_type] [start] [end] | Example sudo parted /dev/sdb mkpart primary btrfs 0% 100G | Function Create 100GB Btrfs partition |
| Set partition flags | ||
| Command parted /dev/sdx set [num] [flag] [on/off] | Example sudo parted /dev/sda set 1 esp on sudo parted /dev/sda set 1 boot on sudo parted /dev/sda set 2 swap on | Function Configure special partition attributes |
| Complete partitioning examples | ||
UEFI system with GPTsudo parted /dev/sda mklabel gptsudo parted /dev/sda mkpart ESP fat32 1MiB 512MiBsudo parted /dev/sda set 1 esp onsudo parted /dev/sda mkpart root ext4 512MiB 100%Non-interactive mode sudo parted -s /dev/sdb mklabel gpt mkpart primary ext4 0% 100% | ||
| ZFS | ||
|---|---|---|
| Command zpool create | Example sudo zpool create tank /dev/sdb | Function Create ZFS pool |
| Command zpool list | Example zpool list | Function List pools |
| Command zpool status | Example zpool status tank | Function Check pool status |
| Command zfs create | Example sudo zfs create tank/data | Function Create dataset |
| Command zfs list | Example zfs list | Function List datasets |
| Command zfs destroy | Example sudo zfs destroy tank/data | Function Destroy dataset |
| Command zfs snapshot | Example sudo zfs snapshot tank/data@backup | Function Create snapshot |
| Command zfs list -t snapshot | Example zfs list -t snapshot | Function List snapshots |
| Command zfs destroy | Example sudo zfs destroy tank/data@backup | Function Delete snapshot |
| Command zfs send | zfs receive | Example zfs send tank/data@backup | zfs receive backup/data | Function Send snapshot |
| Command zpool scrub | Example sudo zpool scrub tank | Function Integrity check |
| Command zpool scrub -s | Example sudo zpool scrub -s tank | Function Stop scrub |
| Command zfs list -o space | Example zfs list -o space tank/data | Function Used/available space |
| LVM | ||
|---|---|---|
| Command pvcreate | Example sudo pvcreate /dev/sdX | Function Create physical volume |
| Command pvdisplay | Example pvdisplay | Function List existing PVs |
| Command pvs | Example pvs | Function PV summary |
| Command vgcreate | Example sudo vgcreate vg_data /dev/sdX | Function Create volume group |
| Command vgdisplay | Example vgdisplay | Function List VGs |
| Command vgs | Example vgs | Function VG summary |
| Command vgextend | Example sudo vgextend vg_data /dev/sdY | Function Add PV to VG |
| Command lvcreate | Example sudo lvcreate -n lv_home -L 50G vg_data | Function Create logical volume |
| Command lvdisplay | Example lvdisplay | Function List LVs |
| Command lvs | Example lvs | Function LV summary |
| Command lvextend | Example sudo lvextend -L +20G /dev/vg_data/lv_home | Function Extend LV |
| Command lvreduce | Example sudo lvreduce -L -10G /dev/vg_data/lv_home | Function Reduce LV |
| Command mkfs.ext4 | Example sudo mkfs.ext4 /dev/vg_data/lv_home | Function Format LV as ext4 |
| Command mount | Example sudo mount /dev/vg_data/lv_home /home | Function Mount LV |
| Command vgdisplay | Example vgdisplay vg_data | Function Free space in VG |
| Command pvck | Example pvck /dev/sdX | Function Verify PV/LV integrity |
| Command lvremove | Example sudo lvremove /dev/vg_data/lv_home | Function Remove LV |
| Command vgremove | Example sudo vgremove vg_data | Function Remove VG |
| Command pvremove | Example sudo pvremove /dev/sdX | Function Remove PV |
| RAID | ||
|---|---|---|
| Command cat /proc/mdstat | Example cat /proc/mdstat | Function Check RAID status |
| Command mdadm --detail | Example mdadm --detail /dev/md0 | Function RAID details |
| Command mdadm --create | Example sudo mdadm --create /dev/md0 --level=1 --raid-devices=2 /dev/sda1 /dev/sdb1 | Function Create RAID array |
| Command mdadm --add | Example sudo mdadm --add /dev/md0 /dev/sdc1 | Function Add disk |
| Command mdadm --fail | Example sudo mdadm --fail /dev/md0 /dev/sda1 | Function Mark disk as failed |
| Command mdadm --remove | Example sudo mdadm --remove /dev/md0 /dev/sda1 | Function Remove disk |
| Command mdadm --grow | Example sudo mdadm --grow /dev/md0 --raid-devices=3 | Function Resize array |
| Command mdadm --assemble | Example sudo mdadm --assemble --scan | Function Assemble array |
| Command mdadm --detail --scan | Example sudo mdadm --detail --scan | sudo tee -a /etc/mdadm/mdadm.conf | Function Save configuration |
| Command update-initramfs | Example sudo update-initramfs -u | Function Update initramfs |
| Command mdadm --stop | Example sudo mdadm --stop /dev/md0 | Function Stop array |
| Command mdadm --remove | Example sudo mdadm --remove /dev/md0 | Function Delete array |
Swap Management
| Swap Files | ||
|---|---|---|
| Command fallocate | Example sudo fallocate -l 2G /swapfile | Function Create swap file |
| Command mkswap | Example sudo mkswap /swapfile | Function Format swap file |
| Command swapon | Example sudo swapon /swapfile | Function Enable swap |
| Command swapoff | Example sudo swapoff /swapfile | Function Disable swap |
| Command swapon --show | Example swapon --show | Function Check active swap |
| RAM Swap (zram) | ||
|---|---|---|
| Distro | Installation | Configuration |
| Debian/Ubuntu | sudo apt install zram-tools | Edit /etc/default/zramswap |
| openSUSE | sudo zypper install systemd-zram-service | Edit /etc/systemd/zram-generator.conf |
| Arch Linux | Preinstalled | Create /etc/systemd/zram-generator.conf |
| Fedora | sudo dnf install zram-generator | Edit /etc/systemd/zram-generator.conf |
| NixOS | Configure in configuration.nix | boot.zram.enable = true; |
Mounting and Identification
| Mount Commands | ||
|---|---|---|
| Command mount | Example sudo mount /dev/sda1 /data | Function Mount filesystem |
| Command mount -a | Example sudo mount -a | Function Mount all filesystems from /etc/fstab |
| Command umount | Example sudo umount /data | Function Unmount filesystem |
| Command umount -l | Example sudo umount -l /data | Function Lazy unmount |
| Command umount -f | Example sudo umount -f /data | Function Force unmount |
| Command findmnt | Example findmnt | Function Check active mounts |
Maintenance and Copy
| Maintenance Commands | ||
|---|---|---|
| Command dd | Example sudo dd if=/dev/sda of=/dev/sdb bs=64K conv=noerror,sync status=progress | Function Raw bit-by-bit copy |
| Command ddrescue | Example sudo ddrescue -f -n /dev/sda /dev/sdd rescue.log | Function Copy with error handling |
| Command rsync | Example sudo rsync -aAXv --progress /source/ /dest/ | Function Incremental copy |
| Command cp --reflink | Example cp --reflink=auto largefile /mnt/backup/ | Function Lightweight cloning (CoW) |
Cleanup and Maintenance
| Cleanup Commands | |
|---|---|
| Command wipefs | Example wipefs --all /dev/sda1 |
| Function Erase FS/RAID signatures | Example shred -vfz /dev/sda |
| Command zerofree | Example zerofree /dev/sda1 |
Containers
| Container Commands | ||
|---|---|---|
| Command docker pull | Example docker pull ubuntu:latest | Function Pull image |
| Command docker create | Example docker create --name my-container ubuntu:latest | Function Create container |
| Command docker run | Example docker run -it --rm ubuntu bash | Function Run interactive container |
| Command docker ps | Example docker ps -a | Function List containers |
| Command docker rm | Example docker rm my-container | Function Remove container |
| Command docker rmi | Example docker rmi nginx:latest | Function Remove image |
6. Creating File Systems
Essential commands for formatting file systems.
| Formatting Commands | ||
|---|---|---|
| Command | System | Example |
| mkfs.ext4 | ext4 | mkfs.ext4 /dev/sda1 |
| mkfs.xfs | XFS | mkfs.xfs -f /dev/nvme0n1p2 |
| mkfs.btrfs | Btrfs | mkfs.btrfs /dev/md0 |
| mkfs.f2fs | F2FS | mkfs.f2fs /dev/mmcblk0p2 |
| mkfs.ntfs | NTFS | mkfs.ntfs -Q /dev/sdc1 |
| mkfs.exfat | exFAT | mkfs.exfat /dev/sdd1 |
| mkswap | Swap | mkswap /dev/sda2 |
7. Btrfs Administration
| Btrfs Commands | ||
|---|---|---|
| Command mkfs.btrfs | Example sudo mkfs.btrfs /dev/sdX1 | Function Create filesystem |
| Command mount -o compress | Example sudo mount -o compress=zstd /dev/sdX1 /mnt | Function Mount with compression |
| Command findmnt -t btrfs | Example findmnt -t btrfs | Function List Btrfs volumes |
| Command btrfs subvolume list | Example sudo btrfs subvolume list /mnt | Function List subvolumes |
| Command btrfs subvolume create | Example sudo btrfs subvolume create /mnt/@data | Function Create subvolume |
| Command btrfs subvolume delete | Example sudo btrfs subvolume delete /mnt/@data | Function Delete subvolume |
| Command btrfs subvolume snapshot | Example sudo btrfs subvolume snapshot /mnt/@data /mnt/@data_backup | Function Create snapshot |
| Command btrfs send | btrfs receive | Example sudo btrfs send /mnt/@data_backup | sudo btrfs receive /mnt/backup_target | Function Snapshot replication |
| Command btrfs scrub start | Example sudo btrfs scrub start /mnt | Function Integrity verification |
| Command btrfs filesystem df | Example sudo btrfs filesystem df /mnt | Function Used/available space |
| Command btrfs balance start | Example sudo btrfs balance start -dusage=80 /mnt | Function Rebalance allocation |
Storage Glossary
Key terms to master storage in 2025
Linux Storage Quiz
Test your knowledge of storage technologies
lvcreatepvcreateQuiz completed!
8. Conclusion
This 2025 Linux Storage Guide provides an overview of current technologies, from physical media like ZNS SSDs to filesystems like Btrfs, through RAID architectures, LVM, and cloud solutions. Designed for enthusiasts and professionals alike, it compiles essential tools and concepts to understand and manage storage on Linux and beyond.
Stay tuned for Part 2, "Storage Unit Optimization", which will explore advanced techniques to maximize performance, reliability and efficiency in 2025.
/image%2F7127247%2F20250815%2Fob_39062c_data-center.png)