Compare commits
56 Commits
libvirt-0_
...
libvirt-0_
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
7e99819dda | ||
|
|
a160d7f98d | ||
|
|
36cab842e8 | ||
|
|
7b7b86e327 | ||
|
|
f4bfe638b6 | ||
|
|
0e9d242f05 | ||
|
|
e24467a8c2 | ||
|
|
b39c370a76 | ||
|
|
62e4e7cde2 | ||
|
|
f822179f97 | ||
|
|
47e7e1e548 | ||
|
|
e73b75314b | ||
|
|
8193a55b4a | ||
|
|
6036708fa2 | ||
|
|
4717aa0b6d | ||
|
|
97ae25ea7d | ||
|
|
6470ed033b | ||
|
|
b550f9c1d5 | ||
|
|
ee0273ffc3 | ||
|
|
50fce74b00 | ||
|
|
e29f71d1c9 | ||
|
|
427ed20801 | ||
|
|
d23e6c285b | ||
|
|
2c139b45d8 | ||
|
|
762435e3b7 | ||
|
|
6383d6b056 | ||
|
|
3712441ea6 | ||
|
|
9d0bc882fa | ||
|
|
90dddf3d3d | ||
|
|
86abd54d02 | ||
|
|
4ab5ad5425 | ||
|
|
f9c1b758c3 | ||
|
|
38cf1bd5ba | ||
|
|
aeda455930 | ||
|
|
288291b795 | ||
|
|
7c2073faca | ||
|
|
5b528ba717 | ||
|
|
4f731a7250 | ||
|
|
f1ac0031f5 | ||
|
|
e45b9c9030 | ||
|
|
3cf75c269d | ||
|
|
585033f372 | ||
|
|
897506e66a | ||
|
|
e4bf8ffa42 | ||
|
|
20367a58a6 | ||
|
|
aa037364ed | ||
|
|
c034c1a3b2 | ||
|
|
da05e02884 | ||
|
|
e1b7b518ac | ||
|
|
581b5f5022 | ||
|
|
c476c8b683 | ||
|
|
b93eafc59f | ||
|
|
2105d62ca8 | ||
|
|
743adffffe | ||
|
|
11e3b51c0d | ||
|
|
66df925739 |
13
.cvsignore
13
.cvsignore
@@ -9,5 +9,14 @@ libvirt-0.6.2.tar.gz
|
||||
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
|
||||
libvirt-0.7.1.tar.gz
|
||||
libvirt-0.7.2.tar.gz
|
||||
libvirt-0.7.3.tar.gz
|
||||
libvirt-0.7.4.tar.gz
|
||||
libvirt-0.7.5.tar.gz
|
||||
libvirt-0.7.6.tar.gz
|
||||
libvirt-0.7.7.tar.gz
|
||||
libvirt-0.8.0.tar.gz
|
||||
libvirt-0.8.1.tar.gz
|
||||
libvirt-0.8.2.tar.gz
|
||||
|
||||
2
Makefile
2
Makefile
@@ -4,7 +4,7 @@ NAME := libvirt
|
||||
SPECFILE = $(firstword $(wildcard *.spec))
|
||||
|
||||
define find-makefile-common
|
||||
for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done
|
||||
for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$d/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done
|
||||
endef
|
||||
|
||||
MAKEFILE_COMMON := $(shell $(find-makefile-common))
|
||||
|
||||
@@ -1,33 +0,0 @@
|
||||
--- src/qemu_conf.c.orig 2009-05-29 19:24:59.000000000 +0200
|
||||
+++ src/qemu_conf.c 2009-05-29 19:19:39.000000000 +0200
|
||||
@@ -792,6 +792,20 @@ int qemudBuildCommandLine(virConnectPtr
|
||||
char uuid[VIR_UUID_STRING_BUFLEN];
|
||||
char domid[50];
|
||||
const char *cpu = NULL;
|
||||
+ int skipSound = 0;
|
||||
+
|
||||
+ if (driver->securityDriver &&
|
||||
+ driver->securityDriver->name &&
|
||||
+ STREQ(driver->securityDriver->name, "selinux") &&
|
||||
+ getuid() == 0) {
|
||||
+ static int soundWarned = 0;
|
||||
+ skipSound = 1;
|
||||
+ if (def->nsounds &&
|
||||
+ !soundWarned) {
|
||||
+ soundWarned = 1;
|
||||
+ VIR_WARN0("Sound cards for VMs are disabled while SELinux security model is active");
|
||||
+ }
|
||||
+ }
|
||||
|
||||
uname_normalize(&ut);
|
||||
|
||||
@@ -1429,7 +1443,8 @@ int qemudBuildCommandLine(virConnectPtr
|
||||
}
|
||||
|
||||
/* Add sound hardware */
|
||||
- if (def->nsounds) {
|
||||
+ if (def->nsounds &&
|
||||
+ !skipSound) {
|
||||
int size = 100;
|
||||
char *modstr;
|
||||
if (VIR_ALLOC_N(modstr, size+1) < 0)
|
||||
@@ -1,71 +0,0 @@
|
||||
From: "Daniel P. Berrange" <berrange@redhat.com>
|
||||
Subject: PATCH: Fix permissions problem starting QEMU
|
||||
|
||||
There is a minor bug when running QEMU non-root, and having
|
||||
capng enabled. libvirt is unable to write the PID file in
|
||||
/var/run/libvirt/qemu, since its now owned by 'qemu', but
|
||||
libvirtd has dropped all capabilties at this point. The fix
|
||||
is to delay dropping capabilities until after the PID file
|
||||
has been created. We should also be sure to kill the child
|
||||
if writing the PID file fails
|
||||
|
||||
* src/util.c: Don't drop capabilities until after the PID file has
|
||||
been written. Kill off child if writing the PID file fails
|
||||
|
||||
* src/qemu_driver.c: Remove bogus trailing '/' in state dir
|
||||
|
||||
diff --git a/src/qemu_driver.c b/src/qemu_driver.c
|
||||
index 9fb8506..26897d3 100644
|
||||
--- a/src/qemu_driver.c
|
||||
+++ b/src/qemu_driver.c
|
||||
@@ -468,7 +468,7 @@ qemudStartup(int privileged) {
|
||||
goto out_of_memory;
|
||||
|
||||
if (virAsprintf(&qemu_driver->stateDir,
|
||||
- "%s/run/libvirt/qemu/", LOCAL_STATE_DIR) == -1)
|
||||
+ "%s/run/libvirt/qemu", LOCAL_STATE_DIR) == -1)
|
||||
goto out_of_memory;
|
||||
} else {
|
||||
uid_t uid = geteuid();
|
||||
diff --git a/src/util.c b/src/util.c
|
||||
index ee64b28..39aae24 100644
|
||||
--- a/src/util.c
|
||||
+++ b/src/util.c
|
||||
@@ -513,12 +513,6 @@ __virExec(virConnectPtr conn,
|
||||
if ((hook)(data) != 0)
|
||||
_exit(1);
|
||||
|
||||
- /* The hook above may need todo something privileged, so
|
||||
- * we delay clearing capabilities until now */
|
||||
- if ((flags & VIR_EXEC_CLEAR_CAPS) &&
|
||||
- virClearCapabilities() < 0)
|
||||
- _exit(1);
|
||||
-
|
||||
/* Daemonize as late as possible, so the parent process can detect
|
||||
* the above errors with wait* */
|
||||
if (flags & VIR_EXEC_DAEMON) {
|
||||
@@ -543,6 +537,9 @@ __virExec(virConnectPtr conn,
|
||||
|
||||
if (pid > 0) {
|
||||
if (pidfile && virFileWritePidPath(pidfile,pid)) {
|
||||
+ kill(pid, SIGTERM);
|
||||
+ usleep(500*1000);
|
||||
+ kill(pid, SIGTERM);
|
||||
virReportSystemError(conn, errno,
|
||||
"%s", _("could not write pidfile"));
|
||||
_exit(1);
|
||||
@@ -551,6 +548,12 @@ __virExec(virConnectPtr conn,
|
||||
}
|
||||
}
|
||||
|
||||
+ /* The steps above may need todo something privileged, so
|
||||
+ * we delay clearing capabilities until the last minute */
|
||||
+ if ((flags & VIR_EXEC_CLEAR_CAPS) &&
|
||||
+ virClearCapabilities() < 0)
|
||||
+ _exit(1);
|
||||
+
|
||||
if (envp)
|
||||
execve(argv[0], (char **) argv, (char**)envp);
|
||||
else
|
||||
|
||||
|
||||
934
libvirt.spec
934
libvirt.spec
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user