Linux

Where Does LVM Store Config and Metadata?

Where LVM keeps lvm.conf, metadata backups, and archives on Linux, and the commands that use them daily.

Last updated

LVM keeps configuration in lvm.conf with metadata backups and archives branching beside it under /etc/lvm. Every volume group change writes a backup plus a rotating archive automatically. The lvmconfig command prints effective settings across the whole cascade.

Metadata describes layout only, never file contents, so these files pair with real data backups. Manual vgcfgbackup calls freeze extra generations before surgery. Copy the tree off-system; same-disk copies die with the disks they describe.

Where LVM stores this, by platform

Linux
/etc/lvm/lvm.conf

Central config with backup and archive trees beside it plus profiles and locks. Automatic copies write on every metadata change; manual calls freeze extras. Restore through vgcfgrestore, never by hand-copying. Keep copies off-system.

Frequently asked questions

how do I back up LVM metadata

Copy /etc/lvm/backup and /etc/lvm/archive off-system with the volume names recorded. Metadata describes layout, never file contents. Restore with vgcfgrestore against the right backup generation.

how do I force a metadata backup

Run vgcfgbackup per group or for all groups to force fresh files. Automatic copies already land on every metadata change. Add explicit backups before risky operations like disk replacement.

how do I restore from an archive

List archives with vgcfgrestore to pick a generation, then restore from that file. Reactivate the group afterward and verify mounts. Practice on scratch disks before emergencies demand it.

Notice an outdated path? Let us know.