[Cluster-devel] [PATCH] libvirt xen uri
Soren Hansen
soren at ubuntu.com
Fri Dec 14 08:24:44 UTC 2007
Hi!
In Ubuntu we've changed libvirt to connect to qemu:///session rather
than xen:/// if no URI is passed to virConnectOpen. fence_xvmd
incidentally does not pass a URI to virConnectOpen and hence will fail.
This patch fixes this old and deprecated use of virConnectOpen.
Thank you!
(Also available as http://people.ubuntu.com/~soren/libvirt_xen_uri.diff)
Index: fence/agents/xvm/fence_xvmd.c
===================================================================
RCS file: /cvs/cluster/cluster/fence/agents/xvm/fence_xvmd.c,v
retrieving revision 1.13
diff -u -r1.13 fence_xvmd.c
--- fence/agents/xvm/fence_xvmd.c 17 Oct 2007 18:29:57 -0000 1.13
+++ fence/agents/xvm/fence_xvmd.c 14 Dec 2007 08:07:01 -0000
@@ -54,6 +54,8 @@
#include "libcman.h"
#include "debug.h"
+#define LIBVIRT_XEN_URI "xen:///"
+
static int running = 1;
@@ -541,7 +543,7 @@
virt_list_t *vl = NULL;
virt_state_t *dom = NULL;
- vp = virConnectOpen(NULL);
+ vp = virConnectOpen(LIBVIRT_XEN_URI);
if (!vp)
perror("virConnectOpen");
@@ -577,7 +579,7 @@
continue;
/* Request and/or timeout: open connection */
- vp = virConnectOpen(NULL);
+ vp = virConnectOpen(LIBVIRT_XEN_URI);
if (!vp) {
printf("NOTICE: virConnectOpen(): %s; cannot fence!\n",
strerror(errno));
--
Soren Hansen
Ubuntu Server Team
http://www.ubuntu.com/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://listman.redhat.com/archives/cluster-devel/attachments/20071214/1ae9df10/attachment.sig>
More information about the Cluster-devel
mailing list