- 27 2月, 2013 1 次提交
-
-
由 Eric Blake 提交于
On RHEL 5, I noticed this test failure message: TEST: qemumonitorjsontest libvirt not compiled with yajl, skippingSKIP: qemumonitorjsontest * tests/virstoragetest.c (testPrepImages): Use simpler fputs. * tests/qemumonitorjsontest.c (mymain): Ensure trailing newline.
-
- 26 2月, 2013 10 次提交
-
-
由 Ján Tomko 提交于
VIR_ERR_NO_CONNECT already contains "no connection driver available". This patch changes: no connection driver available for No connection for URI hello to: no connection driver available for hello Bug: https://bugzilla.redhat.com/show_bug.cgi?id=851413
-
由 Paolo Bonzini 提交于
Currently we call virSetDeviceUnprivSGIO with val == 0 if a block device has an sgio attribute. But for sgio='filtered', we know that a kernel with no unpriv_sgio support will always behave as the user wanted. In this case, there is no need to call the function and report a (bogus) error. Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
-
由 Eric Blake 提交于
testutils.c likes to print summaries after a test completes, including if it failed. But if the test outright exit()s, this summary is skipped. Enforce that we return instead of exit. * cfg.mk (sc_prohibit_exit_in_tests): New syntax check. * tests/commandhelper.c (main): Fix offenders. * tests/qemumonitorjsontest.c (mymain): Likewise. * tests/seclabeltest.c (main): Likewise. * tests/securityselinuxlabeltest.c (mymain): Likewise. * tests/securityselinuxtest.c (mymain): Likewise. * tests/testutils.h (VIRT_TEST_MAIN_PRELOAD): Likewise. * tests/testutils.c (virtTestMain): Likewise. (virtTestCaptureProgramOutput): Use symbolic name.
-
由 Eric Blake 提交于
Now that the segfault is solved, we can skip instead of fail the test when yajl is not present. * tests/qemumonitorjsontest.c (mymain): Skip if no yajl.
-
由 Eric Blake 提交于
On a machine without yajl headers, I was seeing random segfaults from qemumonitorjsontest (about 90% of the runs on my particular machine). The segfault was inside virClassIsDerivedFrom, which points to a case of a race leading to unreferencing a stale pointer to an object that had already been freed. I also noticed that if I got the segfault, I was seeing messages such as: 2013-02-22 16:12:37.504+0000: 19833: error : virNetSocketWriteWire:1361 : Cannot write data: Bad file descriptor which is also evidence of deferencing a stale pointer. I traced it to a race where qemuMonitorTestIO could execute late, after the main thread had already called qemuMonitorTestFree and called virNetSocketClose(test->client) but not clearing it out to NULL. Sure enough, after test->client has been closed, fd is -1, which causes an attempt to write to the socket to fail, which in turn triggers the error code of qemuMonitorTestIO that tries to re-close test->client. * tests/qemumonitortestutils.c (qemuMonitorTestIO): Don't attempt to free client again if test already quit.
-
由 Eric Blake 提交于
If virCondInit fails (okay, so that's unlikely), then we end up attempting a virObjectUnlock() on the cleanup path, even though we don't hold a lock. This is not guaranteed to be safe. While at it, I noticed a couple places where we were referencing mon->fd outside locks. * src/qemu/qemu_monitor.c (qemuMonitorOpenInternal): Minimize lock duration. mon->watch doesn't need clean up on error. (qemuMonitorGetBlockExtent, qemuMonitorBlockResize): Don't dereference fd outside of lock.
-
由 Eric Blake 提交于
I built without yajl support, and noticed a strange failure message in qemumonitorjsontest: 2013-02-22 16:12:37.503+0000: 19812: error : virJSONValueToString:1119 : internal error No JSON parser implementation is available 2013-02-22 16:12:37.503+0000: 19812: error : qemuMonitorJSONCommandWithFd:253 : out of memory While a later patch will fix the test to skip when json is not present, this patch avoids overriding the more useful error message from virJSONValueToString returning NULL. * src/qemu/qemu_monitor_json.c (qemuMonitorJSONCommandWithFd): Don't override message. (qemuMonitorJSONCheckError): Don't print NULL. * src/qemu/qemu_agent.c (qemuAgentCommand): Don't override message. (qemuAgentCheckError): Don't print NULL. (qemuAgentArbitraryCommand): Properly fail on OOM.
-
由 Peter Krempa 提交于
-
由 Peter Krempa 提交于
The new TypedParam helper APIs allow to simplify this function significantly. This patch integrates the fix in 75e5bec9 by correctly ordering the setting functions instead of reordering the parameters.
-
由 Doug Goldstein 提交于
The bridge device was showing the vnet devices created for the domains as connected to the bridge. libvirt should only show host devices when trying to get the interface definition rather than the domain devices as well.
-
- 25 2月, 2013 18 次提交
-
-
由 Philipp Hahn 提交于
uid_t and gid_t are opaque types, ranging from s32 to u32 to u64. Explicitly cast the magic -1 to the appropriate type. Signed-off-by: NPhilipp Hahn <hahn@univention.de>
-
由 Philipp Hahn 提交于
uid_t and gid_t are opaque types, ranging from s32 to u32 to u64. Explicitly cast them to unsigned int for printing. Signed-off-by: NPhilipp Hahn <hahn@univention.de>
-
由 Philipp Hahn 提交于
The uid_t|gid_t values are explicitly casted to "unsigned long", but the printf() still used "%d", which is for signed values. Change the format to "%u". Signed-off-by: NPhilipp Hahn <hahn@univention.de>
-
由 Peter Krempa 提交于
Adds XML parsing and qemu commandline tests for the VirtIO RNG device support.
-
由 Peter Krempa 提交于
This patch adds a new capability bit QEMU_CAPS_OBJECT_RNG_EGD and code to support the egd backend for the VirtIO RNG device. The device is added by 3 qemu command line options: -chardev socket,id=charrng0,host=1.2.3.4,port=1234 (communication backend) -object rng-egd,chardev=charrng0,id=rng0 (RNG protocol client) -device virtio-rng-pci,rng=rng0,bus=pci.0,addr=0x4 (the RNG device)
-
由 Peter Krempa 提交于
This patch implements support for the virtio-rng-pci device and the rng-random backend in qemu. Two capabilities bits are added to track support for those: QEMU_CAPS_DEVICE_VIRTIO_RNG - for the device support and QEMU_CAPS_OBJECT_RNG_RANDOM - for the backend support. qemu is invoked with these additional parameters if the device is enabled: -object rng-random,id=rng0,filename=/test/phile (to add the backend) -device virtio-rng-pci,rng=rng0,bus=pci.0,addr=0x4 (to add the device)
-
由 Peter Krempa 提交于
-
由 Peter Krempa 提交于
This patch adds basic configuration support for the RNG device supporting the virtio model with the "random" and "egd" backend types as described in the schema in the previous patch.
-
由 Peter Krempa 提交于
This patch documents XML elements used for (basic) support of virtual RNG devices. In the devices section in the domain XML users may specify: For the default 'random' backend: <devices> <rng model='virtio'> <backend model='random'>/dev/urandom</backend> </rng> </devices> For the slightly more advanced EGD backend: <devices> <rng model='virtio'> <backend model='egd' type='udp'> <!-- this is a definition of a character device --> <source mode='bind' service='1234'/> <source mode='connect' host='1.2.3.4' service='1234'/> <!-- or other valid character device configuration --> </backend> </rng> </devices> For the planned random daemon/pool: <devices> <rng model='virtio'> <backend model='pool' pool='poolname'>class</backend> </rng> </devices> to enable the RNG device for guests.
-
由 Peter Krempa 提交于
This patch adds a fake switch statement to force the compiler to warn after a new device type was added. This should remind the contributor to add the new device also to this iterator function.
-
由 Gene Czarcinski 提交于
Originally, only a host name was used to associate a DHCPv6 request with a specific IPv6 address. Further testing demonstrates that this is an unreliable method and, instead, a client-id or DUID needs to be used. According to DHCPv6 standards, this id can be a duid-LLT, duid-LL, or duid-UUID even though dnsmasq will accept almost any text string. Although validity checking of a specified string makes sure it is hexadecimal notation with bytes separated by colons, there is no rigorous check to make sure it meets the standard. Documentation and schemas have been updated. Signed-off-by: NGene Czarcinski <gene@czarc.net> Signed-off-by: NLaine Stump <laine@laine.org>
-
由 Gene Czarcinski 提交于
Although in IPv4 one must pick either mac or name, either can be omitted. Similarly, for IPv6, the name can be optionally omitted. Signed-off-by: NGene Czarcinski <gene@czarc.net> Signed-off-by: NLaine Stump <laine@laine.org>
-
由 Laine Stump 提交于
-
由 Ján Tomko 提交于
For really old qemu-img binaries which do not support specifying the format of the backing file, display a DEBUG message instead of INFO that this can't be done.
-
由 Ján Tomko 提交于
Modify the expected output of storagevolxml2argv tests as well.
-
由 Ján Tomko 提交于
-
由 Ján Tomko 提交于
This allows us to create a test for the generated command line.
-
由 Ján Tomko 提交于
-
- 24 2月, 2013 1 次提交
-
-
由 Eric Blake 提交于
It makes no sense to prohibit reuse of the wrapper in other LGPL projects, since most of libvirt is designed to be LGPL. Of course, when using the wrapper to wrap a GPL program, the combined result is still effectively GPL, but that shouldn't force us to license the wrapper as GPL in isolation. * run.in: Relicense to LGPLv2+.
-
- 23 2月, 2013 10 次提交
-
-
由 Michal Privoznik 提交于
If a migration fails, we need to stop all block jobs running so qemu doesn't try to send data to destination over and over again.
-
由 Michal Privoznik 提交于
At the end of migration, it is important to stop NBD server and thus release all allocated resources.
-
由 Michal Privoznik 提交于
This function does the source part of NBD magic. It invokes drive-mirror on each non shared and RW disk with a source and wait till the mirroring process completes. When it does we can proceed with migration. Currently, an active waiting is done: every 500ms libvirt asks qemu if block-job is finished or not. However, once the job finishes, qemu doesn't report its progress so we can only assume if the job finished successfully or not. The better solution would be to listen to the event which is sent as soon as the job finishes. The event does contain the result of job.
-
由 Michal Privoznik 提交于
We need to start NBD server and feed it with all non-<shared/>, RW and source-full disks. Moreover, with new virPortAllocator we must ensure the borrowed port for NBD server will be returned if either migration completes or qemu process is torn down.
-
由 Michal Privoznik 提交于
This will be used after all migration work is done to stop NBD server running on destination. It doesn't take any arguments, just issues a command.
-
由 Michal Privoznik 提交于
This will be used with new migration scheme. This patch creates basically just monitor stub functions. Wiring them into something useful is done in later patches.
-
由 Michal Privoznik 提交于
This will be used with new migration scheme. This patch creates basically just monitor stub functions. Wiring them into something useful is done in later patches.
-
由 Michal Privoznik 提交于
This migration cookie is meant for two purposes. The first is to be sent in begin phase from source to destination to let it know we support new implementation of VIR_MIGRATE_NON_SHARED_{DISK,INC} so destination can start NBD server. Then, the second purpose is, destination can let us know, on which port the NBD server is running.
-
由 Michal Privoznik 提交于
This just keeps track whether qemu knows nbd-server-* commands so we can use it during migration or not.
-
由 Pieter Hollants 提交于
This patch adds support for a new <option>-Tag in the <dhcp> block of network configs, based on a subset of the fifth proposal by Laine Stump in the mailing list discussion at https://www.redhat.com/archives/libvir-list/2012-November/msg01054.html. Any such defined option will result in a dhcp-option=<number>,"<value>" statement in the generated dnsmasq configuration file. Currently, DHCP options can be specified by number only and there is no whitelisting or blacklisting of option numbers, which should probably be added. Signed-off-by: NPieter Hollants <pieter@hollants.com> Signed-off-by: NLaine Stump <laine@laine.org>
-