(I) LVM entry-level program
Volume management creates an abstraction layer on a physical storage device, allowing you to create logical storage volumes. This greatly increases flexibility compared to direct use of physical storage devices.
Logical volumes Allow Storage Virtualization. With logical volumes, you are not limited by the size of physical disks.
In addition, the hardware storage configuration and software are independent, so you can adjust and move data without stopping the application or umount file system.
Logical volumes have the following advantages over physical usage:
① Flexibility. When a logical volume is used, the file system can be distributed across multiple disks, because you can specify multiple disks and partitions to form a logical volume.
② Adjustable storage pool. You can expand or reduce the size of a logical volume without formatting or partitioning.
③ Online data redistribution. You can move data from one disk to another online, or change the distribution of data on the disk.
④ Convenient device naming. You can use a more user-friendly name
⑤ Strip the disk. You can create a logical volume across multiple disks to increase throughput.
⑥ Image volume. Logical volumes can be easily mirrored
7. snapshot volume. Back up a logical volume at a certain time
(Ii) LVM Architecture Overview
The underlying physical storage unit of the LVM logical volume is a block device, such as a partition or disk. The device is initialized as a physical volume (PV ). To create an LVM logical volume, multiple physical volumes form a volume group.
This large storage pool forms the source of LV. Then the logical volume is used by the file system.
(Iii) clvm Introduction
Cluster-based LVM (clvm) is a cluster extension of LVM. Allows computers in a cluster to manage shared storage through LVM.
The clvmd daemon is the core of clvm. The clvmd daemon runs on each cluster computer and updates LVM metadata so that the LVM information on each computer in the cluster remains consistent.
Logical volumes created with clvm on shared storage are visible to computers that have accessed the shared storage.
Clvm allows a user to lock the physical storage device being configured When configuring logical volumes on shared storage. Clvm uses the lock service to ensure consistency of basic information.
Clvm requires changing LVM. conf to use the cluster-wide lock service.