Commit Graph

4021 Commits

Author SHA1 Message Date
Richard W.M. Jones
05d4e07918 tests: Add ./run --test option.
This option, when added via
  TESTS_ENVIRONMENT = [...] $(top_builddir)/run --test
allows us to run the tests and only print the full output (including
debugging etc) when the test fails.
2012-06-26 23:34:30 +01:00
Richard W.M. Jones
bbb7d75c91 ./run: Fix indenting for shell script. 2012-06-26 23:00:29 +01:00
Richard W.M. Jones
0977c8408a ocaml: Allow parallel mount-local test to be skipped.
FUSE is not very reliable on RHEL 5.
2012-06-26 18:39:05 +01:00
Richard W.M. Jones
8d88b06277 FAQ: Add Gentoo (thanks Agostino Sarubbo). 2012-06-26 17:46:05 +01:00
Richard W.M. Jones
eb8eb3b9d5 Version 1.19.12. 1.19.12 2012-06-26 15:32:36 +01:00
Richard W.M. Jones
c87956837e launch: Avoid double-close when qemu exits early.
The stdin and stdout of the qemu process are aliased to g->fd:

  g->fd[0] = wfd[1];
  g->fd[1] = rfd[0];

However if the child exits early, then child_cleanup closes g->fd[0],
g->fd[1], AND the code at the cleanup1 label closes wfd[1], rfd[0],
resulting in a double-close.

Avoid this case by setting wfd[1], rfd[0] to -1.  In the cleanup1
label, only close wfd[1], rfd[0] if they are not -1, and add the same
for g->fd[0], g->fd[1].
2012-06-26 14:53:33 +01:00
Richard W.M. Jones
9e221e55b6 launch: Ensure errno from test_qemu_cmd is captured and printed. 2012-06-26 13:38:57 +01:00
Richard W.M. Jones
11317b5d12 launch: Set g->sock = -1 to avoid double-close.
This fixes commit ef5c02c6ee.
2012-06-26 13:31:58 +01:00
Richard W.M. Jones
ef5c02c6ee launch: Log errors from close syscall. 2012-06-26 11:50:12 +01:00
Richard W.M. Jones
90d0beb3c5 tests: Add thread IDs to test of bug 790721. 2012-06-26 09:17:56 +01:00
Richard W.M. Jones
8fc2127975 sysprep: Don't check for /dev/fuse before running the test.
The program doesn't actually require FUSE when used without
any --script options.
2012-06-25 15:21:32 +01:00
Richard W.M. Jones
f27770e141 fish: Allow mount-local test to be skipped with environment variable.
The test uses FUSE, so we need a way to disable it on RHEL 5.
2012-06-25 15:21:32 +01:00
Richard W.M. Jones
2afa0eeb90 tests: Allow SELinux tests to be skipped with an environment variable. 2012-06-25 15:21:32 +01:00
Richard W.M. Jones
030e318049 Version 1.19.11. 1.19.11 2012-06-25 11:29:16 +01:00
Richard W.M. Jones
729bb9c6b5 launch: Treat /dev/null specially, for old KVM.
Old KVM can't add /dev/null readonly.  Treat /dev/null as a special
case.

We also fix a few tests where /dev/null was being used with
format=qcow2.  This was always incorrect behaviour, but qemu appears
to tolerate it.
2012-06-25 11:20:35 +01:00
Richard W.M. Jones
78a515ec4a lib: Remove obsolete NETWORK, ROUTER definitions in header file.
These haven't been used since we switched over to virtio-serial.
2012-06-25 09:02:18 +01:00
Richard W.M. Jones
a0a86484be Version 1.19.10. 1.19.10 2012-06-22 22:06:30 +01:00
Richard W.M. Jones
461455ca7c tests/xml: Fix compilation of test on RHEL 5 with old libvirt.
Old <libvirt.h> had a conflicting definition of virDomainGetXMLDesc:

fake_libvirt_xml.c:36: error: conflicting types for 'virDomainGetXMLDesc'
/usr/include/libvirt/libvirt.h:715: error: previous declaration of 'virDomainGetXMLDesc' was here

The difference is not material ('int' vs. 'unsigned int').

Avoid the error by not including <libvirt.h>.
2012-06-22 13:18:58 +01:00
Richard W.M. Jones
9e7644346d tests: Add workaround for missing O_CLOEXEC. 2012-06-22 13:18:52 +01:00
Richard W.M. Jones
35882ba977 tests: Fix broken workarounds for missing O_CLOEXEC. 2012-06-22 13:18:49 +01:00
Richard W.M. Jones
ef1514aa1e test-virt-resize: Replace truncate with guestfish sparse.
Another instance of 'truncate' command.

See commit 39df80dcc0 for an
explanation.
2012-06-22 13:18:43 +01:00
Richard W.M. Jones
4d3ec25b47 part-get-bootable: Fix when partitions are missing or unordered (RHBZ#602997).
The original fix for this in
commit 511c82df46 was not complete, in
that it did not fix the case of the old (pre '-m' option) parted.
This doesn't matter for Fedora, but it matters for RHEL 5 which has
this ancient parted.
2012-06-22 11:30:00 +01:00
Richard W.M. Jones
8098d062b4 ruby: Add a replacement rb_hash_lookup function for Ruby 1.8.5.
This function was first added to Ruby in 1.8.7.
2012-06-22 11:29:57 +01:00
Richard W.M. Jones
823ba05ebd ruby: Fix libruby test.
If -lruby was not available, this used to define HAVE_LIBRUBY=0.
However this meant that the later test -n "$HAVE_LIBRUBY" would
be successful, whereas it should fail in this case.
2012-06-22 10:58:00 +01:00
Richard W.M. Jones
6cb74d46ba virt-format: Don't call wipefs unless API is available.
This API is optional.  Don't call it unless it's available
in the appliance.
2012-06-22 10:57:55 +01:00
Richard W.M. Jones
145f35badf tests: Add SKIP_TEST_* variables to allow these tests to be skipped.
By setting these variables, we can skip tests that fail on
RHEL 5.
2012-06-22 10:57:47 +01:00
Richard W.M. Jones
6352953ea9 FAQ: Mention update-guestfs-appliance (thanks Steven Dake). 2012-06-19 08:31:45 +01:00
Richard W.M. Jones
489da3ccdf build: Workaround for AC_PROG_SED not existing.
This didn't exist on ancient autoconf in RHEL 5.
2012-06-18 23:00:43 +01:00
Richard W.M. Jones
bc7f1a5ef1 build: Define abs_builddir if not defined already.
This is missing on RHEL 5.

This updates commit 50aa9533e4.
2012-06-18 21:45:13 +01:00
Richard W.M. Jones
baee3f52ef Version 1.19.9. 1.19.9 2012-06-18 16:33:15 +01:00
Richard W.M. Jones
d7c9c6a0d9 fuse: Skip 'truncate' tests if this command is missing. 2012-06-18 15:33:10 +01:00
Richard W.M. Jones
39df80dcc0 tests: Replace truncate command with 'guestfish sparse'.
RHEL 5 didn't have the truncate command, but we can replace:

  truncate -s SIZE FILE

with the roughly equivalent command:

  guestfish sparse FILE SIZE
2012-06-18 15:33:04 +01:00
Richard W.M. Jones
4846b84476 fuse: Add replacement for fuse_opt_add_opt_escaped.
RHEL 5-era FUSE didn't have this function.

I copied the function out of upstream FUSE, since the license is
compatible.
2012-06-18 15:32:52 +01:00
Richard W.M. Jones
50aa9533e4 build: Define builddir and abs_srcdir when they are missing.
RHEL 5-era autoconf did not define these, so define them manually
when they are missing.

Define builddir as '.'  The scripts require this.  It won't work
in the srcdir != builddir case, but we don't care about that for
RHEL 5.

This commit also moves the builddir / abs_srcdir variable setting
above the include of subdir-rules.mk, in case that include uses
these variables.

Useful script:

  for f in $(find -name Makefile.am | xargs fgrep '$(abs_srcdir)' -l) ; do
    if ! grep -q '^abs_srcdir' $f; then
      echo missing in $f
    fi
  done
2012-06-18 15:32:47 +01:00
Richard W.M. Jones
dd216fedbd ocaml: Use OCAMLOPTFLAGS when compiling .cmx (ie. native code) files. 2012-06-18 15:32:38 +01:00
Richard W.M. Jones
87de366701 configure: Look for mkisofs as well as genisoimage.
For our purposes, the two tools are compatible.
2012-06-18 15:32:12 +01:00
Richard W.M. Jones
60a2f8706b Ignore .gdb_history file. 2012-06-14 17:37:11 +01:00
Richard W.M. Jones
7b1cd65c44 ppc64: is_openable function needed on all platforms now.
This fixes commit 295d6af48d.
2012-06-14 17:36:17 +01:00
Richard W.M. Jones
cd6005128d Version 1.19.8. 1.19.8 2012-06-14 16:21:09 +01:00
Richard W.M. Jones
81ee155b9d tests: Add tests for extended attrs and SELinux, direct and via FUSE.
Note that the SELinux + FUSE test is disabled because of:

https://bugzilla.redhat.com/show_bug.cgi?id=811217
https://bugzilla.redhat.com/show_bug.cgi?id=812798#c42
2012-06-14 16:12:57 +01:00
Richard W.M. Jones
abbace6888 virtio-scsi: Increase udev timeout.
In Koji, when you've got 200+ disks, udev times out before all the
udev events have been processed.
2012-06-14 14:22:07 +01:00
Richard W.M. Jones
d43e3d63de virt-edit: Document CVE-2012-2690. 2012-06-14 12:25:06 +01:00
Richard W.M. Jones
199cc2853c Require febootstrap >= 3.17. 2012-06-14 09:57:28 +01:00
Richard W.M. Jones
8b15fb3e22 Version 1.19.7. 1.19.7 2012-06-13 23:25:50 +01:00
Richard W.M. Jones
4c828dc568 tests: Add a test which adds the maximum number of disks and uses them. 2012-06-13 23:17:13 +01:00
Richard W.M. Jones
8735e92a1d virt-df: Use guestfs_max_disks instead of hard-coding limit of 25.
And comprehensively fix it so it works with > 26 disks.
2012-06-13 23:07:26 +01:00
Richard W.M. Jones
a9d7d044f5 New API: device-index.
This returns the index of the device, eg. /dev/sdb => 1.
Or you can think of it as the order that the device was
added, or the index of the device in guestfs_list_devices.
2012-06-13 23:07:26 +01:00
Richard W.M. Jones
46ed232dc2 New API: guestfs_canonical_device_name.
This API makes device names canonical, eg. /dev/vda1 -> /dev/sda1.
2012-06-13 23:07:26 +01:00
Richard W.M. Jones
998ebc333d lvm-filter: Make it work with > 26 devices.
Thanks Alasdair Kergon.
2012-06-13 23:07:26 +01:00
Richard W.M. Jones
c0a087b823 daemon: Fix order of devices in guestfs_list_devices when > 26 disks.
Sort the device names correctly, not just treating them as
strings.  As a result, /dev/sdz < /dev/sdaa.
2012-06-13 22:10:36 +01:00