Deleted VM, but its data is still present on disk. How do I remove the destroyed VM's data?

Daylight

Member
Jun 18, 2021
7
0
6
44
Hi everyone,

I am new to Proxmox.

My disk space is near maxed out on my local zfs volume.

The disk usage on each VM I am running is much lower than what is being shown on the Promox GUI.

How do I safely reclaim this used disk space without compromising the existing VM's? Kind regards David
 
Check the discard box for the disks in the VMs' hardware tab and then run fstrim -av inside the VMs.
 
I have already destroyed and purged the VM but its data still remains for some reason, so I cannot see how I would be able to do what you suggested. Any other ideas?
 
It seems there is no Discard box present in any of the VM's hardware tab. I'm using Proxmox 6.2-4.

Screenshot 2021-06-19 at 19.34.12.png
 
Ok thanks! :) Does the Cache settings have to be the same? On the Windows VM the Cache is set to Default (No cache) and on the Mojave VM it's set to Write Back. The other two vm's already have the "Discard" box ticked already.

And when you say run the fstrim -av command "inside the vm" are you referring to running inside a terminal on the VM itself or through the Nodes shell?

I really appreciate your help.:)


Screenshot 2021-06-19 at 20.14.08.png
Screenshot 2021-06-19 at 20.13.49.png
 
You have to run it inside the VM. Either per ssh or the shell tab in the VM's section.
Additionally, setting the autotrim option for the zpool (of your host) should help.
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!