Compare commits
11 Commits
libvirt-0_
...
libvirt-0_
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
e1b7b518ac | ||
|
|
581b5f5022 | ||
|
|
c476c8b683 | ||
|
|
b93eafc59f | ||
|
|
2105d62ca8 | ||
|
|
743adffffe | ||
|
|
11e3b51c0d | ||
|
|
66df925739 | ||
|
|
b20a5c6d3b | ||
|
|
7f58f3aa54 | ||
|
|
6577b14441 |
@@ -10,3 +10,5 @@ libvirt-0.6.3.tar.gz
|
||||
libvirt-0.6.4.tar.gz
|
||||
libvirt-0.6.5.tar.gz
|
||||
libvirt-0.7.0-0.1.gitf055724.tar.gz
|
||||
libvirt-0.7.0-0.6.gite195b43.tar.gz
|
||||
libvirt-0.7.0.tar.gz
|
||||
|
||||
73
libvirt-0.7.0-chown-kernel-initrd-before-spawning-qemu.patch
Normal file
73
libvirt-0.7.0-chown-kernel-initrd-before-spawning-qemu.patch
Normal file
@@ -0,0 +1,73 @@
|
||||
From: Mark McLoughlin <markmc@redhat.com>
|
||||
Subject: [PATCH] chown kernel/initrd before spawning qemu
|
||||
|
||||
If we're running qemu unprivileged, we need to chown any supplied kernel
|
||||
or initrd before spawning it.
|
||||
|
||||
* src/qemu_driver.c: rename qemuDomainSetDiskOwnership() to
|
||||
qemuDomainSetFileOwnership(), pass it a path string instead of a disk
|
||||
definition and use it for chowning the kernel/initrd in
|
||||
qemuDomainSetAllDeviceOwnership()
|
||||
---
|
||||
src/qemu_driver.c | 20 ++++++++++++--------
|
||||
1 files changed, 12 insertions(+), 8 deletions(-)
|
||||
|
||||
diff --git a/src/qemu_driver.c b/src/qemu_driver.c
|
||||
index 412b68d..bd58435 100644
|
||||
--- a/src/qemu_driver.c
|
||||
+++ b/src/qemu_driver.c
|
||||
@@ -1684,18 +1684,18 @@ static int qemuDomainSetHostdevOwnership(virConnectPtr conn,
|
||||
|
||||
}
|
||||
|
||||
-static int qemuDomainSetDiskOwnership(virConnectPtr conn,
|
||||
- virDomainDiskDefPtr def,
|
||||
+static int qemuDomainSetFileOwnership(virConnectPtr conn,
|
||||
+ const char *path,
|
||||
uid_t uid, gid_t gid)
|
||||
{
|
||||
|
||||
- if (!def->src)
|
||||
+ if (!path)
|
||||
return 0;
|
||||
|
||||
- VIR_DEBUG("Setting ownership on %s to %d:%d", def->src, uid, gid);
|
||||
- if (chown(def->src, uid, gid) < 0) {
|
||||
+ VIR_DEBUG("Setting ownership on %s to %d:%d", path, uid, gid);
|
||||
+ if (chown(path, uid, gid) < 0) {
|
||||
virReportSystemError(conn, errno, _("cannot set ownership on %s"),
|
||||
- def->src);
|
||||
+ path);
|
||||
return -1;
|
||||
}
|
||||
return 0;
|
||||
@@ -1725,7 +1725,7 @@ static int qemuDomainSetDeviceOwnership(virConnectPtr conn,
|
||||
(def->data.disk->readonly || def->data.disk->shared))
|
||||
return 0;
|
||||
|
||||
- return qemuDomainSetDiskOwnership(conn, def->data.disk, uid, gid);
|
||||
+ return qemuDomainSetFileOwnership(conn, def->data.disk->src, uid, gid);
|
||||
|
||||
case VIR_DOMAIN_DEVICE_HOSTDEV:
|
||||
return qemuDomainSetHostdevOwnership(conn, def->data.hostdev, uid, gid);
|
||||
@@ -1753,12 +1753,16 @@ static int qemuDomainSetAllDeviceOwnership(virConnectPtr conn,
|
||||
uid = restore ? 0 : driver->user;
|
||||
gid = restore ? 0 : driver->group;
|
||||
|
||||
+ if (qemuDomainSetFileOwnership(conn, def->os.kernel, uid, gid) < 0 ||
|
||||
+ qemuDomainSetFileOwnership(conn, def->os.initrd, uid, gid) < 0)
|
||||
+ return -1;
|
||||
+
|
||||
for (i = 0 ; i < def->ndisks ; i++) {
|
||||
if (restore &&
|
||||
(def->disks[i]->readonly || def->disks[i]->shared))
|
||||
continue;
|
||||
|
||||
- if (qemuDomainSetDiskOwnership(conn, def->disks[i], uid, gid) < 0)
|
||||
+ if (qemuDomainSetFileOwnership(conn, def->disks[i]->src, uid, gid) < 0)
|
||||
return -1;
|
||||
}
|
||||
|
||||
--
|
||||
1.6.2.5
|
||||
|
||||
39
libvirt-0.7.0-handle-kernels-with-no-ipv6-support.patch
Normal file
39
libvirt-0.7.0-handle-kernels-with-no-ipv6-support.patch
Normal file
@@ -0,0 +1,39 @@
|
||||
From: Mark McLoughlin <markmc@redhat.com>
|
||||
Subject: [PATCH] Handle kernels with no ipv6 support
|
||||
|
||||
If the ipv6 kernel module is not loaded, then we get this when starting
|
||||
a virtual network:
|
||||
|
||||
libvir: Network Config error :
|
||||
cannot enable /proc/sys/net/ipv6/conf/virbr0/disable_ipv6:
|
||||
No such file or directory
|
||||
|
||||
If disable_ipv6 is not present, we should just merrily continue on our
|
||||
way.
|
||||
|
||||
* src/network_driver.c: make networkDisableIPV6() not fail if the kernel
|
||||
has no ipv6 support
|
||||
---
|
||||
src/network_driver.c | 6 ++++++
|
||||
1 files changed, 6 insertions(+), 0 deletions(-)
|
||||
|
||||
diff --git a/src/network_driver.c b/src/network_driver.c
|
||||
index eaea454..84910ab 100644
|
||||
--- a/src/network_driver.c
|
||||
+++ b/src/network_driver.c
|
||||
@@ -801,6 +801,12 @@ static int networkDisableIPV6(virConnectPtr conn,
|
||||
goto cleanup;
|
||||
}
|
||||
|
||||
+ if (access(field, W_OK) < 0 && errno == ENOENT) {
|
||||
+ VIR_DEBUG("ipv6 appears to already be disabled on %s", network->def->bridge);
|
||||
+ ret = 0;
|
||||
+ goto cleanup;
|
||||
+ }
|
||||
+
|
||||
if (virFileWriteStr(field, "1") < 0) {
|
||||
virReportSystemError(conn, errno,
|
||||
_("cannot enable %s"), field);
|
||||
--
|
||||
1.6.2.5
|
||||
|
||||
85
libvirt-0.7.0-numa-ignore-fail.patch
Normal file
85
libvirt-0.7.0-numa-ignore-fail.patch
Normal file
@@ -0,0 +1,85 @@
|
||||
commit 19bac57b26c2d46ac8a7601158f210f34acdceac
|
||||
Author: Daniel P. Berrange <berrange@redhat.com>
|
||||
Date: Thu Aug 13 11:56:31 2009 +0100
|
||||
|
||||
Make LXC / UML drivers robust against NUMA topology brokenness
|
||||
|
||||
Some kernel versions expose broken NUMA topology for some machines.
|
||||
This causes the LXC/UML drivers to fail to start. QEMU driver was
|
||||
already fixed for this problem
|
||||
|
||||
* src/lxc_conf.c: Log and ignore failure to populate NUMA info
|
||||
* src/uml_conf.c: Log and ignore failure to populate NUMA info
|
||||
* src/capabilities.c: Reset nnumaCell to 0 after freeing
|
||||
|
||||
diff --git a/src/capabilities.c b/src/capabilities.c
|
||||
index c6766b6..193a9fe 100644
|
||||
--- a/src/capabilities.c
|
||||
+++ b/src/capabilities.c
|
||||
@@ -139,6 +139,7 @@ virCapabilitiesFreeNUMAInfo(virCapsPtr caps)
|
||||
for (i = 0 ; i < caps->host.nnumaCell ; i++)
|
||||
virCapabilitiesFreeHostNUMACell(caps->host.numaCell[i]);
|
||||
VIR_FREE(caps->host.numaCell);
|
||||
+ caps->host.nnumaCell = 0;
|
||||
}
|
||||
|
||||
/**
|
||||
diff --git a/src/lxc_conf.c b/src/lxc_conf.c
|
||||
index d06a024..fef60ba 100644
|
||||
--- a/src/lxc_conf.c
|
||||
+++ b/src/lxc_conf.c
|
||||
@@ -30,6 +30,8 @@
|
||||
#include "lxc_conf.h"
|
||||
#include "nodeinfo.h"
|
||||
#include "virterror_internal.h"
|
||||
+#include "logging.h"
|
||||
+
|
||||
|
||||
#define VIR_FROM_THIS VIR_FROM_LXC
|
||||
|
||||
@@ -46,8 +48,14 @@ virCapsPtr lxcCapsInit(void)
|
||||
0, 0)) == NULL)
|
||||
goto no_memory;
|
||||
|
||||
- if (nodeCapsInitNUMA(caps) < 0)
|
||||
- goto no_memory;
|
||||
+ /* Some machines have problematic NUMA toplogy causing
|
||||
+ * unexpected failures. We don't want to break the QEMU
|
||||
+ * driver in this scenario, so log errors & carry on
|
||||
+ */
|
||||
+ if (nodeCapsInitNUMA(caps) < 0) {
|
||||
+ virCapabilitiesFreeNUMAInfo(caps);
|
||||
+ VIR_WARN0("Failed to query host NUMA topology, disabling NUMA capabilities");
|
||||
+ }
|
||||
|
||||
/* XXX shouldn't 'borrow' KVM's prefix */
|
||||
virCapabilitiesSetMacPrefix(caps, (unsigned char []){ 0x52, 0x54, 0x00 });
|
||||
diff --git a/src/uml_conf.c b/src/uml_conf.c
|
||||
index 48e05a8..4f756d4 100644
|
||||
--- a/src/uml_conf.c
|
||||
+++ b/src/uml_conf.c
|
||||
@@ -45,6 +45,7 @@
|
||||
#include "nodeinfo.h"
|
||||
#include "verify.h"
|
||||
#include "bridge.h"
|
||||
+#include "logging.h"
|
||||
|
||||
#define VIR_FROM_THIS VIR_FROM_UML
|
||||
|
||||
@@ -63,8 +64,14 @@ virCapsPtr umlCapsInit(void) {
|
||||
0, 0)) == NULL)
|
||||
goto no_memory;
|
||||
|
||||
- if (nodeCapsInitNUMA(caps) < 0)
|
||||
- goto no_memory;
|
||||
+ /* Some machines have problematic NUMA toplogy causing
|
||||
+ * unexpected failures. We don't want to break the QEMU
|
||||
+ * driver in this scenario, so log errors & carry on
|
||||
+ */
|
||||
+ if (nodeCapsInitNUMA(caps) < 0) {
|
||||
+ virCapabilitiesFreeNUMAInfo(caps);
|
||||
+ VIR_WARN0("Failed to query host NUMA topology, disabling NUMA capabilities");
|
||||
+ }
|
||||
|
||||
if ((guest = virCapabilitiesAddGuest(caps,
|
||||
"uml",
|
||||
469
libvirt-0.7.0-policy-kit-rewrite.patch
Normal file
469
libvirt-0.7.0-policy-kit-rewrite.patch
Normal file
@@ -0,0 +1,469 @@
|
||||
diff -rupN libvirt-0.7.0/configure.in libvirt-0.7.0.new/configure.in
|
||||
--- libvirt-0.7.0/configure.in 2009-08-05 08:53:49.000000000 -0400
|
||||
+++ libvirt-0.7.0.new/configure.in 2009-08-13 08:37:22.393897620 -0400
|
||||
@@ -641,40 +641,61 @@ AC_SUBST([SASL_LIBS])
|
||||
dnl PolicyKit library
|
||||
POLKIT_CFLAGS=
|
||||
POLKIT_LIBS=
|
||||
+PKCHECK_PATH=
|
||||
AC_ARG_WITH([polkit],
|
||||
[ --with-polkit use PolicyKit for UNIX socket access checks],
|
||||
[],
|
||||
[with_polkit=check])
|
||||
|
||||
+with_polkit0=no
|
||||
+with_polkit1=no
|
||||
if test "x$with_polkit" = "xyes" -o "x$with_polkit" = "xcheck"; then
|
||||
- PKG_CHECK_MODULES(POLKIT, polkit-dbus >= $POLKIT_REQUIRED,
|
||||
- [with_polkit=yes], [
|
||||
- if test "x$with_polkit" = "xcheck" ; then
|
||||
- with_polkit=no
|
||||
- else
|
||||
- AC_MSG_ERROR(
|
||||
- [You must install PolicyKit >= $POLKIT_REQUIRED to compile libvirt])
|
||||
- fi
|
||||
- ])
|
||||
- if test "x$with_polkit" = "xyes" ; then
|
||||
+ dnl Check for new polkit first - just a binary
|
||||
+ AC_PATH_PROG([PKCHECK_PATH],[pkcheck], [], [/usr/sbin:$PATH])
|
||||
+ if test "x$PKCHECK_PATH" != "x" ; then
|
||||
+ AC_DEFINE_UNQUOTED([PKCHECK_PATH],["$PKCHECK_PATH"],[Location of pkcheck program])
|
||||
AC_DEFINE_UNQUOTED([HAVE_POLKIT], 1,
|
||||
- [use PolicyKit for UNIX socket access checks])
|
||||
-
|
||||
- old_CFLAGS=$CFLAGS
|
||||
- old_LDFLAGS=$LDFLAGS
|
||||
- CFLAGS="$CFLAGS $POLKIT_CFLAGS"
|
||||
- LDFLAGS="$LDFLAGS $POLKIT_LIBS"
|
||||
- AC_CHECK_FUNCS([polkit_context_is_caller_authorized])
|
||||
- CFLAGS="$old_CFLAGS"
|
||||
- LDFLAGS="$old_LDFLAGS"
|
||||
-
|
||||
- AC_PATH_PROG([POLKIT_AUTH], [polkit-auth])
|
||||
- if test "x$POLKIT_AUTH" != "x"; then
|
||||
- AC_DEFINE_UNQUOTED([POLKIT_AUTH],["$POLKIT_AUTH"],[Location of polkit-auth program])
|
||||
+ [use PolicyKit for UNIX socket access checks])
|
||||
+ AC_DEFINE_UNQUOTED([HAVE_POLKIT1], 1,
|
||||
+ [use PolicyKit for UNIX socket access checks])
|
||||
+ with_polkit="yes"
|
||||
+ with_polkit1="yes"
|
||||
+ else
|
||||
+ dnl Check for old polkit second - library + binary
|
||||
+ PKG_CHECK_MODULES(POLKIT, polkit-dbus >= $POLKIT_REQUIRED,
|
||||
+ [with_polkit=yes], [
|
||||
+ if test "x$with_polkit" = "xcheck" ; then
|
||||
+ with_polkit=no
|
||||
+ else
|
||||
+ AC_MSG_ERROR(
|
||||
+ [You must install PolicyKit >= $POLKIT_REQUIRED to compile libvirt])
|
||||
+ fi
|
||||
+ ])
|
||||
+ if test "x$with_polkit" = "xyes" ; then
|
||||
+ AC_DEFINE_UNQUOTED([HAVE_POLKIT], 1,
|
||||
+ [use PolicyKit for UNIX socket access checks])
|
||||
+ AC_DEFINE_UNQUOTED([HAVE_POLKIT0], 1,
|
||||
+ [use PolicyKit for UNIX socket access checks])
|
||||
+
|
||||
+ old_CFLAGS=$CFLAGS
|
||||
+ old_LDFLAGS=$LDFLAGS
|
||||
+ CFLAGS="$CFLAGS $POLKIT_CFLAGS"
|
||||
+ LDFLAGS="$LDFLAGS $POLKIT_LIBS"
|
||||
+ AC_CHECK_FUNCS([polkit_context_is_caller_authorized])
|
||||
+ CFLAGS="$old_CFLAGS"
|
||||
+ LDFLAGS="$old_LDFLAGS"
|
||||
+
|
||||
+ AC_PATH_PROG([POLKIT_AUTH], [polkit-auth])
|
||||
+ if test "x$POLKIT_AUTH" != "x"; then
|
||||
+ AC_DEFINE_UNQUOTED([POLKIT_AUTH],["$POLKIT_AUTH"],[Location of polkit-auth program])
|
||||
+ fi
|
||||
+ with_polkit0="yes"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
AM_CONDITIONAL([HAVE_POLKIT], [test "x$with_polkit" = "xyes"])
|
||||
+AM_CONDITIONAL([HAVE_POLKIT0], [test "x$with_polkit0" = "xyes"])
|
||||
+AM_CONDITIONAL([HAVE_POLKIT1], [test "x$with_polkit1" = "xyes"])
|
||||
AC_SUBST([POLKIT_CFLAGS])
|
||||
AC_SUBST([POLKIT_LIBS])
|
||||
|
||||
@@ -1695,7 +1716,11 @@ else
|
||||
AC_MSG_NOTICE([ avahi: no])
|
||||
fi
|
||||
if test "$with_polkit" = "yes" ; then
|
||||
-AC_MSG_NOTICE([ polkit: $POLKIT_CFLAGS $POLKIT_LIBS])
|
||||
+if test "$with_polkit0" = "yes" ; then
|
||||
+AC_MSG_NOTICE([ polkit: $POLKIT_CFLAGS $POLKIT_LIBS (version 0)])
|
||||
+else
|
||||
+AC_MSG_NOTICE([ polkit: $PKCHECK_PATH (version 1)])
|
||||
+fi
|
||||
else
|
||||
AC_MSG_NOTICE([ polkit: no])
|
||||
fi
|
||||
diff -rupN libvirt-0.7.0/qemud/libvirtd.policy libvirt-0.7.0.new/qemud/libvirtd.policy
|
||||
--- libvirt-0.7.0/qemud/libvirtd.policy 2009-07-22 09:37:32.000000000 -0400
|
||||
+++ libvirt-0.7.0.new/qemud/libvirtd.policy 1969-12-31 19:00:00.000000000 -0500
|
||||
@@ -1,42 +0,0 @@
|
||||
-<!DOCTYPE policyconfig PUBLIC
|
||||
- "-//freedesktop//DTD PolicyKit Policy Configuration 1.0//EN"
|
||||
- "http://www.freedesktop.org/standards/PolicyKit/1.0/policyconfig.dtd">
|
||||
-
|
||||
-<!--
|
||||
-Policy definitions for libvirt daemon
|
||||
-
|
||||
-Copyright (c) 2007 Daniel P. Berrange <berrange redhat com>
|
||||
-
|
||||
-libvirt is licensed to you under the GNU Lesser General Public License
|
||||
-version 2. See COPYING for details.
|
||||
-
|
||||
-NOTE: If you make changes to this file, make sure to validate the file
|
||||
-using the polkit-policy-file-validate(1) tool. Changes made to this
|
||||
-file are instantly applied.
|
||||
--->
|
||||
-
|
||||
-<policyconfig>
|
||||
- <action id="org.libvirt.unix.monitor">
|
||||
- <description>Monitor local virtualized systems</description>
|
||||
- <message>System policy prevents monitoring of local virtualized systems</message>
|
||||
- <defaults>
|
||||
- <!-- Any program can use libvirt in read-only mode for monitoring,
|
||||
- even if not part of a session -->
|
||||
- <allow_any>yes</allow_any>
|
||||
- <allow_inactive>yes</allow_inactive>
|
||||
- <allow_active>yes</allow_active>
|
||||
- </defaults>
|
||||
- </action>
|
||||
-
|
||||
- <action id="org.libvirt.unix.manage">
|
||||
- <description>Manage local virtualized systems</description>
|
||||
- <message>System policy prevents management of local virtualized systems</message>
|
||||
- <defaults>
|
||||
- <!-- Only a program in the active host session can use libvirt in
|
||||
- read-write mode for management, and we require user password -->
|
||||
- <allow_any>no</allow_any>
|
||||
- <allow_inactive>no</allow_inactive>
|
||||
- <allow_active>auth_admin_keep_session</allow_active>
|
||||
- </defaults>
|
||||
- </action>
|
||||
-</policyconfig>
|
||||
diff -rupN libvirt-0.7.0/qemud/libvirtd.policy-0 libvirt-0.7.0.new/qemud/libvirtd.policy-0
|
||||
--- libvirt-0.7.0/qemud/libvirtd.policy-0 1969-12-31 19:00:00.000000000 -0500
|
||||
+++ libvirt-0.7.0.new/qemud/libvirtd.policy-0 2009-08-13 08:37:22.408883879 -0400
|
||||
@@ -0,0 +1,42 @@
|
||||
+<!DOCTYPE policyconfig PUBLIC
|
||||
+ "-//freedesktop//DTD PolicyKit Policy Configuration 1.0//EN"
|
||||
+ "http://www.freedesktop.org/standards/PolicyKit/1.0/policyconfig.dtd">
|
||||
+
|
||||
+<!--
|
||||
+Policy definitions for libvirt daemon
|
||||
+
|
||||
+Copyright (c) 2007 Daniel P. Berrange <berrange redhat com>
|
||||
+
|
||||
+libvirt is licensed to you under the GNU Lesser General Public License
|
||||
+version 2. See COPYING for details.
|
||||
+
|
||||
+NOTE: If you make changes to this file, make sure to validate the file
|
||||
+using the polkit-policy-file-validate(1) tool. Changes made to this
|
||||
+file are instantly applied.
|
||||
+-->
|
||||
+
|
||||
+<policyconfig>
|
||||
+ <action id="org.libvirt.unix.monitor">
|
||||
+ <description>Monitor local virtualized systems</description>
|
||||
+ <message>System policy prevents monitoring of local virtualized systems</message>
|
||||
+ <defaults>
|
||||
+ <!-- Any program can use libvirt in read-only mode for monitoring,
|
||||
+ even if not part of a session -->
|
||||
+ <allow_any>yes</allow_any>
|
||||
+ <allow_inactive>yes</allow_inactive>
|
||||
+ <allow_active>yes</allow_active>
|
||||
+ </defaults>
|
||||
+ </action>
|
||||
+
|
||||
+ <action id="org.libvirt.unix.manage">
|
||||
+ <description>Manage local virtualized systems</description>
|
||||
+ <message>System policy prevents management of local virtualized systems</message>
|
||||
+ <defaults>
|
||||
+ <!-- Only a program in the active host session can use libvirt in
|
||||
+ read-write mode for management, and we require user password -->
|
||||
+ <allow_any>no</allow_any>
|
||||
+ <allow_inactive>no</allow_inactive>
|
||||
+ <allow_active>auth_admin_keep_session</allow_active>
|
||||
+ </defaults>
|
||||
+ </action>
|
||||
+</policyconfig>
|
||||
diff -rupN libvirt-0.7.0/qemud/libvirtd.policy-1 libvirt-0.7.0.new/qemud/libvirtd.policy-1
|
||||
--- libvirt-0.7.0/qemud/libvirtd.policy-1 1969-12-31 19:00:00.000000000 -0500
|
||||
+++ libvirt-0.7.0.new/qemud/libvirtd.policy-1 2009-08-13 08:37:22.412905763 -0400
|
||||
@@ -0,0 +1,42 @@
|
||||
+<!DOCTYPE policyconfig PUBLIC
|
||||
+ "-//freedesktop//DTD PolicyKit Policy Configuration 1.0//EN"
|
||||
+ "http://www.freedesktop.org/standards/PolicyKit/1.0/policyconfig.dtd">
|
||||
+
|
||||
+<!--
|
||||
+Policy definitions for libvirt daemon
|
||||
+
|
||||
+Copyright (c) 2007 Daniel P. Berrange <berrange redhat com>
|
||||
+
|
||||
+libvirt is licensed to you under the GNU Lesser General Public License
|
||||
+version 2. See COPYING for details.
|
||||
+
|
||||
+NOTE: If you make changes to this file, make sure to validate the file
|
||||
+using the polkit-policy-file-validate(1) tool. Changes made to this
|
||||
+file are instantly applied.
|
||||
+-->
|
||||
+
|
||||
+<policyconfig>
|
||||
+ <action id="org.libvirt.unix.monitor">
|
||||
+ <description>Monitor local virtualized systems</description>
|
||||
+ <message>System policy prevents monitoring of local virtualized systems</message>
|
||||
+ <defaults>
|
||||
+ <!-- Any program can use libvirt in read-only mode for monitoring,
|
||||
+ even if not part of a session -->
|
||||
+ <allow_any>yes</allow_any>
|
||||
+ <allow_inactive>yes</allow_inactive>
|
||||
+ <allow_active>yes</allow_active>
|
||||
+ </defaults>
|
||||
+ </action>
|
||||
+
|
||||
+ <action id="org.libvirt.unix.manage">
|
||||
+ <description>Manage local virtualized systems</description>
|
||||
+ <message>System policy prevents management of local virtualized systems</message>
|
||||
+ <defaults>
|
||||
+ <!-- Only a program in the active host session can use libvirt in
|
||||
+ read-write mode for management, and we require user password -->
|
||||
+ <allow_any>no</allow_any>
|
||||
+ <allow_inactive>no</allow_inactive>
|
||||
+ <allow_active>auth_admin_keep</allow_active>
|
||||
+ </defaults>
|
||||
+ </action>
|
||||
+</policyconfig>
|
||||
diff -rupN libvirt-0.7.0/qemud/Makefile.am libvirt-0.7.0.new/qemud/Makefile.am
|
||||
--- libvirt-0.7.0/qemud/Makefile.am 2009-07-22 09:37:32.000000000 -0400
|
||||
+++ libvirt-0.7.0.new/qemud/Makefile.am 2009-08-13 08:37:22.398915449 -0400
|
||||
@@ -21,7 +21,8 @@ EXTRA_DIST = \
|
||||
remote_protocol.x \
|
||||
libvirtd.conf \
|
||||
libvirtd.init.in \
|
||||
- libvirtd.policy \
|
||||
+ libvirtd.policy-0 \
|
||||
+ libvirtd.policy-1 \
|
||||
libvirtd.sasl \
|
||||
libvirtd.sysconf \
|
||||
libvirtd.aug \
|
||||
@@ -147,7 +148,13 @@ endif
|
||||
libvirtd_LDADD += ../src/libvirt.la
|
||||
|
||||
if HAVE_POLKIT
|
||||
+if HAVE_POLKIT0
|
||||
policydir = $(datadir)/PolicyKit/policy
|
||||
+policyfile = libvirtd.policy-0
|
||||
+else
|
||||
+policydir = $(datadir)/polkit-1/actions
|
||||
+policyfile = libvirtd.policy-1
|
||||
+endif
|
||||
endif
|
||||
|
||||
if HAVE_AVAHI
|
||||
@@ -197,7 +204,7 @@ endif
|
||||
if HAVE_POLKIT
|
||||
install-data-polkit:: install-init
|
||||
mkdir -p $(DESTDIR)$(policydir)
|
||||
- $(INSTALL_DATA) $(srcdir)/libvirtd.policy $(DESTDIR)$(policydir)/org.libvirt.unix.policy
|
||||
+ $(INSTALL_DATA) $(srcdir)/$(policyfile) $(DESTDIR)$(policydir)/org.libvirt.unix.policy
|
||||
uninstall-data-polkit:: install-init
|
||||
rm -f $(DESTDIR)$(policydir)/org.libvirt.unix.policy
|
||||
else
|
||||
diff -rupN libvirt-0.7.0/qemud/qemud.c libvirt-0.7.0.new/qemud/qemud.c
|
||||
--- libvirt-0.7.0/qemud/qemud.c 2009-07-22 09:37:32.000000000 -0400
|
||||
+++ libvirt-0.7.0.new/qemud/qemud.c 2009-08-13 08:37:22.419878018 -0400
|
||||
@@ -895,7 +895,7 @@ static struct qemud_server *qemudNetwork
|
||||
}
|
||||
#endif
|
||||
|
||||
-#ifdef HAVE_POLKIT
|
||||
+#if HAVE_POLKIT0
|
||||
if (auth_unix_rw == REMOTE_AUTH_POLKIT ||
|
||||
auth_unix_ro == REMOTE_AUTH_POLKIT) {
|
||||
DBusError derr;
|
||||
@@ -982,7 +982,7 @@ static struct qemud_server *qemudNetwork
|
||||
sock = sock->next;
|
||||
}
|
||||
|
||||
-#ifdef HAVE_POLKIT
|
||||
+#if HAVE_POLKIT0
|
||||
if (server->sysbus)
|
||||
dbus_connection_unref(server->sysbus);
|
||||
#endif
|
||||
diff -rupN libvirt-0.7.0/qemud/qemud.h libvirt-0.7.0.new/qemud/qemud.h
|
||||
--- libvirt-0.7.0/qemud/qemud.h 2009-07-23 12:33:02.000000000 -0400
|
||||
+++ libvirt-0.7.0.new/qemud/qemud.h 2009-08-13 08:37:22.425909852 -0400
|
||||
@@ -34,7 +34,7 @@
|
||||
#include <sasl/sasl.h>
|
||||
#endif
|
||||
|
||||
-#ifdef HAVE_POLKIT
|
||||
+#if HAVE_POLKIT0
|
||||
#include <dbus/dbus.h>
|
||||
#endif
|
||||
|
||||
@@ -253,7 +253,7 @@ struct qemud_server {
|
||||
#if HAVE_SASL
|
||||
char **saslUsernameWhitelist;
|
||||
#endif
|
||||
-#if HAVE_POLKIT
|
||||
+#if HAVE_POLKIT0
|
||||
DBusConnection *sysbus;
|
||||
#endif
|
||||
};
|
||||
diff -rupN libvirt-0.7.0/qemud/remote.c libvirt-0.7.0.new/qemud/remote.c
|
||||
--- libvirt-0.7.0/qemud/remote.c 2009-07-23 12:33:02.000000000 -0400
|
||||
+++ libvirt-0.7.0.new/qemud/remote.c 2009-08-13 08:37:22.431865087 -0400
|
||||
@@ -43,7 +43,7 @@
|
||||
#include <fnmatch.h>
|
||||
#include "virterror_internal.h"
|
||||
|
||||
-#ifdef HAVE_POLKIT
|
||||
+#if HAVE_POLKIT0
|
||||
#include <polkit/polkit.h>
|
||||
#include <polkit-dbus/polkit-dbus.h>
|
||||
#endif
|
||||
@@ -3106,7 +3106,80 @@ remoteDispatchAuthSaslStep (struct qemud
|
||||
#endif /* HAVE_SASL */
|
||||
|
||||
|
||||
-#if HAVE_POLKIT
|
||||
+#if HAVE_POLKIT1
|
||||
+static int
|
||||
+remoteDispatchAuthPolkit (struct qemud_server *server,
|
||||
+ struct qemud_client *client,
|
||||
+ virConnectPtr conn ATTRIBUTE_UNUSED,
|
||||
+ remote_error *rerr,
|
||||
+ void *args ATTRIBUTE_UNUSED,
|
||||
+ remote_auth_polkit_ret *ret)
|
||||
+{
|
||||
+ pid_t callerPid;
|
||||
+ uid_t callerUid;
|
||||
+ const char *action;
|
||||
+ int status = -1;
|
||||
+ char pidbuf[50];
|
||||
+ int rv;
|
||||
+
|
||||
+ virMutexLock(&server->lock);
|
||||
+ virMutexLock(&client->lock);
|
||||
+ virMutexUnlock(&server->lock);
|
||||
+
|
||||
+ action = client->readonly ?
|
||||
+ "org.libvirt.unix.monitor" :
|
||||
+ "org.libvirt.unix.manage";
|
||||
+
|
||||
+ const char * const pkcheck [] = {
|
||||
+ PKCHECK_PATH,
|
||||
+ "--action-id", action,
|
||||
+ "--process", pidbuf,
|
||||
+ "--allow-user-interaction",
|
||||
+ NULL
|
||||
+ };
|
||||
+
|
||||
+ REMOTE_DEBUG("Start PolicyKit auth %d", client->fd);
|
||||
+ if (client->auth != REMOTE_AUTH_POLKIT) {
|
||||
+ VIR_ERROR0(_("client tried invalid PolicyKit init request"));
|
||||
+ goto authfail;
|
||||
+ }
|
||||
+
|
||||
+ if (qemudGetSocketIdentity(client->fd, &callerUid, &callerPid) < 0) {
|
||||
+ VIR_ERROR0(_("cannot get peer socket identity"));
|
||||
+ goto authfail;
|
||||
+ }
|
||||
+
|
||||
+ VIR_INFO(_("Checking PID %d running as %d"), callerPid, callerUid);
|
||||
+
|
||||
+ rv = snprintf(pidbuf, sizeof pidbuf, "%d", callerPid);
|
||||
+ if (rv < 0 || rv >= sizeof pidbuf) {
|
||||
+ VIR_ERROR(_("Caller PID was too large %d"), callerPid);
|
||||
+ goto authfail;
|
||||
+ }
|
||||
+
|
||||
+ if (virRun(NULL, pkcheck, &status) < 0) {
|
||||
+ VIR_ERROR(_("Cannot invoke %s"), PKCHECK_PATH);
|
||||
+ goto authfail;
|
||||
+ }
|
||||
+ if (status != 0) {
|
||||
+ VIR_ERROR(_("Policy kit denied action %s from pid %d, uid %d, result: %d\n"),
|
||||
+ action, callerPid, callerUid, status);
|
||||
+ goto authfail;
|
||||
+ }
|
||||
+ VIR_INFO(_("Policy allowed action %s from pid %d, uid %d"),
|
||||
+ action, callerPid, callerUid);
|
||||
+ ret->complete = 1;
|
||||
+ client->auth = REMOTE_AUTH_NONE;
|
||||
+
|
||||
+ virMutexUnlock(&client->lock);
|
||||
+ return 0;
|
||||
+
|
||||
+authfail:
|
||||
+ remoteDispatchAuthError(rerr);
|
||||
+ virMutexUnlock(&client->lock);
|
||||
+ return -1;
|
||||
+}
|
||||
+#elif HAVE_POLKIT0
|
||||
static int
|
||||
remoteDispatchAuthPolkit (struct qemud_server *server,
|
||||
struct qemud_client *client,
|
||||
@@ -3217,7 +3290,7 @@ authfail:
|
||||
return -1;
|
||||
}
|
||||
|
||||
-#else /* HAVE_POLKIT */
|
||||
+#else /* !HAVE_POLKIT0 & !HAVE_POLKIT1*/
|
||||
|
||||
static int
|
||||
remoteDispatchAuthPolkit (struct qemud_server *server ATTRIBUTE_UNUSED,
|
||||
@@ -3231,7 +3304,7 @@ remoteDispatchAuthPolkit (struct qemud_s
|
||||
remoteDispatchAuthError(rerr);
|
||||
return -1;
|
||||
}
|
||||
-#endif /* HAVE_POLKIT */
|
||||
+#endif /* HAVE_POLKIT1 */
|
||||
|
||||
|
||||
/***************************************************************
|
||||
diff -rupN libvirt-0.7.0/src/remote_internal.c libvirt-0.7.0.new/src/remote_internal.c
|
||||
--- libvirt-0.7.0/src/remote_internal.c 2009-07-29 10:42:15.000000000 -0400
|
||||
+++ libvirt-0.7.0.new/src/remote_internal.c 2009-08-13 10:55:57.607899170 -0400
|
||||
@@ -6201,6 +6201,7 @@ remoteAuthPolkit (virConnectPtr conn, st
|
||||
virConnectAuthPtr auth)
|
||||
{
|
||||
remote_auth_polkit_ret ret;
|
||||
+#if HAVE_POLKIT0
|
||||
int i, allowcb = 0;
|
||||
virConnectCredential cred = {
|
||||
VIR_CRED_EXTERNAL,
|
||||
@@ -6210,8 +6211,10 @@ remoteAuthPolkit (virConnectPtr conn, st
|
||||
NULL,
|
||||
0,
|
||||
};
|
||||
+#endif
|
||||
DEBUG0("Client initialize PolicyKit authentication");
|
||||
|
||||
+#if HAVE_POLKIT0
|
||||
if (auth && auth->cb) {
|
||||
/* Check if the necessary credential type for PolicyKit is supported */
|
||||
for (i = 0 ; i < auth->ncredtype ; i++) {
|
||||
@@ -6220,6 +6223,7 @@ remoteAuthPolkit (virConnectPtr conn, st
|
||||
}
|
||||
|
||||
if (allowcb) {
|
||||
+ DEBUG0("Client run callback for PolicyKit authentication");
|
||||
/* Run the authentication callback */
|
||||
if ((*(auth->cb))(&cred, 1, auth->cbdata) < 0) {
|
||||
virRaiseError (in_open ? NULL : conn, NULL, NULL, VIR_FROM_REMOTE,
|
||||
@@ -6233,6 +6237,9 @@ remoteAuthPolkit (virConnectPtr conn, st
|
||||
} else {
|
||||
DEBUG0("No auth callback provided");
|
||||
}
|
||||
+#else
|
||||
+ DEBUG0("No auth callback required for PolicyKit-1");
|
||||
+#endif
|
||||
|
||||
memset (&ret, 0, sizeof ret);
|
||||
if (call (conn, priv, in_open, REMOTE_PROC_AUTH_POLKIT,
|
||||
@@ -1,248 +0,0 @@
|
||||
From 50f5a6c7ab7795fb6ade4bb24849fa2bab5084dd Mon Sep 17 00:00:00 2001
|
||||
From: Mark McLoughlin <markmc@redhat.com>
|
||||
Date: Wed, 29 Jul 2009 08:40:17 +0100
|
||||
Subject: [PATCH] Convert NEWS to UTF-8
|
||||
|
||||
* docs/news.xsl: request UTF-8 as the output encoding
|
||||
|
||||
* NEWS: re-generate with UTF-8 encoding
|
||||
---
|
||||
NEWS | 70 ++++++++++++++++++++++++++++----------------------------
|
||||
docs/news.xsl | 2 +-
|
||||
2 files changed, 36 insertions(+), 36 deletions(-)
|
||||
|
||||
diff --git a/NEWS b/NEWS
|
||||
index 447d2b4..0a838b9 100644
|
||||
--- a/NEWS
|
||||
+++ b/NEWS
|
||||
@@ -137,7 +137,7 @@
|
||||
- Improvements: add SCSI storage rescan (David Allan), rootless
|
||||
LXC containers support improvements (Serge Hallyn), getHostname
|
||||
support for LXC (Dan Smith), cleanup and logging output of some
|
||||
- domain functions (Guido G<>nther), drop pool lock when allocating
|
||||
+ domain functions (Guido Günther), drop pool lock when allocating
|
||||
volumes (Cole Robinson), LXC handle kernel without CLONE_NEWUSER
|
||||
support (Serge Hallyn), cpu pinning on defined Xen domains (Takahashi
|
||||
Tomohiro), dynamic bridge names support (Soren Hansen), LXC use
|
||||
@@ -145,7 +145,7 @@
|
||||
virNodeDeviceCreateXML and virNodeDeviceDestroy entry points
|
||||
(Dave Allan)
|
||||
- Cleanups: don't hardcode getgrnam_r buffer to 1024 bytes (Guido
|
||||
- G<>nther), qemudBuildCommandLine API cleanup (Daniel Berrange),
|
||||
+ Günther), qemudBuildCommandLine API cleanup (Daniel Berrange),
|
||||
|
||||
|
||||
|
||||
@@ -214,15 +214,15 @@
|
||||
to avoid crashes (Daniel Berrange), mark defined network descriptions
|
||||
as persistent (Cole Robinson), qemu+tls handshake negotiation hang
|
||||
(Chris Lalancette)
|
||||
- - Improvements: don't hardcode ssh port (Guido G<>nther), new test
|
||||
+ - Improvements: don't hardcode ssh port (Guido Günther), new test
|
||||
cases and testing infrastructure (Jim Meyering), improve the
|
||||
SExpr parser (John Levon), proper error reporting on xend
|
||||
shutdown command (John Levon), proper handling of errors when
|
||||
- saving QEmu domains state (Guido G<>nther), revamp of the internal
|
||||
+ saving QEmu domains state (Guido Günther), revamp of the internal
|
||||
error memory APIs (John Levon), better virsh error reporting (John
|
||||
Levon), more daemon options to allow running multiple daemons (Jim
|
||||
- Meyering), error handling when creating a QEmu domain (Guido G<>nther),
|
||||
- fix timeouts in QEmu log reading (Guido G<>nther), migration with
|
||||
+ Meyering), error handling when creating a QEmu domain (Guido Günther),
|
||||
+ fix timeouts in QEmu log reading (Guido Günther), migration with
|
||||
xend 3.3 fixes (John Levon), virsh XML dump flags cleanup (Cole
|
||||
Robinson), fix build with loadable drivers (Maximilian Wilhelm),
|
||||
internal XML APIs to read long long and hexa values (Mark
|
||||
@@ -236,7 +236,7 @@
|
||||
(Jim Meyering), many error handling cleanups (Jim Meyering), XML
|
||||
module cleanups (Mark McLoughlin), compiler warning (Maximilian
|
||||
Wilhelm), daemon TCP listen cleanup (Cole Robinson), size_t type
|
||||
- cleanup (Guido G<>nther), parallel make fix (Michael Marineau),
|
||||
+ cleanup (Guido Günther), parallel make fix (Michael Marineau),
|
||||
storage error diagnostic fix (Ryota Ozaki), remove redundant monitor
|
||||
watch variable (Cole Robinson), qemu AttachDevice error report
|
||||
improvement (Cole Robinson), virsh output cleanup (Jim Meyering),
|
||||
@@ -248,7 +248,7 @@
|
||||
0.6.0: Jan 31 2009:
|
||||
- New features: thread safety of the API and event handling (Daniel
|
||||
Berrange), allow QEmu domains to survive daemon restart (Guido
|
||||
- G<>nther), extended logging capabilities, support copy-on-write
|
||||
+ Günther), extended logging capabilities, support copy-on-write
|
||||
storage volumes (Daniel Berrange), support of storage cache
|
||||
control options for QEmu/KVM (Daniel Berrange)
|
||||
- Portability: fix old DBus API problem, Debian portability fix
|
||||
@@ -260,13 +260,13 @@
|
||||
solaris Xen fixes (John Levon), RPC portability to Solaris (Daniel
|
||||
Berrange)
|
||||
- Documentation: typo fixes (Richard Jones), logging support,
|
||||
- vnc keymap attributes (Guido G<>nther), HACKING file updates
|
||||
+ vnc keymap attributes (Guido Günther), HACKING file updates
|
||||
(Jim Meyering), new PCI passthrough format, libvirt-qpid and
|
||||
UML driver documentation (Daniel Berrange), provide RNG schemas
|
||||
for all XML formats used in libvirt APIs (Daniel Berrange),
|
||||
- Bug fixes: segfault on virtual network without bridge name (Cole
|
||||
Robinson), various locking fixes (Cole Robinson), fix serial
|
||||
- and parallel devices on tcp/unix/telnet (Guido G<>nther), leak
|
||||
+ and parallel devices on tcp/unix/telnet (Guido Günther), leak
|
||||
in daemon (Jim Meyering), storage driver segfault (Miloslav TrmaC),
|
||||
missing check in read-only connections (Daniel Berrange),
|
||||
OpenVZ crash and mutex fixes (Anton Protopopov), couple of
|
||||
@@ -282,15 +282,15 @@
|
||||
- Improvements: driver infrastructure and locking (Daniel Berrange),
|
||||
Test driver infrastructure (Daniel Berrange), parallelism in the
|
||||
daemon and associated config (Daniel Berrange), virsh help cleanups
|
||||
- (Jim Meyering), logrotate daemon logs (Guido G<>nther), more
|
||||
+ (Jim Meyering), logrotate daemon logs (Guido Günther), more
|
||||
regression tests (Jim Meyering), QEmu SDL graphics (Itamar Heim),
|
||||
add --version flag to daemon (Dave Allan), memory consumption
|
||||
cleanup (Dave Allan), QEmu pid file and XML states for daemon
|
||||
- restart (Guido G<>nther), gnulib updates (Jim Meyering and
|
||||
+ restart (Guido Günther), gnulib updates (Jim Meyering and
|
||||
Dan Berrange), PCI passthrough for KVM (Jason Krieg), generic
|
||||
internal thread API (Daniel Berrange), RHEL-5 specific Xen
|
||||
configure option and code (Markus Armbruster), save domain
|
||||
- state as string in status file (Guido G<>nther), add locking
|
||||
+ state as string in status file (Guido Günther), add locking
|
||||
to all API entry points (Daniel Berrange), new ref counting APIs
|
||||
(Daniel Berrange), IP address for Xen bridges (John Levon),
|
||||
driver format for disk file types (Daniel Berrange), improve
|
||||
@@ -303,15 +303,15 @@
|
||||
(Jim Meyering), gethostby* cleanup and test (Jim Meyering), some
|
||||
code fixes (Dave Allan), various code cleanup (Jim Meyering),
|
||||
virsh argument handling cleanup (Jim Meyering), virAsprintf
|
||||
- cleanup replacement (Guido G<>nther), QEmu monitor reads (Cole
|
||||
- Robinson), Makefile cleanups (Guido G<>nther), Xen code cleanups
|
||||
+ cleanup replacement (Guido Günther), QEmu monitor reads (Cole
|
||||
+ Robinson), Makefile cleanups (Guido Günther), Xen code cleanups
|
||||
(John Levon), revamp of ELF export scripts (John Levon), domain
|
||||
event callback args (John Levon), enforce use of pid_t (John Levon),
|
||||
virsh pool-*-as XML code merge (Cole Robinson), xgettext warnings
|
||||
- (Jim Meyering), add virKillProcess (Guido G<>nther), add
|
||||
+ (Jim Meyering), add virKillProcess (Guido Günther), add
|
||||
virGetHostname (David Lutterkort), add flags argument to the full
|
||||
- XML parsing stack (Guido G<>nther), various daemon code cleanups
|
||||
- (Guido G<>nther), handling of daemon missing config file (Jim
|
||||
+ XML parsing stack (Guido Günther), various daemon code cleanups
|
||||
+ (Guido Günther), handling of daemon missing config file (Jim
|
||||
Meyering), rpcgen invocation cleanup (Richard Jones), devhelp
|
||||
builkd makefile cleanups (John Levon), update error handling for
|
||||
threading (Daniel Berrange), remove all non-rentrant POSIX calls
|
||||
@@ -331,7 +331,7 @@
|
||||
- Bug fixes: add a delay in storage backend for disks to show up
|
||||
(Chris Lalancette), fix parsing for CDRom device with no source
|
||||
(Daniel Berrange), use xenstore to list domains to avoid some
|
||||
- bugs (Guido G<>nther), remove a leak in xen inotify code (Daniel
|
||||
+ bugs (Guido Günther), remove a leak in xen inotify code (Daniel
|
||||
Berrange), UML driver freeing of uninitialialized variable (Ron
|
||||
Yorston), fix UML inotify code (Daniel Berrange), crash when
|
||||
adding storage without a format (Cole Robinson)
|
||||
@@ -339,8 +339,8 @@
|
||||
max memory (Jim Fehlig), allow remote://hostname/ URI for automatic
|
||||
probe of hypervisors (Daniel Berrange), fix daemon configuration
|
||||
regression testing (Jim Meyering ), check /usr/bin/kvm for QEmu
|
||||
- driver init (Guido G<>nther), proper active vs. inactive
|
||||
- differentiation (Guido G<>nther), improve MTU setting on tap
|
||||
+ driver init (Guido Günther), proper active vs. inactive
|
||||
+ differentiation (Guido Günther), improve MTU setting on tap
|
||||
interfaces (Eduardo Habkost), increase timeout for initial QEmu
|
||||
monitor poll (Cole Robinson)
|
||||
- Cleanups:fix improper initialisations (Jim Meyering)
|
||||
@@ -350,9 +350,9 @@
|
||||
- New features: CPU and scheduler support for LXC (Dan Smith), SDL display configuration (Daniel Berrange), domain lifecycle event support for QEmu and Xen with python bindings (Ben Guthro and Daniel Berrange), KVM/QEmu migration support (Rich Jones and Chris Lalancette), User Mode Linux driver (Daniel Berrange), API for node device enumeration using HAL and DeviceKit with python bindings (David Lively),
|
||||
- Portability: RHEL build fixes, VPATH build (Guido Gunther), many MinGW related cleanups and fixes (Richard Jones), compilation without libvirtd (Richard Jones), Add a Windows icon (Richard Jones), sys/poll.h portability fixes (Daniel Berrange), gnulib and mingw cleanups (Jim Meyering),
|
||||
- Documentation: virsh man page cleanups (Mark McLoughlin), doc for NIC model selection (Richard Jones), monitoring section, link to AMQP bindings, inew APIs, UML driver docs (Daniel Berrange),
|
||||
- - Bug fixes: Xen interfaces ordering (Jim Fehlig), startup timeout with multiple pty (Cole Robinson), segfault if QEmu without active virtual network (Cole Robinson), qemu small leak (Eduardo Habkost), index creation for more than 26 disks (Sanjay Rao and Chris Wright), virRealloc handling of 0 (Daniel Berrange), missing pointer initialization (Chris Lalancette), bus device index bug (Guido G<>nther), avoid crash in some error patch (Chris Lalancette), fix a problem in storage back-end (Chris Lalancette), minimum domain memory size check for Xen (Shigeki Sakamoto), switch off QEmu cache if device is shared (Charles Duffy), logical volume definition before scan bug (Chris Lalancette), a couple of memory leaks on QEmu vnc (Jim Meyering), lvs parsing fixes (Cole Robinson),
|
||||
- - Improvements: LXC resources control and internal cgroup API (Dan Smith), virDomainCreateLinux renamed virDomainDefineXML, network driver modularization (Daniel Berrange), change the way domain and net are reported in errors (Jim Meyering), partition table scan on iSCSI (Chris Lalancette), qemudDiskDeviceName to handle normal disks (Guido G<>nther), qemudDomainBlockStats improvement (Guido G<>nther), scsi/virtio hotplug support for KVM (Guido G<>nther), USB hot addition in QEmu (Guido G<>nther), logical pool and storage backend XML dump improvement (Chris Lalancette), MAC addresses prefix per driver (Daniel Berrange), OpenVZ getVersion support (Daniel Berrange), hot removal of scsi/virtio disks for KVM (Guido G<>nther), test storage driver (Cole Robinson), iSCSI and disk storage driver improvement on path handling (Chris Lalancette), UUID and ID support for Xenner (Daniel Berrange), better logging when when executing commands (Cole Robinson), bridged network for OpenVZ (Daniel Berrange), OpenVZ config file params (Evgeniy Sokolov), allow to build drivers as libtool convenience libs (Daniel Berrange), fully versioned linker script for exported ABI (Daniel Berrange), Push URI probing down into drivers open (Daniel Berrange), move all stateful drivers into the daemon binary (Daniel Berrange), improve domain event with a detail field (Daniel Berrange), domain events for QEMU driver (Daniel Berrange), event unregister callback crash (David Lively), plug a few leaks (Daniel Berrange), internal APIs for handling node device XML config (David Lively), tweaks to node device implementation (Daniel Berrange), OpenVZ vCPUs values init (Evgeniy Sokolov)
|
||||
- - Cleanups: C99 initializers (Guido Gunther), test output (Cole Robinson), debug macro centralization (Cole Robinson), various error handling (Guido G<>nther), safewrite use cleanup (Jim Meyering), centralize error reporting logic (Cole Robinson), avoid printf warnings (Daniel Berrange), use arrays instead of list for internal APIs (Daniel Berrange), remove many format string warnings Jim Meyering), avoid syntax check warnings (Chris Lalancette), improve po-check and list generation (Jim Meyering), .gitignore generation and handling (Jim Meyering), use ARRAY_CARDINALITY (Jim Meyering), gnulib updates and switch to use netdb.h (Jim Meyering), drop usage of socket_errno (Jim Meyering), remove socketcompat.h (Jim Meyering), more tests (Jim Meyering), drop virStringList (Daniel Berrange), reformatting and isolation of the error APIs (Daniel Berrange), cleanup internal.h and move internal APIs in specific headers (Daniel Berrange), move domain events helpers into domain_events.c (Daniel Berrange), cleanup the way optional modules are compiled (Daniel Berrange), add new logging module, optional dlopen of drivers (Daniel Berrange), various new tests (Jim Meyering), cleanups when Xen is not configured in (Daniel Berrange), add some missing functions comments (Jim Meyering),
|
||||
+ - Bug fixes: Xen interfaces ordering (Jim Fehlig), startup timeout with multiple pty (Cole Robinson), segfault if QEmu without active virtual network (Cole Robinson), qemu small leak (Eduardo Habkost), index creation for more than 26 disks (Sanjay Rao and Chris Wright), virRealloc handling of 0 (Daniel Berrange), missing pointer initialization (Chris Lalancette), bus device index bug (Guido Günther), avoid crash in some error patch (Chris Lalancette), fix a problem in storage back-end (Chris Lalancette), minimum domain memory size check for Xen (Shigeki Sakamoto), switch off QEmu cache if device is shared (Charles Duffy), logical volume definition before scan bug (Chris Lalancette), a couple of memory leaks on QEmu vnc (Jim Meyering), lvs parsing fixes (Cole Robinson),
|
||||
+ - Improvements: LXC resources control and internal cgroup API (Dan Smith), virDomainCreateLinux renamed virDomainDefineXML, network driver modularization (Daniel Berrange), change the way domain and net are reported in errors (Jim Meyering), partition table scan on iSCSI (Chris Lalancette), qemudDiskDeviceName to handle normal disks (Guido Günther), qemudDomainBlockStats improvement (Guido Günther), scsi/virtio hotplug support for KVM (Guido Günther), USB hot addition in QEmu (Guido Günther), logical pool and storage backend XML dump improvement (Chris Lalancette), MAC addresses prefix per driver (Daniel Berrange), OpenVZ getVersion support (Daniel Berrange), hot removal of scsi/virtio disks for KVM (Guido Günther), test storage driver (Cole Robinson), iSCSI and disk storage driver improvement on path handling (Chris Lalancette), UUID and ID support for Xenner (Daniel Berrange), better logging when when executing commands (Cole Robinson), bridged network for OpenVZ (Daniel Berrange), OpenVZ config file params (Evgeniy Sokolov), allow to build drivers as libtool convenience libs (Daniel Berrange), fully versioned linker script for exported ABI (Daniel Berrange), Push URI probing down into drivers open (Daniel Berrange), move all stateful drivers into the daemon binary (Daniel Berrange), improve domain event with a detail field (Daniel Berrange), domain events for QEMU driver (Daniel Berrange), event unregister callback crash (David Lively), plug a few leaks (Daniel Berrange), internal APIs for handling node device XML config (David Lively), tweaks to node device implementation (Daniel Berrange), OpenVZ vCPUs values init (Evgeniy Sokolov)
|
||||
+ - Cleanups: C99 initializers (Guido Gunther), test output (Cole Robinson), debug macro centralization (Cole Robinson), various error handling (Guido Günther), safewrite use cleanup (Jim Meyering), centralize error reporting logic (Cole Robinson), avoid printf warnings (Daniel Berrange), use arrays instead of list for internal APIs (Daniel Berrange), remove many format string warnings Jim Meyering), avoid syntax check warnings (Chris Lalancette), improve po-check and list generation (Jim Meyering), .gitignore generation and handling (Jim Meyering), use ARRAY_CARDINALITY (Jim Meyering), gnulib updates and switch to use netdb.h (Jim Meyering), drop usage of socket_errno (Jim Meyering), remove socketcompat.h (Jim Meyering), more tests (Jim Meyering), drop virStringList (Daniel Berrange), reformatting and isolation of the error APIs (Daniel Berrange), cleanup internal.h and move internal APIs in specific headers (Daniel Berrange), move domain events helpers into domain_events.c (Daniel Berrange), cleanup the way optional modules are compiled (Daniel Berrange), add new logging module, optional dlopen of drivers (Daniel Berrange), various new tests (Jim Meyering), cleanups when Xen is not configured in (Daniel Berrange), add some missing functions comments (Jim Meyering),
|
||||
|
||||
|
||||
0.4.6: Sep 23 2008:
|
||||
@@ -364,7 +364,7 @@
|
||||
OpenVZ (Evgeniy Sokolov), fix parsing of pool without a source
|
||||
(Chris Lalancette and Daniel Berrange)
|
||||
- Improvements: add storage disk volume delete (Cole Robinson),
|
||||
- KVM dynamic max CPU detection (Guido G<>nther), spec file improvement
|
||||
+ KVM dynamic max CPU detection (Guido Günther), spec file improvement
|
||||
for minimal builds (Ben Guthro), improved error message in XM
|
||||
configuration module (Richard Jones), network config in OpenVZ
|
||||
support (Evgeniy Sokolov), enable stopping a pool in logical
|
||||
@@ -379,7 +379,7 @@
|
||||
unified XML domain and network parsing for all drivers (Daniel
|
||||
Berrange), OpenVZ features improvements (Evgeniy Sokolov),
|
||||
OpenVZ and Linux containers support now default, USB device
|
||||
- passthrough for QEmu/KVM (Guido G<>nther), storage pool source
|
||||
+ passthrough for QEmu/KVM (Guido Günther), storage pool source
|
||||
discovery (David Lively)
|
||||
- Portability: fixes for MinGW (Atsushi SAKAI and Daniel Berrange),
|
||||
detection of xen lib improvement (David Lively),
|
||||
@@ -389,9 +389,9 @@
|
||||
SAKAI and Daniel Berrange), HTML generation fix, -lpthread explicit
|
||||
linking when needed (Jim Meyering)
|
||||
- Documentation: various typo fixes (Anton Protopopov, Toth
|
||||
- Istv<74>n, Atsushi SAKAI, Nguyen Anh Quynh),
|
||||
+ István, Atsushi SAKAI, Nguyen Anh Quynh),
|
||||
Java bindings docs, remove Xen centric
|
||||
- comments (Guido G<>nther), various typo in comments (Chris
|
||||
+ comments (Guido Günther), various typo in comments (Chris
|
||||
Lalancette), docs and API comments fixes (Charles Duffy),
|
||||
how to contribute to open source link (Richard Jones),
|
||||
memory unit fixups (matthew chan)
|
||||
@@ -401,14 +401,14 @@
|
||||
in QEmu/KVM (Daniel Berrange), fix OpenVZ probe function (Evgeniy
|
||||
Sokolov), ID related lookup fixes in OpenVZ (Evgeniy Sokolov),
|
||||
pool cration for netfs (Cole Robinson), check for migrate support
|
||||
- with QEmu (Guido G<>nther), check against double create with QEmu
|
||||
- (Guido G<>nther), broken open failure detection in QEmu (Guido
|
||||
- G<>nther), UUID string conversions in QEmu (Guido G<>nther),
|
||||
+ with QEmu (Guido Günther), check against double create with QEmu
|
||||
+ (Guido Günther), broken open failure detection in QEmu (Guido
|
||||
+ Günther), UUID string conversions in QEmu (Guido Günther),
|
||||
various small cleanup and bug fixes (Daniel Berrange), ID
|
||||
related fixes in the test driver (Daniel Berrange), better error
|
||||
reporting on XML parsing (Daniel Berrange), empty CD-ROM source
|
||||
device section (Chris Lalancette), avoid crashes for interface
|
||||
- without a name in QEmu (Guido G<>nther), provide the real
|
||||
+ without a name in QEmu (Guido Günther), provide the real
|
||||
vncport (Charles Duffy), fix forward delay (Daniel Berrange),
|
||||
new VM state is initialized to be SHUTOFF (Daniel Berrange),
|
||||
virsh attach-disk bug fixes (Chris Lalancette), veth clash
|
||||
@@ -440,7 +440,7 @@
|
||||
(Daniel Berrange), virsh "edit" command (Richard Jones), save
|
||||
UUID of OpenVZ domains (Evgeniy Sokolov), improve xen blocks
|
||||
statistics (Chris Lalancette), gnulib updates (Jim Meyering),
|
||||
- allow to add disk as USB devices (Guido G<>nther), LXC container
|
||||
+ allow to add disk as USB devices (Guido Günther), LXC container
|
||||
process should survive libvirtd restarts (Daniel Berrange), allow
|
||||
to define static host domain configs, number of CPU used by
|
||||
OpenVZ domains (Evgeniy Sokolov), private root fs for LXC (Daniel
|
||||
@@ -572,9 +572,9 @@
|
||||
driver (Cole Robinson), xen and hvm added to test driver capabilities
|
||||
(Cole Robinson)
|
||||
- Code cleanup: remove unused getopt header (Jim Meyering), mark more
|
||||
- strings as translatable (Guido G<>nther and Jim Meyering), convert
|
||||
+ strings as translatable (Guido Günther and Jim Meyering), convert
|
||||
error strings to something meaningful and translatable (Jim Meyering),
|
||||
- Linux Containers code cleanup, last error initializer (Guido G<>nther)
|
||||
+ Linux Containers code cleanup, last error initializer (Guido Günther)
|
||||
|
||||
|
||||
0.4.1: Mar 3 2008:
|
||||
diff --git a/docs/news.xsl b/docs/news.xsl
|
||||
index a190120..e35030e 100644
|
||||
--- a/docs/news.xsl
|
||||
+++ b/docs/news.xsl
|
||||
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0"?>
|
||||
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
||||
version="1.0">
|
||||
- <xsl:output method="text" encoding="ISO-8859-1"/>
|
||||
+ <xsl:output method="text" encoding="UTF-8"/>
|
||||
|
||||
<xsl:template match="/">
|
||||
<xsl:text>
|
||||
--
|
||||
1.6.2.5
|
||||
|
||||
89
libvirt.spec
89
libvirt.spec
@@ -78,12 +78,23 @@
|
||||
Summary: Library providing a simple API virtualization
|
||||
Name: libvirt
|
||||
Version: 0.7.0
|
||||
Release: 0.5.gitf055724%{?dist}%{?extra_release}
|
||||
Release: 4%{?dist}%{?extra_release}
|
||||
License: LGPLv2+
|
||||
Group: Development/Libraries
|
||||
Source: libvirt-0.7.0-0.1.gitf055724.tar.gz
|
||||
Source: libvirt-%{version}.tar.gz
|
||||
|
||||
Patch01: libvirt-convert-news-to-utf8.patch
|
||||
# Make sure qemu can access kernel/initrd (bug #516034)
|
||||
Patch01: libvirt-0.7.0-chown-kernel-initrd-before-spawning-qemu.patch
|
||||
|
||||
# Don't fail to start network if ipv6 modules is not loaded (bug #516497)
|
||||
Patch02: libvirt-0.7.0-handle-kernels-with-no-ipv6-support.patch
|
||||
|
||||
# Policykit rewrite (bug #499970)
|
||||
# NB remove autoreconf hack & extra BRs when this goes away
|
||||
Patch03: libvirt-0.7.0-policy-kit-rewrite.patch
|
||||
|
||||
# Log and ignore NUMA topology problems (rhbz #506590)
|
||||
Patch04: libvirt-0.7.0-numa-ignore-fail.patch
|
||||
|
||||
# Temporary hack till PulseAudio autostart problems are sorted
|
||||
# out when SELinux enforcing (bz 486112)
|
||||
@@ -102,8 +113,12 @@ Requires: iptables
|
||||
# needed for device enumeration
|
||||
Requires: hal
|
||||
%if %{with_polkit}
|
||||
%if 0%{?fedora} >= 12
|
||||
Requires: polkit >= 0.93
|
||||
%else
|
||||
Requires: PolicyKit >= 0.6
|
||||
%endif
|
||||
%endif
|
||||
%if %{with_storage_fs}
|
||||
# For mount/umount in FS driver
|
||||
BuildRequires: util-linux
|
||||
@@ -157,8 +172,13 @@ BuildRequires: bridge-utils
|
||||
BuildRequires: cyrus-sasl-devel
|
||||
%endif
|
||||
%if %{with_polkit}
|
||||
%if 0%{?fedora} >= 12
|
||||
# Only need the binary, not -devel
|
||||
BuildRequires: polkit >= 0.93
|
||||
%else
|
||||
BuildRequires: PolicyKit-devel >= 0.6
|
||||
%endif
|
||||
%endif
|
||||
%if %{with_storage_fs}
|
||||
# For mount/umount in FS driver
|
||||
BuildRequires: util-linux
|
||||
@@ -201,6 +221,9 @@ BuildRequires: netcf-devel
|
||||
# Fedora build root suckage
|
||||
BuildRequires: gawk
|
||||
|
||||
# Temp hack for patch 3
|
||||
BuildRequires: libtool autoconf automake gettext cvs
|
||||
|
||||
%description
|
||||
Libvirt is a C toolkit to interact with the virtualization capabilities
|
||||
of recent versions of Linux (and other OSes). The main package includes
|
||||
@@ -255,6 +278,9 @@ of recent versions of Linux (and other OSes).
|
||||
%setup -q
|
||||
|
||||
%patch01 -p1
|
||||
%patch02 -p1
|
||||
%patch03 -p1
|
||||
%patch04 -p1
|
||||
|
||||
%patch200 -p0
|
||||
|
||||
@@ -347,6 +373,9 @@ of recent versions of Linux (and other OSes).
|
||||
%define _without_netcf --without-netcf
|
||||
%endif
|
||||
|
||||
# Temp hack for patch 3
|
||||
autoreconf -if
|
||||
|
||||
%configure %{?_without_xen} \
|
||||
%{?_without_qemu} \
|
||||
%{?_without_openvz} \
|
||||
@@ -423,6 +452,18 @@ chmod 0644 $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/libvirtd
|
||||
%clean
|
||||
rm -fr %{buildroot}
|
||||
|
||||
%pre
|
||||
%if 0%{?fedora} >= 12
|
||||
# Normally 'setup' adds this in /etc/passwd, but this is
|
||||
# here for case of upgrades from earlier Fedora. This
|
||||
# UID/GID pair is reserved for qemu:qemu
|
||||
getent group kvm >/dev/null || groupadd -g 36 -r kvm
|
||||
getent group qemu >/dev/null || groupadd -g 107 -r qemu
|
||||
getent passwd qemu >/dev/null || \
|
||||
useradd -r -u 107 -g qemu -G kvm -d / -s /sbin/nologin \
|
||||
-c "qemu user" qemu
|
||||
%endif
|
||||
|
||||
%post
|
||||
|
||||
%if %{with_libvirtd}
|
||||
@@ -488,8 +529,8 @@ fi
|
||||
%dir %{_localstatedir}/run/libvirt/
|
||||
|
||||
%dir %{_localstatedir}/lib/libvirt/
|
||||
%dir %attr(0700, root, root) %{_localstatedir}/lib/libvirt/images/
|
||||
%dir %attr(0700, root, root) %{_localstatedir}/lib/libvirt/boot/
|
||||
%dir %attr(0711, root, root) %{_localstatedir}/lib/libvirt/images/
|
||||
%dir %attr(0711, root, root) %{_localstatedir}/lib/libvirt/boot/
|
||||
%dir %attr(0700, root, root) %{_localstatedir}/cache/libvirt/
|
||||
|
||||
%if %{with_qemu}
|
||||
@@ -524,8 +565,12 @@ fi
|
||||
%endif
|
||||
|
||||
%if %{with_polkit}
|
||||
%if 0%{?fedora} >= 12
|
||||
%{_datadir}/polkit-1/actions/org.libvirt.unix.policy
|
||||
%else
|
||||
%{_datadir}/PolicyKit/policy/org.libvirt.unix.policy
|
||||
%endif
|
||||
%endif
|
||||
|
||||
%dir %attr(0700, root, root) %{_localstatedir}/log/libvirt/
|
||||
%if %{with_qemu}
|
||||
@@ -604,6 +649,40 @@ fi
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
* Thu Aug 13 2009 Daniel P. Berrange <berrange@redhat.com> - 0.7.0-4
|
||||
- Rewrite policykit support (rhbz #499970)
|
||||
- Log and ignore NUMA topology problems (rhbz #506590)
|
||||
|
||||
* Mon Aug 10 2009 Mark McLoughlin <markmc@redhat.com> - 0.7.0-3
|
||||
- Don't fail to start network if ipv6 modules is not loaded (#516497)
|
||||
|
||||
* Thu Aug 6 2009 Mark McLoughlin <markmc@redhat.com> - 0.7.0-2
|
||||
- Make sure qemu can access kernel/initrd (bug #516034)
|
||||
- Set perms on /var/lib/libvirt/boot to 0711 (bug #516034)
|
||||
|
||||
* Wed Aug 5 2009 Daniel Veillard <veillard@redhat.com> - 0.7.0-1
|
||||
- Upstream release of 0.7.0
|
||||
- ESX, VBox3, Power Hypervisor drivers
|
||||
- new net filesystem glusterfs
|
||||
- Storage cloning for LVM and Disk backends
|
||||
- interface implementation based on netcf
|
||||
- Support cgroups in QEMU driver
|
||||
- QEmu hotplug NIC support
|
||||
- a lot of fixes
|
||||
|
||||
* Fri Jul 31 2009 Mark McLoughlin <markmc@redhat.com> - 0.7.0-0.9.gite195b43
|
||||
- Set perms on /var/lib/libvirt/images to 0711
|
||||
|
||||
* Thu Jul 30 2009 Mark McLoughlin <markmc@redhat.com> - 0.7.0-0.8.gite195b43
|
||||
- Add patch from upstream to fix qemu pidfile perms problem
|
||||
|
||||
* Thu Jul 30 2009 Daniel P. Berrange <berrange@redhat.com> - 0.7.0-0.7.gite195b43
|
||||
- Create qemu/kvm user & group to fix upgrades
|
||||
|
||||
* Wed Jul 29 2009 Daniel Veillard <veillard@redhat.com> - 0.7.0-0.6.gite195b43
|
||||
- another prerelease with qemu, uml and remote patches
|
||||
- drop the news patch as it's now UTF8 upstream
|
||||
|
||||
* Wed Jul 29 2009 Mark McLoughlin <markmc@redhat.com> - 0.7.0-0.5.gitf055724
|
||||
- Move ldconfig call to libvirt-client %post/%postun
|
||||
- Fix rpmlint warning about libvirt-client summary
|
||||
|
||||
Reference in New Issue
Block a user