TrumanWong

lvresize

Adjust logical volume space size

Supplementary instructions

lvresize command is used to adjust the space size of the LVM logical volume, which can increase or decrease the space. You need to be careful when using the lvresize command to resize and shrink the logical volume space because it may cause data loss.

grammar

lvresize(option)(parameter)

Options

-L: Specify the size of the logical volume, the unit is "kKmMgGtT" bytes;
-l: Specify the size of the logical volume (number of LEs).

Parameters

Logical volume: Specify the logical volume to be deleted.

Example

Use the lvresize command to adjust the maximum logical volume size. Enter the following command at the command line:

[root@localhost ~]# lvresize -L +200M /dev/vg1000/lvol0 #Increase the logical volume space by 200M

The output information is as follows:

Extending logical volume lvol0 to 280.00 MB
Logical volume lvol0 successfully resized