creating_lvms
This is an old revision of the document!
Creating Volume Groups
Below is the command used to create a volume group from one or more physical volumes.
vgcreate vg1 /dev/device1 /dev/device2When physical volumes are used to create volume group, the disk space is divided into 4mb extents. This means that the logical volumes are increased and decreased by this size.
Representation
Logical Volume groups will be represented as:
/dev/vg/lv/For example if you create 2 volume groups and 3 logical volumes it will be displayed as:
/dev/vg1/lv01 /dev/vg1/lv02 /dev/vg1/lv03 /dev/vg2/lv01 /dev/vg2/lv02 /dev/vg2/lv03
Extending a volume group
Below is how to extend a volume group by adding another physical volume:
vgextend vg1 /dev/device4
Displaying Volume Groups
There are 2 commands you can use to display the current groups:
The vgs command provides volume group information in a configurable form, displaying one line per volume group
vgsThe vgdisplay command displays volume group properties (such as size, extents, number of physical volumes, etc.) in a fixed form
vgdisplay
creating_lvms.1448271104.txt.gz · Last modified: 2024/05/23 07:26 (external edit)