- 10 11月, 2012 1 次提交
-
-
由 Viktor Mihajlovski 提交于
For S390, the default console target type cannot be of type 'serial'. It is necessary to at least interpret the 'arch' attribute value of the os/type element to produce the correct default type. Therefore we need to extend the signature of defaultConsoleTargetType to account for architecture. As a consequence all the drivers supporting this capability function must be updated. Despite the amount of changed files, the only change in behavior is that for S390 the default console target type will be 'virtio'. N.B.: A more future-proof approach could be to to use hypervisor specific capabilities to determine the best possible console type. For instance one could add an opaque private data pointer to the virCaps structure (in case of QEMU to hold capsCache) which could then be passed to the defaultConsoleTargetType callback to determine the console target type. Seems to be however a bit overengineered for the use case... Signed-off-by: NViktor Mihajlovski <mihajlov@linux.vnet.ibm.com>
-
- 02 11月, 2012 1 次提交
-
-
由 Daniel P. Berrange 提交于
The libvirt coding standard is to use 'function(...args...)' instead of 'function (...args...)'. A non-trivial number of places did not follow this rule and are fixed in this patch. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
- 21 9月, 2012 1 次提交
-
-
由 Eric Blake 提交于
https://www.gnu.org/licenses/gpl-howto.html recommends that the 'If not, see <url>.' phrase be a separate sentence. * tests/securityselinuxhelper.c: Remove doubled line. * tests/securityselinuxtest.c: Likewise. * globally: s/; If/. If/
-
- 14 8月, 2012 1 次提交
-
-
由 Dmitry Guryanov 提交于
openvzOpen fucntion must leave unlocked virDomainObj objects in driver->domains. Now even simple commands like list or domain lookup hang, for example virsh -c openvz:///system list --all. Signed-off-by: NDmitry Guryanov <dguryanov@parallels.com>
-
- 07 8月, 2012 1 次提交
-
-
由 Daniel P. Berrange 提交于
Switch virDomainObjPtr to use the virObject APIs for reference counting. The main change is that virObjectUnref does not return the reference count, merely a bool indicating whether the object still has any refs left. Checking the return value is also not mandatory. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
- 23 7月, 2012 1 次提交
-
-
由 Osier Yang 提交于
Per the FSF address could be changed from time to time, and GNU recommends the following now: (http://www.gnu.org/licenses/gpl-howto.html) You should have received a copy of the GNU General Public License along with Foobar. If not, see <http://www.gnu.org/licenses/>. This patch removes the explicit FSF address, and uses above instead (of course, with inserting 'Lesser' before 'General'). Except a bunch of files for security driver, all others are changed automatically, the copyright for securify files are not complete, that's why to do it manually: src/security/security_selinux.h src/security/security_driver.h src/security/security_selinux.c src/security/security_apparmor.h src/security/security_apparmor.c src/security/security_driver.c
-
- 20 7月, 2012 1 次提交
-
-
由 Daniel P. Berrange 提交于
Update the OpenVZ driver to use virReportError instead of the openvzError custom macro Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
- 19 7月, 2012 1 次提交
-
-
由 Eric Blake 提交于
Noticed during the recent error cleanups. * src/network/bridge_driver.c (networkStartRadvd): Fix spacing. * src/openvz/openvz_conf.c (openvzReadMemConf): Likewise. * src/qemu/qemu_command.c (qemuNetworkIfaceConnect): Likewise. * src/qemu/qemu_hotplug.c (qemuDomainDetachNetDevice): Likewise. * src/qemu/qemu_process.c (qemuProcessStop): Likewise. * src/security/virt-aa-helper.c (vah_add_file): Likewise.
-
- 17 7月, 2012 1 次提交
-
-
由 Stefan Berger 提交于
Introduce new members in the virMacAddr 'class' - virMacAddrSet: set virMacAddr from a virMacAddr - virMacAddrSetRaw: setting virMacAddr from raw 6 byte MAC address buffer - virMacAddrGetRaw: writing virMacAddr into raw 6 byte MAC address buffer - virMacAddrCmp: comparing two virMacAddr - virMacAddrCmpRaw: comparing a virMacAddr with a raw 6 byte MAC address buffer then replace raw MAC addresses by replacing - 'unsigned char *' with virMacAddrPtr - 'unsigned char ... [VIR_MAC_BUFLEN]' with virMacAddr and introduce usage of above functions where necessary.
-
- 11 7月, 2012 2 次提交
-
-
由 Guido Günther 提交于
This makes the driver fail with a clear error message in case of UUID collisions (for example if somebody copied a container configuration without updating the UUID) and also raises an error on other hash map failures. OpenVZ itself doesn't complain about duplicate UUIDs since this parameter is only used by libvirt.
-
由 Eric Blake 提交于
The only useful translation of "%s" as a format string is "%s" (I suppose you could claim "%1$s" is also valid, but why bother). So it is not worth translating; fixing this exposes some instances where we were failing to translate real error messages. This makes the fix of commit 097da1ab more generic, as well as ensuring no future regressions. * cfg.mk (sc_prohibit_useless_translation): New rule. * src/lxc/lxc_driver.c (lxcSetVcpuBWLive): Fix offender. * src/openvz/openvz_conf.c (openvzReadFSConf): Likewise. * src/qemu/qemu_cgroup.c (qemuSetupCgroupForVcpu): Likewise. * src/qemu/qemu_driver.c (qemuSetVcpusBWLive): Likewise. * src/xenapi/xenapi_utils.c (xenapiSessionErrorHandle): Likewise.
-
- 30 6月, 2012 1 次提交
-
-
由 Eric Blake 提交于
Reported by Jason Helfman as a build-breaker on FreeBSD. * src/conf/domain_conf.c (virDomainFSDefParseXML): Use POSIX spelling. * src/openvz/openvz_conf.c (openvzReadFSConf): Likewise.
-
- 28 6月, 2012 1 次提交
-
-
由 Peter Krempa 提交于
The ignore_value macro is used across libvirt. This patch includes it in the internal header and cleans all other includes.
-
- 20 6月, 2012 1 次提交
-
-
由 Guido Günther 提交于
since int is 4 bytes on both i386 and amd64.
-
- 19 6月, 2012 1 次提交
-
-
由 Guido Günther 提交于
The word size there is 64 bit not 8.
-
- 24 5月, 2012 1 次提交
-
-
由 Guido Günther 提交于
-
- 15 5月, 2012 1 次提交
-
-
由 Guido Günther 提交于
to save some syscalls (as suggested by Eric Blake)
-
- 04 5月, 2012 1 次提交
-
-
由 Guido Günther 提交于
-
- 05 4月, 2012 1 次提交
-
-
由 Ilja Livenson 提交于
https://bugzilla.redhat.com/show_bug.cgi?id=809895 Basically, openvz dropped strict version numbering (3.1 vs 3.1.0), which caused parsing to fail.
-
- 28 1月, 2012 1 次提交
-
-
由 Daniel P. Berrange 提交于
Rename virFormatMacAddr, virGenerateMacAddr and virParseMacAddr to virMacAddrFormat, virMacAddrGenerate and virMacAddrParse respectively
-
- 03 11月, 2011 1 次提交
-
-
由 Daniel P. Berrange 提交于
The default console type may vary based on the OS type. ie a Xen paravirt guests wants a 'xen' console, while a fullvirt guests wants a 'serial' console. A plain integer default console type in the capabilities does not suffice. Instead introduce a callback that is passed the OS type. * src/conf/capabilities.h: Use a callback for default console type * src/conf/domain_conf.c, src/conf/domain_conf.h: Use callback for default console type. Add missing LXC/OpenVZ console types. * src/esx/esx_driver.c, src/libxl/libxl_conf.c, src/lxc/lxc_conf.c, src/openvz/openvz_conf.c, src/phyp/phyp_driver.c, src/qemu/qemu_capabilities.c, src/uml/uml_conf.c, src/vbox/vbox_tmpl.c, src/vmware/vmware_conf.c, src/xen/xen_hypervisor.c, src/xenapi/xenapi_driver.c: Set default console type callback
-
- 22 7月, 2011 1 次提交
-
-
由 Eric Blake 提交于
In preparation for a future patch adding new virFile APIs. * src/util/files.h, src/util/files.c: Move... * src/util/virfile.h, src/util/virfile.c: ...here, and rename functions to virFile prefix. Macro names are intentionally left alone. * *.c: All '#include "files.h"' uses changed. * src/Makefile.am (UTIL_SOURCES): Reflect rename. * cfg.mk (exclude_file_name_regexp--sc_prohibit_close): Likewise. * src/libvirt_private.syms: Likewise. * docs/hacking.html.in: Likewise. * HACKING: Regenerate.
-
- 02 7月, 2011 1 次提交
-
-
由 Eric Blake 提交于
To avoid regressions, we let callers specify whether to require a minor and micro version. Callers that were parsing uname() output benefit from defaulting to 0, whereas callers that were parsing version strings from other sources should not change in behavior. * src/util/util.c (virParseVersionString): Allow caller to choose whether to fail if minor or micro is missing. * src/util/util.h (virParseVersionString): Update signature. * src/esx/esx_driver.c (esxGetVersion): Update callers. * src/lxc/lxc_driver.c (lxcVersion): Likewise. * src/openvz/openvz_conf.c (openvzExtractVersionInfo): Likewise. * src/uml/uml_driver.c (umlGetVersion): Likewise. * src/vbox/vbox_MSCOMGlue.c (vboxLookupVersionInRegistry): Likewise. * src/vbox/vbox_tmpl.c (vboxExtractVersion): Likewise. * src/vmware/vmware_conf.c (vmwareExtractVersion): Likewise. * src/xenapi/xenapi_driver.c (xenapiGetVersion): Likewise. Reported by Matthias Bolte.
-
- 01 6月, 2011 3 次提交
-
-
由 Matthias Bolte 提交于
Convert openvzLocateConfFile to a replaceable function pointer to allow testing the config file parsing without rewriting the whole OpenVZ config parsing to a more testable structure.
-
由 Matthias Bolte 提交于
Otherwise virsh dumpxml will report <domain type='qemu'> instead of the expected <domain type='openvz'>.
-
由 Matthias Bolte 提交于
The regression fix in 3aab7f2d altered the error handling. getline returns -1 on failure to read a line (including EOF). The original openvzReadConfigParam function using openvz_readline only treated EOF as not-found. The current getline version treats all getline failures as not-found. This patch fixes this and distinguishes EOF from other getline failures.
-
- 31 5月, 2011 1 次提交
-
-
由 Jean-Baptiste Rouault 提交于
strchrnul() was called on the wrong string so it returned the same result for each iteration.
-
- 27 5月, 2011 3 次提交
-
-
由 Matthias Bolte 提交于
Commit f0443765 replaced openvz_readline with getline and changed EOF-handling in the openvzGetVPSUUID. This patch restores original EOF-handling. Reported by Jean-Baptiste Rouault.
-
由 Matthias Bolte 提交于
This testcase passes before the regression is added in f0443765, fails after that commit and passes again after the regression was fixed.
-
由 Taisuke Yamada 提交于
As reported by Diego Blanco in https://bugzilla.redhat.com/show_bug.cgi?id=702602 commit f0443765 which replaced openvz_readline to getline(3) broke OpenVZ driver as it changed semantics of EOF-handling when parsing OpenVZ configuration. There're several other issues reported with current OpenVZ driver: #1: unclear error message when parsing "CPUS=" line #2: openvz driver goes into crashing loop #3: "NETIF=" line in configuration is not parsed correctly #4: aborts even when optional parameter is missing #5: there's a potential memory leak This updated patch to fix #[145]. This patch does not fix #[23] as I haven't verified these yet, but this at least got me to run OpenVZ on libvirt once again.
-
- 17 5月, 2011 1 次提交
-
-
由 Cole Robinson 提交于
v2: Use virCommand's autocleanup v3: Don't free 'names' on success
-
- 16 5月, 2011 1 次提交
-
-
由 Jiri Denemark 提交于
Only in drivers which use virDomainObj, drivers that query hypervisor for domain status need to be updated separately in case their hypervisor supports this functionality. The reason is also saved into domain state XML so if a domain is not running (i.e., no state XML exists) the reason will be lost by libvirtd restart. I think this is an acceptable limitation.
-
- 13 5月, 2011 1 次提交
-
-
由 Cole Robinson 提交于
Use capabilities to allow a driver to register a default <init> if none is specified in the XML. Openvz was already open-coding this to be /sbin/init LXC currently falls over if no init is specified, so an explicit error is an improvement IMO. (Side note: I don't think we can set a default value for LXC. If we use /sbin/init but the user doesn't specify a separate root FS for their guest, the container will rerun the host's init which can be traumatic :). For virt-install I'm thinking of defaulting to /sbin/init if a root FS has been specified, otherwise require the user to manually specify <init>)
-
- 05 4月, 2011 1 次提交
-
-
由 Matthias Bolte 提交于
Replace openvz_readline with getline in several places to get rid of stack allocated buffers to hold lines. openvzReadConfigParam allocates memory for return values instead of expecting a preexisting buffer.
-
- 25 3月, 2011 1 次提交
-
-
由 Eric Blake 提交于
Add the compiler attribute to ensure we don't introduce any more ref bugs like were just patched in commit 9741f346, then explicitly mark the remaining places in code that are safe. * src/qemu/qemu_monitor.h (qemuMonitorUnref): Mark ATTRIBUTE_RETURN_CHECK. * src/conf/domain_conf.h (virDomainObjUnref): Likewise. * src/conf/domain_conf.c (virDomainObjParseXML) (virDomainLoadStatus): Fix offenders. * src/openvz/openvz_conf.c (openvzLoadDomains): Likewise. * src/vmware/vmware_conf.c (vmwareLoadDomains): Likewise. * src/qemu/qemu_domain.c (qemuDomainObjBeginJob) (qemuDomainObjBeginJobWithDriver) (qemuDomainObjExitRemoteWithDriver): Likewise. * src/qemu/qemu_monitor.c (QEMU_MONITOR_CALLBACK): Likewise. Suggested by Daniel P. Berrange.
-
- 18 2月, 2011 1 次提交
-
-
由 Christophe Fergeau 提交于
Now that the virHash handling functions call virReportOOMError by themselves when needed, users of the virHash API no longer need to do it by themselves. Since users of the virHash API were not consistently calling virReportOOMError after memory failures from the virHash code, this has the added benefit of making OOM reporting from this code more consistent and reliable.
-
- 29 1月, 2011 1 次提交
-
-
由 Matthias Bolte 提交于
Pure cosmetic change.
-
- 08 12月, 2010 2 次提交
-
-
由 Eric Blake 提交于
* src/openvz/openvz_conf.c (openvzLoadDomains): Replace unsafe sscanf with safe direct parsing. (openvzGetVEID): Avoid lost integer overflow detection. (openvzAssignUUIDs): Likewise, and detect readdir failure.
-
由 Eric Blake 提交于
popen must be matched with pclose (not fclose), or it will leak resources. Furthermore, it is a lousy interface when it comes to signal handling. We're much better off using our decent command wrapper. Note that virCommand guarantees that VIR_FREE(outbuf) is both required and safe to call, whether virCommandRun succeeded or failed. * src/openvz/openvz_conf.c (openvzLoadDomains, openvzGetVEID): Replace popen with virCommand usage.
-
- 17 11月, 2010 1 次提交
-
-
由 Stefan Berger 提交于
Similarly to deprecating close(), I am now deprecating fclose() and introduce VIR_FORCE_FCLOSE() and VIR_FCLOSE(). Also, fdopen() is replaced with VIR_FDOPEN(). Most of the files are opened in read-only mode, so usage of VIR_FORCE_CLOSE() seemed appropriate. Others that are opened in write mode already had the fclose()< 0 check and I converted those to VIR_FCLOSE()< 0. I did not find occurrences of possible double-closed files on the way.
-