mirror of
https://github.com/chubin/cheat.sheets
synced 2024-11-15 06:12:59 +00:00
0fd4d3f647
Tested it with LVM version: 2.02.187(2) (2020-03-24) Library version: 1.02.170 (2020-03-24) Driver version: 4.42.0 The correct parameter is -l and not -L in the case of a percentage augment
36 lines
1.1 KiB
Plaintext
36 lines
1.1 KiB
Plaintext
# lvextend
|
|
# Extends a logical volume in an existing volume group.
|
|
# A volume group is a collection of logical and physical volumes.
|
|
|
|
# Extend volume in volume mylv in groug vg0
|
|
# (defined by volume path /dev/vg0/mylv)
|
|
# to 12 gigabyte:
|
|
lvextend -L 12G /dev/vg0/mylv
|
|
|
|
# Extend volume in volume mylv in groug vg0
|
|
# (defined by volume path /dev/vg0/mylv)
|
|
# by 1 gigabyte:
|
|
lvextend -L +1G /dev/vg0/mylv
|
|
|
|
# Extend volume in volume mylv in groug vg0
|
|
# (defined by volume path /dev/vg0/mylv)
|
|
# to use all of the unallocated space in the volume group vg0:
|
|
lvextend -l +100%FREE /dev/vg0/mylv
|
|
|
|
# Extend ext4 filesystem after changing a logical volume
|
|
# (takes volume path as parameter):
|
|
ext2resize /dev/vg0/mylv
|
|
|
|
# Extend btrfs filesystem after changing a logical volume
|
|
# (takes the mount point as parameter, not the volume path):
|
|
btrfs filesystem resize max /mylv
|
|
|
|
# Extend xfs filesystem after changing a logical volume
|
|
# (takes the mount point as parameter, not the volume path):
|
|
xfs_growfs /mylv
|
|
|
|
# Extend jfs filesystem after changing a logical volume
|
|
# (takes the mount point as parameter, not the volume path);
|
|
# Just remount:
|
|
mount -o remount,resize /home
|