Resize LVM storage ubuntu
Tested on ubuntu 2404
Fdisk
Using sudo fdisk -l to find the right device.
fdisk /dev/sda
* d
* enter
* n
* enter
* enter
* enter
* N
* p
* wAnd reboot before resizing LVM
Resize LVM
Display lvm infos
sh
lsblk /dev/sdathen
sh
sudo pvresize /dev/sda3
sudo lvextend -l +100%FREE -r /dev/mapper/ubuntu--vg-ubuntu--lvThis can take a while, be patient and do not kill the vm during the process.
-l adds GB to the volume -r extends the filesystem
check using sudo vgs or df -hPT