3.2. Logical Volume Creation Overview

3.2. Logical Volume Creation Overview

The following is a summary of the steps to perform to create an LVM logical volume.

  1. Initialize the partitions you will use for the LVM volume as physical volumes (this labels them).

  2. Create a volume group.

  3. Create a logical volume.

After creating the logical volume you can create and mount the file system. The examples in this document use GFS file systems.

  1. Create a GFS file system on the logical volume with the gfs_mkfs command.

  2. Create a new mount point with the mkdir command. In a clustered system, create the mount point on all nodes in the cluster.

  3. Mount the file system. You may want to add a line to the fstab file for each node in the system.

Alternately, you can create and mount the GFS file system with the LVM GUI.

Creating the LVM volume is machine independent, since the storage area for LVM setup information is on the physical volumes and not the machine where the volume was created. Servers that use the storage have local copies, but can recreate that from what is on the physical volumes. You can attach physical volumes to a different server if the LVM versions are compatible.


Note: This documentation is provided {and copyrighted} by Red Hat®, Inc. and is released via the Open Publication License. The copyright holder has added the further requirement that Distribution of substantively modified versions of this document is prohibited without the explicit permission of the copyright holder. The CentOS project redistributes these original works (in their unmodified form) as a reference for CentOS-4 because CentOS-4 is built from publicly available, open source SRPMS. The documentation is unmodified to be compliant with upstream distribution policy. Neither CentOS-4 nor the CentOS Project are in any way affiliated with or sponsored by Red Hat®, Inc.