| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This optional argument controls how <readonly/> disks in
the libvirt XML are handled. It can be set to one of:
"write" (default) - add them R/W
"read" - add them R/O
"error" - throw an error if asked to add them R/W
"ignore" - ignore these disks
I have added limited regression tests for this feature. However
libvirt's test:/// XML does not allow you to specify that a domain
starts off shut down, so we cannot fully test this. Instead I tested
it by hand.
|
|
|
|
|
|
| |
This changes the private function guestfs___for_each_disk so that the
<readonly/> flag on libvirt disks is detected and passed through to
the callback function.
|
|
|
|
|
|
|
|
|
|
|
| |
The four new APIs:
guestfs_copy_device_to_device,
guestfs_copy_device_to_file,
guestfs_copy_file_to_device, and
guestfs_copy_file_to_file
let you copy from a source to a destination, between files and
devices, optionally allowing source and destination offsets and size
to be specified.
|
|
|
|
|
|
| |
This converts a partition device name (eg. /dev/sda1) to a partition
number (eg. 1). This is useful in conjunction with the parted APIs
that mostly take a disk device + partnum.
|
|
|
|
|
|
|
| |
Also add this option, if necessary, when testing for virtio-serial
support.
When the workaround is enabled, we specify machine type 'pc'.
|
| |
|
|
|
|
| |
This is just code refactoring.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
It is possible for the pcre library to return a variable number of captures for
a single regular expression. e.g.:
^/dev/(cciss/c\d+d\d+)(?:p(\d+))?$
This will return either 1 or 2 captures depending on whether the device has a
partition suffix. The current match wrappers don't allow for this, and require
that a predictable number of matches are returned.
This change updates match, match1, match2, and match3 to ignore the specific
number of matches returned. Instead, any returned captures are assigned to the
given arguments, and any remaining arguments are set to NULL.
|
|
|
|
|
|
|
|
|
|
|
| |
We currently use a heuristic to guess how drive names we find
referenced in the guest map to drive names in the appliance. If this
heuristic fails it can cause inspection to fail.
This change adds a new 'name' option to add_drive_opts, which allows
the user to explicitly pass the name of a drive to libguestfs if it is
known. This change also updates the fstab-parsing inspection code to
use this information if it is available.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is a NFC on its own, but provides a place-holder for drive metadata which
can be used after launch.
Fixes by RWMJ:
- Fix the tests: this requires a new internal function 'debug-drives'
that dumps out the g->drives information so it can be checked in
two of the tests. Previously these tests used 'debug-cmdline'.
- Test file existence / use_cache_off in the add_drive_opts function,
not when launching qemu in the child process.
- Call free along error paths.
- Add comments.
|
|
|
|
|
| |
The regular expression matching disk name assumed that there was only a single
letter suffix. This change handles a naming scheme for any number of disks.
|
| |
|
| |
|
|
|
|
|
|
| |
For now, only detect the tool, but support from reading
installed package could be added later ( may require either
a package of pkgsrc, or a smaller tool to read the db ).
|
|
|
|
|
|
|
|
| |
While testing on Fedora 16, I noticed that Linux will mount the disk
without trouble by using automatically ufstype=old, and yet do not
let us read the directories. So we should start directly with usftype=ufs2,
and if it fail, try 44bsd, as used for netbsd and openbsd ( as seen on
http://wiki-static.aydogan.net/How_to_mount_FFS_partition_under_Linux ).
|
|
|
|
| |
Like Ubuntu one, it may not be always present.
|
|
|
|
| |
This would also erronously detect SLES as Opensuse.
|
|
|
|
|
|
| |
Ths logo is present on Lucid Lynx, but may not always be installed, like
in case of a minimal installation ( or server ). While Edubuntu and Kubuntu
have different logo, I didn't check where it would be placed.
|
| |
|
|
|
|
|
| |
Mainly this is a documentation change. However a sample of
DTrace-compatible userspace probes are also added.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
| |
These calls allow you to change the number of virtual CPUs assigned to
the appliance.
This also adds a --smp option to virt-rescue.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
These APIs let you copy compressed files or devices out from the disk
image.
Compression is useful for large images which are mostly zeroes. We
cannot currently do sparseness detection, and compression gives us a
form of zero detection for free.
Example usage:
$ guestfish --ro -a /dev/vg_pin/F16x64 -i \
compress-out gzip /etc/passwd /tmp/passwd.gz
$ file -z /tmp/passwd.gz
/tmp/passwd.gz: ASCII text (gzip compressed data, was "passwd", from
Unix, last modified: Sun Aug 28 14:40:46 2011)
|
|
|
|
|
|
|
|
|
| |
See:
https://bugzilla.redhat.com/show_bug.cgi?id=502058#c15
https://bugzilla.redhat.com/show_bug.cgi?id=698842#c8
This updates commit 79e66f89e2f6c27486476d7857da58feb491bf5c.
|
| |
|
|
|
|
|
|
|
|
|
| |
Originally this was disabled to work around RHBZ#502058. That bug was
never officially fixed, but it may have fixed itself.
In the meantime, KVM has broken ordinary PIC support (RHBZ#723822).
Since APIC is the most common way that regular Linux and Windows
guests run it makes sense to remove this hack.
|
| |
|
|
|
|
|
|
|
| |
This means "the device that holds /etc/fstab", so map it correctly.
This fixes support for ttylinux and also some other guests that use
/dev/root instead of a real device name.
|
| |
|
| |
|
|
|
|
| |
This event is generated whenever a libguestfs function is called.
|
| |
|
|
|
|
| |
pclose can return > 0 when the status of the command was non-zero.
|
|
|
|
|
| |
Note that errno is probably not set to a useful value here, so there
is not much point recording it.
|
|
|
|
| |
In particular pclose returns a status > 0 if the command fails.
|
| |
|
|
|
|
|
| |
This refactors the code in test_qemu slightly to ensure that
FILE *fp is not leaked on error paths.
|