Re: [PATCH v2] sanlock: Retry after EINPROGRESS

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 11/15/2012 03:39 AM, Michal Privoznik wrote:
> It may take some time for sanlock to add a lockspace. And if user
> restart libvirtd service meanwhile, the fresh daemon can fail adding
> the same lockspace with EINPROGRESS. Recent sanlock has
> sanlock_inq_lockspace() function which should block until lockspace
> changes state. If we are building against older sanlock we should
> retry a few times before claiming an error. This issue can be easily
> reproduced:
> 
> for i in {1..1000} ; do echo $i; service libvirtd restart; sleep 2; done
> 20
> Stopping libvirtd daemon:                                  [FAILED]
> Starting libvirtd daemon:                                  [  OK  ]
> 21
> Stopping libvirtd daemon:                                  [  OK  ]
> Starting libvirtd daemon:                                  [  OK  ]
> 22
> Stopping libvirtd daemon:                                  [  OK  ]
> Starting libvirtd daemon:                                  [  OK  ]
> 
>  error : virLockManagerSanlockSetupLockspace:334 : Unable to add
>  lockspace /var/lib/libvirt/sanlock/__LIBVIRT__DISKS__: Operation now in
>  progress
> ---

ACK.

-- 
Eric Blake   eblake@xxxxxxxxxx    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]