kvm_recover_space_from_vm
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
kvm_recover_space_from_vm [2014/12/02 21:05] – [Test] admin | kvm_recover_space_from_vm [2021/10/09 15:14] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 3: | Line 3: | ||
=====Archlinux - KVM Recover space from VM===== | =====Archlinux - KVM Recover space from VM===== | ||
Note: A VM image on NFS storage might not work. I had success with local and iSCSI storage. | Note: A VM image on NFS storage might not work. I had success with local and iSCSI storage. | ||
- | ~~TOC~~ | ||
====Create VM==== | ====Create VM==== | ||
* Create VM with virtio-scsi controler and unmap setting: < | * Create VM with virtio-scsi controler and unmap setting: < | ||
Line 30: | Line 29: | ||
* Delete tstfile | * Delete tstfile | ||
* Trim the filesystem: < | * Trim the filesystem: < | ||
- | * Check VM image size. You can see in the first column the size grow and shrink after fstrim. < | + | * Check VM image size. You can see in the first column the size grow and shrink after fstrim. < |
1226824 -rw-r--r-- 1 nobody kvm 1256325120 Dec 2 21:59 vmcentos.qcow2 | 1226824 -rw-r--r-- 1 nobody kvm 1256325120 Dec 2 21:59 vmcentos.qcow2 | ||
1355912 -rw-r--r-- 1 nobody kvm 1388511232 Dec 2 21:59 vmcentos.qcow2 | 1355912 -rw-r--r-- 1 nobody kvm 1388511232 Dec 2 21:59 vmcentos.qcow2 |
kvm_recover_space_from_vm.1417554352.txt.gz · Last modified: 2014/12/02 21:05 by admin