live migration with discard enabled

Aleksej

Well-Known Member
Feb 25, 2018
62
4
48
38
Hello.
I have troubles with live migration if "discard=on" for VM.
For some time it halts overall system with IO delay 90% and then migration starts normally.
it seems that proxmox at first moving something (the whole disk size), i can see it by network monitor, and than move disk as usual.

I have 1Gbps connection, lve migration takes about 10 minutes of 50G VM disk and about 20 minutes with "discard=on". So via network traffic flows twice.
Maybe i'm doing something wrong?
I tried discard=on on virtio, scsi - the same.
Also i noticed if VM is newly created on host data on onderlying SSD is used as with discard=on, but after live migration or restoring backup it shows 100% usage until i do not poweroff VM and enable discard.

I'm using up-to-date PVE (pve-manager/6.4-13/9f411e79 (running kernel: 5.4.157-1-pve)
 
I tried with LVM, LVM-thin (the most i use) storage and simple directory (qcow2)

No, with proxmox 7 i didn't try.
I have this issue from old proxmox 5...
I googled about high IO delay but there is a lot of threads but nothing about that...
 
If you have discard enabled it will zero the whole new disk first, hence the delay / high I/O time.

If you can your better to disable discard, reboot and then migrate.

This is a current limitation of QEMU and not PVE
 

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!