- 11 7月, 2011 1 次提交
-
-
由 Michal Privoznik 提交于
This patch creates new <bios> element which, at this time has only the attribute useserial='yes|no'. This attribute allow users to use Serial Graphics Adapter and see BIOS messages from the very first moment domain boots up. Therefore, users can choose boot medium, set PXE, etc.
-
- 09 7月, 2011 3 次提交
-
-
由 Matthias Bolte 提交于
Don't print OK/FAIL for tests that decide to be skipped after calling virtTestMain. Delay printing of the indentation before the first test until we know that the test didn't decide to be skipped. Also make the reconnect test use VIRT_TEST_MAIN.
-
由 Matthias Bolte 提交于
The current logic tries to count from 1 to 40 and ignores paddings of 0 and 1 to 40. This doesn't work for counter + 1 mod 40 == 0 like here for counter value 159 TEST: virsh-all ........................................ 40 ........................................ 80 ........................................ 120 ....................................... 159 OK PASS: virsh-all Also seq isn't portable. Therefore, calculate the correct padding length directly and use printf to output it at once.
-
由 Matthias Bolte 提交于
-
- 08 7月, 2011 4 次提交
-
-
由 Michal Privoznik 提交于
This option accepts 3 values: -keep, to keep current client connected (Spice+VNC) -disconnect, to disconnect client (Spice) -fail, to fail setting password if there is a client connected (Spice)
-
由 John Williams 提交于
Add libvirt support for MicroBlaze architecture as a QEMU target. Based on mips/mipsel pattern. Signed-off-by: NJohn Williams <john.williams@petalogix.com>
-
由 Jim Fehlig 提交于
Currently, the xen statstest and reconnect tests are only compiled if xend is running. Compile them unconditionally if xen headers are present, but skip the tests at runtime if xend is not running. This is in response to Eric's suggestion here https://www.redhat.com/archives/libvir-list/2011-July/msg00367.html
-
由 Jim Fehlig 提交于
-
- 05 7月, 2011 1 次提交
-
-
由 Matthias Bolte 提交于
Reported by Ruben Kerkhof.
-
- 02 7月, 2011 3 次提交
-
-
由 Eric Blake 提交于
* tests/utiltest.c (DO_TEST): Fix indentation for cppi.
-
由 Matthias Bolte 提交于
Move non-esx specific tests from esxutilstest there and add a test for virParseVersionString.
-
由 Eric Blake 提交于
According to the automake manual, CPPFLAGS (aka INCLUDES, as spelled in automake 1.9.6) should only include -I, -D, and -U directives; more generic directives like -Wall belong in CFLAGS since they affect more phases of the build process. Therefore, we should be sticking CFLAGS additions into a CFLAGS container, not a CPPFLAGS container. * src/Makefile.am (libvirt_driver_vmware_la_CFLAGS): Use AM_CFLAGS. (INCLUDES): Move CFLAGS items... (AM_CFLAGS): ...to their proper location. * python/Makefile.am (INCLUDES, AM_CFLAGS): Likewise. * tests/Makefile.am (INCLUDES, AM_CFLAGS): Likewise. (commandtest_CFLAGS, commandhelper_CFLAGS) (virnetmessagetest_CFLAGS, virnetsockettest_CFLAGS): Use AM_CFLAGS.
-
- 01 7月, 2011 2 次提交
-
-
由 Daniel P. Berrange 提交于
* tests/Makefile.am: Remove jsondata.h
-
由 Daniel P. Berrange 提交于
While investigating some memory leaks it was unclear whether the JSON code correctly free'd all memory during parsing. Add a test case which can be run under valgrind to clearly demonstrate that the parser is leak free. * tests/Makefile.am: Add 'jsontest' * tests/jsontest.c: A few simple JSON parsing tests
-
- 30 6月, 2011 1 次提交
-
-
由 Osier Yang 提交于
-
- 29 6月, 2011 3 次提交
-
-
由 Osier Yang 提交于
Detected when playing with "make -C tests valgrind".
-
由 Matthias Bolte 提交于
networkSaveDnsmasqHostsfile was added in 8fa9c221 (Apr 2010). It has a force flag. If the dnsmasq hostsfile already exists force needs to be true to overwrite it. networkBuildDnsmasqArgv sets force to false, networkDefine sets it to true. This results in the hostsfile being written only in networkDefine in the common case. If no error occurred networkSaveDnsmasqHostsfile returns true and networkBuildDnsmasqArgv adds the --dhcp-hostsfile to the dnsmasq command line. networkSaveDnsmasqHostsfile was changed in 89ae9849 (24 Jun 2011) to return a new dnsmasqContext instead of reusing one. This change broke the logic of the force flag as now networkSaveDnsmasqHostsfile returns NULL on error, but the early return -- if force was not set and the hostsfile exists -- returns 0. This turned the early return in an error case and networkBuildDnsmasqArgv didn't add the --dhcp-hostsfile option anymore if the hostsfile already exists. It did because networkDefine created the hostsfile already. Then 9d4e2845 fixed the return 0 case in networkSaveDnsmasqHostsfile but didn't apply the force option correctly to the new addnhosts file. Now force doesn't control an early return anymore, but influences the handling of the hostsfile context creation and dnsmasqSave is always called now. This commit also added test cases that reveal several problems. First, the tests now calls functions that try to write the dnsmasq config files to disk. If someone runs this tests as root this might overwrite actively used dnsmasq config files, this is a no-go. Also the tests depend on configure --localstatedir, this needs to be fixed as well, because it makes the tests fail when localstatedir is different from /var. This patch does several things to fix this: 1) Move dnsmasqContext creation and saving out of networkBuildDnsmasqArgv to the caller to separate the command line generation from the config file writing. This makes the command line generation testable without the risk of interfering with system files, because the tests just don't call dnsmasqSave. 2) This refactoring of networkSaveDnsmasqHostsfile makes the force flag useless as the saving happens somewhere else now. This fixes the wrong usage of the force flag in combination with then newly added addnhosts file by removing the force flag. 3) Adapt the wrong test cases to the correct behavior, by adding the missing --dhcp-hostsfile option. Both affected tests contain DHCP host elements but missed the necessary --dhcp-hostsfile option. 4) Rename networkSaveDnsmasqHostsfile to networkBuildDnsmasqHostsfile, because it doesn't save the dnsmasqContext anymore. 5) Move all directory creations in dnsmasq context handling code from the *New functions to dnsmasqSave to avoid directory creations in system paths in the test cases. 6) Now that networkBuildDnsmasqArgv doesn't create the dnsmasqContext anymore the test case can create one with the localstatedir that is expected by the tests instead of the configure --localstatedir given one.
-
由 Laine Stump 提交于
If a domain name is defined for a network, add the --expand-hosts option to the dnsmasq commandline. This results in the domain being added to any hostname that is defined in a dns <host> element and contains no '.' characters (i.e. it is an "unqualified" hostname). Since PTR records are automatically created for any name defined in <host>, the result of a PTR request will change from the unqualified name to the qualified name. This also has the same effect on any hostnames that dnsmasq reads from the host's /etc/hosts file. (In the case of guest hostnames that were learned by dnsmasq via DHCP requests, they were already getting the domain name added on, even without --expand-hosts).
-
- 27 6月, 2011 1 次提交
-
-
由 Matthias Bolte 提交于
Convert networkDnsmasqLeaseFileName to a replaceable function pointer that allow the testsuite to use a version of that function that is not depending on configure --localstatedir. This fixes 5 of 6 test failures, when configure --localstatedir isn't set to /var.
-
- 25 6月, 2011 5 次提交
-
-
由 Eric Blake 提交于
'make syntax-check' regression introduced in commit 60b9c693. * tests/networkxml2argvdata/*.argv: Break long lines.
-
由 Michal Novotny 提交于
This commit introduces names definition for the DNS hosts file using the following syntax: <dns> <host ip="192.168.1.1"> <name>alias1</name> <name>alias2</name> </host> </dns> Some of the improvements and fixes were done by Laine Stump so I'm putting him into the SOB clause again ;-) Signed-off-by: NMichal Novotny <minovotn@redhat.com> Signed-off-by: NLaine Stump <laine@laine.org>
-
由 Michal Novotny 提交于
The regression testing done by comparison of command-line generated from the network XML file and the expected command-line arguments (read from file). Signed-off-by: NMichal Novotny <minovotn@redhat.com>
-
由 Michal Novotny 提交于
This commit introduces the <dns> element and <txt> record for the virtual DNS network. The DNS TXT record can be defined using following syntax in the network XML file: <dns> <txt name="example" value="example value" /> </dns> Also, the Relax-NG scheme has been altered to allow the texts without spaces only for the name element and some nitpicks about memory free'ing have been fixed by Laine so therefore I'm adding Laine to the SOB clause ;-) Signed-off-by: NMichal Novotny <minovotn@redhat.com> Signed-off-by: NLaine Stump <laine@laine.org>
-
由 Matthias Bolte 提交于
getifaddrs can return an IPv6 address, but getaddrinfo can fail for an IPv6 address. Cover this combination.
-
- 24 6月, 2011 4 次提交
-
-
由 Eric Blake 提交于
* src/xenxs/xen_sxpr.c (xenParseSxprPCI): Comment fix. * tests/object-locking.ml (driverTables): Likewise. * tests/testutils.c (virtTestDifferenceBin): Likewise.
-
由 Daniel P. Berrange 提交于
For controlled shutdown we issue a 'system_powerdown' command to the QEMU monitor. This triggers an ACPI event which (most) guest OS wire up to a controlled shutdown. There is no equiv ACPI event to trigger a controlled reboot. This patch attempts to fake a reboot. - In qemuDomainObjPrivatePtr we have a bool fakeReboot flag. - The virDomainReboot method sets this flag and then triggers a normal 'system_powerdown'. - The QEMU process is started with '-no-shutdown' so that the guest CPUs pause when it powers off the guest - When we receive the 'POWEROFF' event from QEMU JSON monitor if fakeReboot is not set we invoke the qemuProcessKill command and shutdown continues normally - If fakeReboot was set, we spawn a background thread which issues 'system_reset' to perform a warm reboot of the guest hardware. Then it issues 'cont' to start the CPUs again * src/qemu/qemu_command.c: Add -no-shutdown flag if we have JSON support * src/qemu/qemu_domain.h: Add 'fakeReboot' flag to qemuDomainObjPrivate struct * src/qemu/qemu_driver.c: Fake reboot using the system_powerdown command if JSON support is available * src/qemu/qemu_monitor.c, src/qemu/qemu_monitor.h, src/qemu/qemu_monitor_json.c, src/qemu/qemu_monitor_json.h, src/qemu/qemu_monitor_text.c, src/qemu/qemu_monitor_text.h: Add binding for system_reset command * src/qemu/qemu_process.c: Reset the guest & start CPUs if fakeReboot is set
-
由 Daniel P. Berrange 提交于
Introduces a simple wrapper around the raw POSIX sockets APIs and name resolution APIs. Allows for easy creation of client and server sockets with correct usage of name resolution APIs for protocol agnostic socket setup. It can listen for UNIX and TCP stream sockets. It can connect to UNIX, TCP streams directly, or indirectly to UNIX sockets via an SSH tunnel or external command * src/Makefile.am: Add to libvirt-net-rpc.la * src/rpc/virnetsocket.c, src/rpc/virnetsocket.h: Generic sockets APIs * tests/Makefile.am: Add socket test * tests/virnetsockettest.c: New test case * tests/testutils.c: Avoid overriding LIBVIRT_DEBUG settings * tests/ssh.c: Dumb helper program for SSH tunnelling tests
-
由 Daniel P. Berrange 提交于
This provides a new struct that contains a buffer for the RPC message header+payload, as well as a decoded copy of the message header. There is an API for applying a XDR encoding & decoding of the message headers and payloads. There are also APIs for maintaining a simple FIFO queue of message instances. Expected usage scenarios are: To send a message msg = virNetMessageNew() ...fill in msg->header fields.. virNetMessageEncodeHeader(msg) ...loook at msg->header fields to determine payload filter virNetMessageEncodePayload(msg, xdrfilter, data) ...send msg->bufferLength worth of data from buffer To receive a message msg = virNetMessageNew() ...read VIR_NET_MESSAGE_LEN_MAX of data into buffer virNetMessageDecodeLength(msg) ...read msg->bufferLength-msg->bufferOffset of data into buffer virNetMessageDecodeHeader(msg) ...look at msg->header fields to determine payload filter virNetMessageDecodePayload(msg, xdrfilter, data) ...run payload processor * src/Makefile.am: Add to libvirt-net-rpc.la * src/rpc/virnetmessage.c, src/rpc/virnetmessage.h: Internal message handling API. * testutils.c, testutils.h: Helper for printing binary differences * virnetmessagetest.c: Validate all XDR encoding/decoding
-
- 22 6月, 2011 1 次提交
-
-
由 Michal Privoznik 提交于
For virtio disks and interfaces, qemu allows users to enable or disable ioeventfd feature. This means, qemu can execute domain code, while another thread waits for I/O event. Basically, in some cases it is win, in some loss. This feature is available via 'ioeventfd' attribute in disk and interface <driver> element. It accepts 'on' and 'off'. Leaving this attribute out defaults to hypervisor decision.
-
- 20 6月, 2011 1 次提交
-
-
由 Osier Yang 提交于
Only add tests for qemuxmlargvtest.c, as there is no qemu command line for numatune XML, just want to make sure the XML could be validated well.
-
- 15 6月, 2011 3 次提交
-
-
由 Jiri Denemark 提交于
Prefer bootindex=N option for -device over the old way -boot ORDER possibly accompanied with boot=on option for -drive. This gives us full control over which device will actually be used for booting guest OS. Moreover, if qemu doesn't support boot=on, this is the only way to boot of certain disks in some configurations (such as virtio disks when used together IDE disks) without transforming domain XML to use per device boot elements.
-
由 Marc-André Lureau 提交于
From a security pov copy and paste between the guest and the client is not always desirable. So we need to be able to enable/disable this. The best place to do this from an administration pov is on the hypervisor, so the qemu cmdline is getting a spice disable-copy-paste option, see bug 693645. Example qemu invocation: qemu -spice port=5932,disable-ticketing,disable-copy-paste https://bugzilla.redhat.com/show_bug.cgi?id=693661
-
由 Guido Günther 提交于
since the testfiles assume a /proc/cpuinfo specific to this architecture. We e.g. can't parse the number of cores on other architectures.
-
- 13 6月, 2011 2 次提交
-
-
由 Wen Congyang 提交于
-
由 Wen Congyang 提交于
qemu supports multi function PCI device at least version 0.13.0.
-
- 02 6月, 2011 5 次提交
-
-
由 Daniel P. Berrange 提交于
A lock manager may operate in various modes. The direct mode of operation is to obtain locks based on the resources associated with devices in the XML. The indirect mode is where the app creating the domain provides explicit leases for each resource that needs to be locked. This XML extension allows for listing resources in the XML <devices> ... <lease> <lockspace>somearea</lockspace> <key>thequickbrownfoxjumpsoverthelazydog</key> <target path='/some/lease/path' offset='23432'/> </lease> ... </devices> The 'lockspace' is a unique identifier for the lockspace which the lease is associated The 'key' is a unique identifier for the resource associated with the lease. The 'target' is the file on disk where the leases are held. * docs/schemas/domain.rng: Add lease schema * src/conf/domain_conf.c, src/conf/domain_conf.h: parsing and formatting for leases * tests/qemuxml2argvdata/qemuxml2argv-lease.args, tests/qemuxml2argvdata/qemuxml2argv-lease.xml, tests/qemuxml2xmltest.c: Test XML handling for leases
-
由 Eric Blake 提交于
Alas, /usr/bin/kvm is also not directly supported by testutilsqemu.c. In fact, _any_ test that uses <cpu match=...> has to use our faked qemu.sh in order to properly answer the 'qemu -cpu ?' probe done during qemu command line building. * tests/qemuxml2argvdata/*graphics-spice-timeout*: Switch emulator, again.
-
由 Jiri Denemark 提交于
-
由 Jiri Denemark 提交于
Commit 2d6adabd replaced qsorting disk and controller devices with inserting them at the right position. That was to fix unnecessary reordering of devices. However, when parsing domain XML devices are just taken in the order in which they appear in the XML since. Use the correct insertion algorithm to honor device target.
-
由 Matthias Bolte 提交于
The test used an emulator that is not supported in testutilsqemu.c. Switch from qemu-kvm to kvm to fix this.
-