[libvirt] question about locking in qemuDomainObjBeginJobInternal()

Michal Privoznik mprivozn at redhat.com
Wed Aug 16 13:23:15 UTC 2017


On 08/15/2017 11:05 PM, Chris Friesen wrote:
> Hi,
> 
> I'm hitting a scenario (on libvirt 1.2.12, so yeah it's a bit old) where
> I'm attempting to create two domains at the same time, and they both end
> up erroring out with "cannot acquire state change lock":
> 
> 
> 2017-08-14T12:57:00.000 79674: warning :
> qemuDomainObjBeginJobInternal:1380 : Cannot start job (modify, none) for
> domain instance-00000001; current job is (modify, none) owned by (79673, 0)
> 2017-08-14T12:57:00.000 79674: error :
> qemuDomainObjBeginJobInternal:1385 : Timed out during operation: cannot
> acquire state change lock
> 2017-08-14T12:57:01.000 79675: warning :
> qemuDomainObjBeginJobInternal:1380 : Cannot start job (modify, none) for
> domain instance-00000002; current job is (modify, none) owned by (79677, 0)
> 2017-08-14T12:57:01.000 79675: error :
> qemuDomainObjBeginJobInternal:1385 : Timed out during operation: cannot
> acquire state change lock
> 
> Given that the lock appears to be per-domain, I assume this means that
> something is trying to issue multiple operations in parallel to each
> domain?

Yeah. Or the other possibility is that some API left the job set? Can
you attach gdb once the create API is issued and run "t a a bt" in it?
It should display all the libvirtd threads and what are they doing. That
way we can debug this. Although, I guess it's already fixed upstream
since 1.2.12 is very old.

Michal




More information about the libvir-list mailing list