Change in vdsm[master]: vdsm: Use virsh to check if libvirt is up
danken at redhat.com
danken at redhat.com
Thu Sep 27 14:46:17 UTC 2012
Dan Kenigsberg has posted comments on this change.
Change subject: vdsm: Use virsh to check if libvirt is up
......................................................................
Patch Set 1: (1 inline comment)
....................................................
File vdsm/vdsmd.init.in
Line 401: # this workaround should be removed.
Line 402:
Line 403: for i in {1..50}
Line 404: do
Line 405: if virsh -r version > /dev/null 2>&1 &&
we already have implicit libvirt-client dependency via libvirt-python. I do not mind adding an explicit requirement if everyone loves it.
I understand that forking in order to test if libvirt is up seems excessive, but that's a common practice in the bash-scripting world (and what's happening when you call /usr/bin/[ in the replaced code).
If virsh segfaults, we must fix it asap. The alternative to using it is writing our own ping-libvirt tool. That could be nice, since we can put the timeout logic there, and avoid excessive forks. on the other hand, other places in this code need a is_libvirt_running function. so the external script would better have timeout as an arg.
Line 406: pgrep libvirtd > /dev/null 2>&1; then
Line 407: return 0
Line 408: fi
Line 409: sleep 0.2
--
To view, visit http://gerrit.ovirt.org/8245
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic2844070ca0816525851b3b495b3dfe3096058a9
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Moti Asayag <masayag at redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Douglas Schilling Landgraf <dougsland at redhat.com>
Gerrit-Reviewer: Igor Lvovsky <ilvovsky at redhat.com>
Gerrit-Reviewer: Moti Asayag <masayag at redhat.com>
Gerrit-Reviewer: Yaniv Bronhaim <ybronhei at redhat.com>
More information about the vdsm-patches
mailing list