Extend LVM disk for virtual machine server or any server


I am doing this on proxmox

1) login to the proxmox server

2) cd to the disk you need to expand

[box] cd /var/lib/vz/images[/box]

3) Increase the disk size

[box] qemu-img resize diskimage.zzz +[size in GB you want to expand]G[/box]

4) boot your VM with gparted or partition magic live iso

5) expand the volume to the new size

6) reboot the VM normally

7) run command

[box]pvdisplay[/box]

8) note the "VG NAME"

9) run
[box]lvextend -L+[size in GB you want to expand]G /dev/{insert VG NAME]/root[/box]

10) Done!
, ,