Hi Everyone,
I'm new to Proxmox and recently ran into an issue with disk management. Here's the situation:
I created an Ubuntu 24 server VM with an initial disk size of 150 GB. Later, I realized I needed to add an additional 25 GB, but I accidentally extended the disk by 175 GB, bringing the total size to 325 GB.
The issue is that I haven’t allocated the extra disk space to the VM's filesystem yet, but now I need to reduce the disk size back to the correct size.
Here’s some additional info about my setup:
I'm new to Proxmox and recently ran into an issue with disk management. Here's the situation:
I created an Ubuntu 24 server VM with an initial disk size of 150 GB. Later, I realized I needed to add an additional 25 GB, but I accidentally extended the disk by 175 GB, bringing the total size to 325 GB.
The issue is that I haven’t allocated the extra disk space to the VM's filesystem yet, but now I need to reduce the disk size back to the correct size.
Here’s some additional info about my setup:
- LVM is used for the volume management.
- Below are the outputs of df -h and lsblk commands:
df -h:
- Filesystem Size Used Avail Use% Mounted on
tmpfs 2.0G 8.5M 2.0G 1% /run
efivarfs 256K 94K 157K 38% /sys/firmware/efi/efivars
/dev/mapper/ubuntu--vg-lv--0 145G 111G 27G 81% /
tmpfs 10G 0 10G 0% /dev/shm
tmpfs 5.0M 0 5.0M 0% /run/lock
/dev/sda2 2.0G 183M 1.7G 10% /boot
/dev/sda1 1.1G 6.2M 1.1G 1% /boot/efi
lsblk:
- NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS
sda 8:0 0 325G 0 disk
├─sda1 8:1 0 1G 0 part /boot/efi
├─sda2 8:2 0 2G 0 part /boot
└─sda3 8:3 0 146.9G 0 part
└─ubuntu--vg-lv--0 252:0 0 146.9G 0 lvm /
sr0 11:0 1 2.6G 0 rom
- What I Need Help With:
- Is it possible to reduce the size of the disk back to the desired size (175 GB or 150 GB)?
- If yes, what is the safest way to achieve this without affecting the data in the VM?
- Any specific steps for LVM would be greatly appreciated.
- I understand resizing can be risky, so I’m being cautious here and asking for advice before proceeding.
Thanks in advance for your guidance!