Many users have been experiencing problems in XenServer, Basically Used Space and Allocated space does not match, I too have encountered this issue, It is to do with the snapshotting feature,
When a snapshot is deleted , Citrix XenServer should automatically reclaim the disk space by un allocating data which had been used by the snapshot, The process known as coalescing. XenServer coalesces the disk space while the vm’s remain running (online coalescing).
However, a bug in XenServer 5.5 and coalescing implementation has a been giving users a lot of grief. . After deleting all the snapshots for a VM’s disks, some or all of the disk space will probably remain allocated to these snapshots, however you can not see these snapshots anymore.
In my case we lost 300gb, 30% of the storage on the server,
A manual workaround has been issued, to address this problem, XenServer 5.5 Update 1 includes an Off-line Coalesce tool. This tool reclaims all disk space previously allocated to deleted snapshots while the VM is temporarily shut down or suspended.
Proceed with Caution!
- Before running the Coalesce tool, all snapshots associated with the VM must be deleted,
It is important to remove the snapshots before running the tool otherwise the process will fail
How to
Reclaiming your disk space
Citrix recommends that you back up the VM on which you will run the space reclamation tool. You can use the XenCenter export option for this purpose.
You will need to know your VM’s UUID.
To retrieve the UUID
1. In XenCenter, enable hidden objects (View menu > Hidden Objects).
2. In the Resource pane, select the VM for which you want to obtain the UUID. The UUID appears in the General tab.
If you are working from the CLI of the Xenserver run xe vm-list, then copy the UUID of the VM you want.
EX xe vm-list
uuid ( RO) : 28c26191-3657-77a4-452d-709893b90315
name-label ( RW): Test1
power-state ( RO): running
uuid ( RO) : c77336ed-eee2-4cb7-9b61-2b717d251946
name-label ( RW): Control domain on host: Xen1
power-state ( RO): running
uuid ( RO) : 427472f3-43ac-772f-2e65-3ed58c9f3ba3
name-label ( RW): Test2
power-state ( RO): running
uuid ( RO) : 7947cfbc-d5fd-ea22-3bde-4383b2e15f66
name-label ( RW): Test3
power-state ( RO): running
To run the tool use
coalesce-leaf –u 7947cfbc-d5fd-ea22-3bde-4383b2e15f66
after the –u enter the UUID of the VM of which you took a snapshot and want to recover the data,
Ideally you backup your vm before running this tool, and under no circumstance are you to start the vm while the tool is running and this can cause severe damage to your data.
Run this tool on each vm where you had snapshots and have been deleted,
This process should reclaim your data.