Thanks a lot, I'll have a try.
-----Original Message-----
From: Michal Privoznik [mailto:mprivozn@redhat.com]
Sent: Friday, October 11, 2013 8:58 PM
To: Wangyufei (A)
Cc: libvir-list(a)redhat.com; jdenemar(a)redhat.com; Wangrui (K)
Subject: Re: [libvirt] [BUG] libvirtd on destination crash frequently while
migrating vms concurrently
On 27.09.2013 09:55, Wangyufei (A) wrote:
> Hello,
> I found a problem that libvirtd on destination crash frequently while
> migrating vms concurrently. For example, if I migrate 10 vms
> concurrently ceaselessly, then after about 30 minutes the libvirtd on
> destination will crash. So I analyzed and found two bugs during
> migration process.
> First, during migration prepare phase on destination, libvirtd assigns
> ports to qemu to be startd on destination. But the port increase
> operation is not aomic, so there's a chance that multi vms get the same
> port, and only the first one can start successfully, others will fail to
> start. I've applied a patch to solve this bug, and I test it, it works
> well. If only this bug exists, libvirtd will not crash. The second bug
> is fatal.
> Second, I found the libvirtd crash because of segment fault which is
> produced by accessing vm released. Apparently it's caused by
> multi-thread operation, thread A access vm data which has released by
> thread B. At last I proved my thought right.
So I've just pushed the patch upstream. Please give it a try if it
resolves your problem.
Michal