blob: 0918f4fdff6bb52c8df6f6a26f0d98187a1cd6b7 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
Virtio-blk does not support TRIM
When model=virtio is used, TRIM is not supported.
# mount -o discard /dev/vda4 /mnt
# mount | tail -1
/dev/vda4 on /mnt type fuseblk (rw,nosuid,nodev,relatime,user_id=0,group_id=0,allow_other,blksize=4096)
# fstrim /mnt/
fstrim: /mnt/: the discard operation is not supported
Booting without model=virtio allows using TRIM (in Windows as well).
Full QEMU line:
qemu-system-x86_64 -enable-kvm -cpu host -bios /usr/share/ovmf/ovmf_x64.bin -smp 2 -m 7G -vga qxl -usbdevice tablet -net nic,model=virtio -net user -drive discard=unmap,detect-zeroes=unmap,cache=none,file=vms/win10.hd.img.vmdk,format=vmdk,if=virtio
|