Candid photograph of a Linux server terminal with a soft olive-green glow against a dark slate background, conveying a calm technical atmosphere.

Step-by-step guides for system administrators — covering command-line basics, web server setup, and preparation material for technical interviews.

Browse Tutorials

Managing disk partitions with LVM on Fedora

Managing disk partitions with LVM on Fedora gives administrators flexible storage without repeatedly rewriting disk layouts. Disk partitions become physical volumes, a volume group pools available capacity, and logical volumes provide filesystems that can grow as data expands.

Fedora ships with LVM2, XFS and ext4, so the workflow suits workstations, home servers and production hosts. The important discipline is to inspect devices before changing them, record every command, and keep a tested backup outside the logical volume.

Why LVM works well on Fedora

LVM separates physical storage from the filesystem. A new disk can be added to an existing volume group, and unused extents can be assigned to a logical volume without moving unrelated data. This is particularly useful on Fedora systems hosting containers, databases or growing virtual-machine images.

Australian deployments often link offices in Sydney, Melbourne and Brisbane with cloud platforms operating in Sydney and Melbourne regions. Data-residency commitments can make in-country snapshots and backups valuable, while Australian retailers commonly sell 1 TB, 2 TB and 4 TB drives. Retail capacity uses decimal units but LVM reports GiB, so an advertised “2 TB” disk normally appears as about 1.82 TiB.

Prepare devices with a cautious workflow

Start with lsblk -e7 -o NAME,SIZE,TYPE,FSTYPE,MOUNTPOINTS,MODEL, then use findmnt, pvs, vgs and lvs to identify mounted and LVM-managed storage. Choose an unused whole device such as /dev/sdb; never copy that example blindly because device names change between machines and virtual disks.

For a new disk, create a GPT partition with sudo parted /dev/sdb mklabel gpt and sudo parted /dev/sdb mkpart primary 0% 100%, then run sudo partprobe /dev/sdb. wipefs -a may be needed for a reused disk, but it erases filesystem signatures and should only follow a verified device check. Existing cloud volumes may already contain a partition scheme.

Administrators running search clusters can compare the same storage-planning principles with the site's guide to Elasticsearch on CentOS, while remembering that CentOS and Fedora release packaging can differ.

Compare partitioning approaches

The choice is not simply between fixed and flexible layouts. Both approaches need backups, but they offer different operational paths.

Consideration Plain partitions LVM
Initial layout Straightforward per disk Physical volume, volume group and logical volume hierarchy
Capacity growth Requires partition or filesystem changes Unused extents can be assigned to a logical volume
Rollback points No native snapshots Copy-on-write snapshots require reserved space
Disk failure handling Depends on disk and RAID design Also depends on disk and RAID design
Operational complexity Fewer management layers Adds metadata, monitoring and recovery procedures

Use plain partitions for a simple boot disk or fixed appliance where the layout rarely changes. Choose LVM when capacity must be reassigned, snapshots are valuable, or several services share one storage pool. A logical volume still depends on healthy disks and correctly maintained metadata.

Build and resize logical volumes

After partitioning, initialise and assemble the hierarchy with sudo pvcreate /dev/sdb1, sudo vgcreate vgdata /dev/sdb1, and sudo lvcreate -L 40G -n data vgdata. Create the filesystem with sudo mkfs.xfs /dev/vgdata/data, mount it at a deliberate directory, and add its UUID to /etc/fstab. XFS is a strong Fedora default, while ext4 remains suitable when its operational requirements suit the workload.

Growing a volume has two stages: extend the logical volume, then grow the filesystem. For example, use sudo lvextend -L +20G /dev/vgdata/data followed by sudo xfs_growfs /dev/vgdata/data; on ext4, use resize2fs instead. Confirm the new size with lsblk and lvs before placing more data on it.

Before treating additional space as a database fix, review the practical guide to optimising MySQL tables so index behaviour and storage use are considered alongside capacity.

Recommendations for reliable LVM operations

LVM snapshots provide fast rollback points, but they are copy-on-write views, not backups. Reserve adequate snapshot space, test restoration and keep an independent copy away from the machine. A thin pool can make provisioning economical, yet it introduces another allocation layer that administrators must monitor.

Enable lvm2-monitor.service where snapshots or automatic recovery are required. LVM does not provide disk redundancy by itself: place a physical volume on a verified RAID1 array or configure LVM RAID deliberately. Schedule health checks for physical disks, volume groups and filesystems, and retain results in the organisation’s change-management system.

Operate the setup responsibly

Production operation requires more than successful commands. Track SMART data, kernel messages, filesystem errors and free extents, and document which volumes can be reconstructed and which require restoration. For Australian teams using AWS Sydney or Melbourne regions, confirm that snapshots and backups remain in the required jurisdiction; contractual data residency is separate from technical convenience.

Before sharing diagnostic output or screenshots with the publication or a mailing list, check the site's privacy policy and remove customer identifiers, hostnames and application data. Use DD/MM/YYYY dates and Australian spelling in local runbooks so Sydney and Melbourne operators interpret records consistently.

The immediate next step is to run lsblk -e7 -o NAME,SIZE,TYPE,FSTYPE,MOUNTPOINTS,MODEL on a spare Fedora test host and attach the output to the change record.