- 09 10月, 2012 6 次提交
-
-
由 Eric Blake 提交于
I was using qemu-monitor-command during development, and found it quite hard to use. Compare the results of this patch on ease of reading: $ virsh qemu-monitor-command dom '{"execute":"query-version"}' {"return":{"qemu":{"micro":1,"minor":12,"major":0},"package":"(qemu-kvm-0.12.1.2)"},"id":"libvirt-7683"} $ virsh qemu-monitor-command --pretty dom '{"execute":"query-version"}' { "return": { "qemu": { "micro": 1, "minor": 12, "major": 0 }, "package": "(qemu-kvm-0.12.1.2)" }, "id": "libvirt-7674" } * tools/virsh-host.c (cmdQemuMonitorCommand): New option. * tools/virsh.pod (qemu-monitor-command): Document it.
-
由 Marcelo Cerri 提交于
The functions virGetUserID and virGetGroupID are now able to parse user/group names and IDs in a similar way to coreutils' chown. So, user and group parsing in security_dac can be simplified.
-
由 Marcelo Cerri 提交于
This patch updates virGetUserID and virGetGroupID to be able to parse a user or group name in a similar way to coreutils' chown. This means that a numeric value with a leading plus sign is always parsed as an ID, otherwise the functions try to parse the input first as a user or group name and if this fails they try to parse it as an ID. This patch includes Peter Krempa's changes to correctly handle errors returned by getpwnam_r and getgrnam_r.
-
由 Matthias Bolte 提交于
curl_global_init is not thread-safe. curl_easy_init might call curl_global_init when it was no called before. But curl_easy_init can be called from different threads by the ESX driver. Therefore, call curl_global_init from virInitialize to stop curl_easy_init from calling it. Reported by Benjamin Wang.
-
由 Martin Kletzander 提交于
When both kvmclock and kvm_pv_eoi are configured (either disabled or enabled) libvirt will generate invalid CPU specification due to the fact that even though kvmclock causes the CPU to be specified, it doesn't set have_cpu flag to true (and the new kvm_pv_eoi as well). This patch fixes the issue and adds a test exactly for that to show that it is fixed correctly (and also to keep it that way in the future of course).
-
由 Alexander Larsson 提交于
The variable that is set in the script is with_dbus, not have_dbus.
-
- 08 10月, 2012 2 次提交
-
-
由 Guannan Ren 提交于
libvirt_ulonglongUnwrap requires the integer type of python obj. But libvirt_longlongUnwrap still could handle python obj of Pyfloat_type which causes the float value to be rounded up to an integer. For example >>> dom.setSchedulerParameters({'vcpu_quota': 0.88}) 0 libvirt_longlongUnwrap treats 0.88 as a valid value 0 However >>> dom.setSchedulerParameters({'cpu_shares': 1000.22}) libvirt_ulonglongUnwrap will throw out an error "TypeError: an integer is required" The patch make this consistent.
-
由 Guannan Ren 提交于
libvirt_virDomainGetVcpus: add error handling, return -1 instead of None libvirt_virDomainPinVcpu and libvirt_virDomainPinVcpuFlags: check the type of argument make use of libvirt_boolUnwrap Set bitmap according to these values which are contained in given argument of vcpu tuple and turn off these bit corresponding to missing vcpus in argument tuple The original way ignored the error info from PyTuple_GetItem if index is out of range. "IndexError: tuple index out of range" The error message will only be raised on next command in interactive mode.
-
- 07 10月, 2012 1 次提交
-
-
由 Matthias Bolte 提交于
libcurl uses a SIGALRM in combination with sigsetjmp/siglongjmp to be able to abort a DNS lookup when it takes too long. The problem with this in a multi-threaded application is that the signal handler for SIGALRM and the call to siglongjmp can be executed on a thread that is different from the one that initially did the SIGALRM setup and the call to sigsetjmp. In the reported case this triggered a segfault. Disable libcurl's use of signals to avoid this situation. This has the disadvantage of losing the ability to abort synchronous DNS lookups which might result in libcurl getting stuck in a DNS lookup in the worst case. When libcurl was build with an asynchronous DNS backend such as c-ares then there is no problem because the timeout mechanism works without signals here anyway. Reported by Benjamin Wang.
-
- 05 10月, 2012 6 次提交
-
-
由 Viktor Mihajlovski 提交于
The output buffer for virFileReadAll was too small for systems with more than 30 CPUs which leads to a log entry and incorrect behavior. The new size will be sufficient for the current architectural limits. Signed-off-by: NViktor Mihajlovski <mihajlov@linux.vnet.ibm.com>
-
由 Eric Blake 提交于
This reverts part of commit 5468594f; the perl changes in that patch were sufficient. Since libvirt.syms is already a generated file created in part from libvirt_private.syms, we don't need a second pass over libvirt_private.syms in isolation. * src/Makefile.am: Undo addition of check-private-symfile.
-
由 Michal Privoznik 提交于
Currently, we are checking if libvirt.so contains public symbols. However, sometimes we rename an internal symbol and forget to change libvirt_private.syms accordingly. Hence, it's safer to check for internal symbols as well.
-
由 Eric Blake 提交于
I noticed that in two places, we require util-linux, and in a third, we require util-linux-ng. On Fedora (I tested F15 through rawhide), util-linux-ng is obsoleted by util-linux; on RHEL 6, util-linux is obsoleted by util-linux-ng. That is, on either platform, either name will get you the correct package installed (where the preferred name on fedora is util-linux, and on RHEL 6 is util-linux-ng). But on RHEL 5, there is no util-linux-ng * libvirt.spec.in (Requires): Use util-linux, not util-linux-ng.
-
由 Michal Privoznik 提交于
After it got renamed to virProcessKill (cf470068) it is no longer needed in the private syms file.
-
由 Eric Blake 提交于
Use of the wrong attribute name caused the table of contents to be useless. Fix suggested by Daniel P. Berrange. * docs/migration.html.in: Use correct anchoring attribute.
-
- 04 10月, 2012 4 次提交
-
-
由 Wido den Hollander 提交于
Getting a artifact into Maven central has a lot of restrictions as where the artifact should be hosted. This seemed like a big hassle which we don't want to go through now. Document a way for users to use libvirt.org as a repository so they can fetch the Java bindings with maven. Signed-off-by: NWido den Hollander <wido@widodh.nl>
-
由 Kyle Mestery 提交于
Correct the check for the return value of virStrcpyStatic() when copying port-profile names. Fixes Open vSwitch ports which utilize port-profiles from network definitions. Signed-off-by: NKyle Mestery <kmestery@cisco.com>
-
由 Eric Blake 提交于
Based on a report that phyp is undocumented: https://www.redhat.com/archives/libvirt-users/2012-July/msg00013.html * docs/drvphyp.html.in (phyp): New file. * docs/drivers.html.in: List it.
-
由 Eric Blake 提交于
Several gnulib tests were failing 'make check', and compilation with CFLAGS=-g failed due to a gcc 4.2.1 limitation. * .gnulib: Update to latest, for gcc 4.2 support and fixed FreeBSD tests.
-
- 03 10月, 2012 2 次提交
-
-
由 Marcelo Cerri 提交于
This patch adds a brief description about labels for each security driver.
-
由 Marcelo Cerri 提交于
The DAC driver is missing parsing of group and user names for DAC labels and currently just parses uid and gid. This patch extends it to support names, so the following security label definition is now valid: <seclabel type='static' model='dac' relabel='yes'> <label>qemu:qemu</label> <imagelabel>qemu:qemu</imagelabel> </seclabel> When it tries to parse an owner or a group, it first tries to resolve it as a name, if it fails or it's an invalid user/group name then it tries to parse it as an UID or GID. A leading '+' can also be used for both owner and group to force it to be parsed as IDs, so the following example is also valid: <seclabel type='static' model='dac' relabel='yes'> <label>+101:+101</label> <imagelabel>+101:+101</imagelabel> </seclabel> This ensures that UID 101 and GUI 101 will be used instead of an user or group named "101".
-
- 02 10月, 2012 8 次提交
-
-
由 Eric Blake 提交于
Commit c579d6b3 added a sledgehammer to silence spurious warnings from gcc 4.2, but in the process, it also silenced useful warnings from gcc 4.3 through 4.5. As a result, a bug slipped in to commit 0caccb58. Tested with FreeBSD (gcc 4.2.1), RHEL 6.3 (gcc 4.4), and F17 (gcc 4.7.2), where the former didn't trip on spurious warnings, and where the latter two detected a revert of 2b804cfa. * m4/virt-compile-warnings.m4 (-Wno-format): Probe for the actual spurious message, to once again allow gcc 4.4 to use -Wformat.
-
由 Eric Blake 提交于
Introduced in commit 0caccb58. CC libvirt_driver_qemu_impl_la-qemu_capabilities.lo ../../src/qemu/qemu_capabilities.c: In function 'qemuCapsInitQMP': ../../src/qemu/qemu_capabilities.c:2327:13: error: format '%d' expects argument of type 'int', but argument 8 has type 'const char *' [-Werror=format] * src/qemu/qemu_capabilities.c (qemuCapsInitQMP): Use correct format.
-
由 Jiri Denemark 提交于
Since libvirt switched to QMP capabilities probing recently, it starts QEMU process used for this probing with -daemonize, which means virCommandAbort can no longer reach these processes. As a result of that, restarting libvirtd will leave several new QEMU processes behind. Let's use QEMU's -pidfile and use it to kill the process when QMP caps probing is done.
-
由 Peter Krempa 提交于
When doing snapshots, the filesystem freeze function used the agent entering function that expects the qemud_driver unlocked. This might cause a deadlock of the qemu driver if the agent does not respond. The only call path of this function has the qemud_driver locked, so this patch changes the entering functions to those expecting the driver locked.
-
由 Michal Privoznik 提交于
There was an inverted return value in lxcCgroupControllerActive(). The function assumes cgroups are active and do couple of checks to prove that. If any of them fails, false is returned. Therefore, at the end, after all checks are done we must return true, not false.
-
由 Eric Blake 提交于
Commit f6430390 broke builds on RHEL 5, where glibc (2.5) is too old to support mkostemp (2.7) or htole64 (2.9). While gnulib has mkostemp, it still lacks htole64; and it's not worth dragging in replacements on systems where journald is unlikely to exist in the first place, so we just use an extra configure-time check as our witness of whether to attempt compiling the code. * src/util/logging.c (virLogParseOutputs): Don't attempt to compile journald on older glibc. * configure.ac (AC_CHECK_DECLS): Check for htole64.
-
由 Eric Blake 提交于
Commit f1a43a8e missed one side of an #if/#else. * src/util/processinfo.c (virProcessInfoGetAffinity): Use correct bitmap operation.
-
由 Dave Allan 提交于
Clarify that domains with numeric names can only be identified by their domain id.
-
- 01 10月, 2012 1 次提交
-
-
由 Eric Blake 提交于
Several people have reported that if the .gnulib submodule is dirty, then 'make' will go into an infinite loop attempting to rerun bootstrap, because that never cleans up the dirty submodule. By default, we should halt and make the user investigate, but if the user doesn't know why or care that the submodule is dirty, I also added the ability to 'make CLEAN_SUBMODULE=1' to get things going again. Also, while testing this, I noticed that when a submodule update was needed, 'make' would first run autoreconf, then bootstrap (which reruns autoreconf); adding a strategic dependency allows for less work. * .gnulib: Update to latest, for maint.mk improvements. * cfg.mk (_autogen): Also hook maint.mk, to run before autoreconf. * autogen.sh (bootstrap): Refuse to run if gnulib is dirty, unless user requests discarding gnulib changes.
-
- 30 9月, 2012 2 次提交
-
-
由 Matthias Bolte 提交于
Use MATCH for all flags checks. hypervMsvmComputerSystemToDomain expects the domain pointer to the initialized to NULL. All items in doms up to the count-th one are valid, no need to double check before freeing them.
-
由 Matthias Bolte 提交于
Avoid requesting information such as identity or power state when it is not necessary. Lookup virtual machine list with the required fields (configStatus, name, and config.uuid) to make esxVI_GetVirtualMachineIdentity work. No need to call esxVI_GetNumberOfSnapshotTrees. rootSnapshotTreeList can be tested for emptiness by checking it for NULL. esxVI_LookupRootSnapshotTreeList already does the error reporting, don't overwrite it. Check if autostart is enabled at all before looking up the individual autostart setting of a virtual machine. Reorder VIR_EXPAND_N(doms, ndoms, 1) to avoid leaking the result of the call to virGetDomain if VIR_EXPAND_N fails. Replace VIR_EXPAND_N by VIR_RESIZE_N to avoid quadratic scaling, as in the Hyper-V version of the function. If virGetDomain fails it already reports an error, don't overwrite it with an OOM error. All items in doms up to the count-th one are valid, no need to double check before freeing them. Finally, don't leak autoStartDefaults and powerInfoList.
-
- 29 9月, 2012 1 次提交
-
-
由 Daniel J Walsh 提交于
Currently if you build on a machine that does not support SELinux we end up with the default mount point being /selinux, since this is moved to /sys/fs/selinux, we should start defaulting there. I believe this is causing a bug in libvirt-lxc when /selinux does not exists, even though /sys/fs/selinux exists.
-
- 28 9月, 2012 7 次提交
-
-
由 Daniel P. Berrange 提交于
Start a QEMU process using $QEMU -S -no-user-config -nodefaults \ -nographic -M none -qmp unix:/some/path,server,nowait and talk QMP over stdio to discover what capabilities the binary supports. This works for QEMU 1.2.0 or later and for older QEMU automatically fallback to the old approach of parsing -help and related command line args. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
由 Daniel P. Berrange 提交于
Some architectures provide the query-cpu-definitions command, but are set to always return a "GenericError" from it :-( Catch this & treat it as if there was an empty list of CPUs returned Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
由 Daniel P. Berrange 提交于
After calling qemuMonitorClose(), it is still possible for the QEMU monitor I/O event callback to get invoked. This will trigger an error message because mon->fd has been set to -1 at this point. Silently ignore the case where mon->fd is -1, likewise for mon->watch being zero. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
由 Daniel P. Berrange 提交于
The qemuMonitorOpen method only needs a virDomainObjPtr in order to access the QEMU pid. This is not critical when detecting the QEMU capabilties, so can easily be skipped Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
由 Daniel P. Berrange 提交于
The help output for QEMU 1.2.0 changed 'pci-assign' to 'kvm-pci-assign'. Since the new capabilities code does exact device name matching instead of substring matching, this caused the capabilities to go missing. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
由 Chuck Short 提交于
Minimal CPU "parser" for armhf to avoid compile time warning. Signed-off-by: NChuck Short <chuck.short@canonical.com>
-
由 Daniel P. Berrange 提交于
Probe to see if the systemd journal is accessible, and if so enable logging to the journal by default, rather than stderr (current default under systemd). Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-