| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
| |
This implements progress notification messages in the daemon, and
adds a callback in the library to handle them.
No calls are changed so far, so in fact no progress messages can
be generated by this commit.
For more details, see:
https://www.redhat.com/archives/libguestfs/2010-July/msg00003.html
https://www.redhat.com/archives/libguestfs/2010-July/msg00024.html
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
If this string was non-empty, then it broke a lot of things because
autoconf and other parts of the build system were expecting this
string to contain a simple MAJOR.MINOR.RELEASE version number.
This requires changes to guestfish and guestmount so they use the
guestfs_version API to fetch the version from the library. (The
Perl tools were already doing it this way). In a way this is more
accurate, because it's no longer hard-coded in the binary, but
fetched from the dynamically linked libguestfs.so.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
| |
launch() expects guestfsd to start, which it never does in virt-rescue, so it
always returns an error about the appliance shutting down unexpectedly.
|
|
|
|
|
|
|
|
|
|
|
|
| |
When guestfsd exits, or the user exits the virt-rescue shell, the init script
exits which causes the kernel to panic. This isn't really a functional issue, as
all useful work is done by this point. However, it does cause virt-rescue to
display an unsightly error message.
This patch causes the appliance to power off cleanly before the init script
exits. Note it actually does a reboot rather than a poweroff. This is because
ACPI is disabled in the appliance, meaning poweroff doesn't work, but qemu is
configured not to restart on reboot.
|
|
|
|
|
|
|
|
| |
Core files are not reliably written to disk if guestfsd dumps core. This patch
makes libguestfs do the same appliance cleanup for guestfsd and virt-rescue,
which seems to fix the matter.
It also removes a redundant sleep and additional sync when exiting virt-rescue.
|
|
|
|
|
|
| |
This adds a new debug command, core_pattern, which writes a new pattern for
coredump files to the appliance kernel, and sets the daemon's hard and soft core
limits to infinity.
|
| |
|
|
|
|
|
|
|
| |
Two bits of XDR both contained a definition called 'str' which
means that 'xdr_str' was being exported globally twice. Because
of the linker script this didn't affect us. But it's best to
rename this global so that conflicts cannot arise.
|
|
|
|
|
| |
Without this option, qemu will read some defaults from /etc/qemu/
configuration files.
|
| |
|
|
|
|
| |
guestfs_set_network (g, true) enables network support in the appliance.
|
| |
|
|
|
|
| |
Don't print them because no one's listening ...
|
|
|
|
|
|
|
| |
This changes the protocol so that the Linux errno (if available)
is sent back to the library. Note that the errno is not yet
made available to callers, since it is not clear how best to
present this Linux-specific number.
|
|
|
|
|
|
|
|
|
| |
This commit removes one of the protocol limits, by raising the
maximum error message size from 256 bytes to 64K.
Although we could consider raising this further, since the
error messages are currently stored in fixed sized buffers on
the stack, that would require more invasive code changes.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This adds support for virtio-serial, and removes all other
vmchannel methods.
Virtio-serial is faster than other methods, and is now widely
available.
I tested this by using the guestfs_upload API on an 83 MB file:
before: 6.12 seconds (14.1 MB/sec)
after: 4.20 seconds (20.6 MB/sec)
(note this is with the current 8K chunk size)
|
|
|
|
|
|
|
|
|
|
|
|
| |
This changes the method used to build the supermin appliance
to use the new ext2-based appliance supported by latest febootstrap.
The appliance can also be cached, so we avoid rebuilding it
each time it is used.
Mailing list discussion goes into the rationale and details:
https://www.redhat.com/archives/libguestfs/2010-August/msg00028.html
Requires febootstrap >= 2.8.
|
|
|
|
| |
This is just code movement.
|
|
|
|
| |
This is just code movement.
|
| |
|
|
|
|
| |
This haven't been used -- and haven't worked -- for a long time.
|
| |
|
|
|
|
|
| |
Not used by anyone, didn't work well, and replaced now by the
C inspection APIs.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Don't shell out to virt-inspector. Instead, use the new C-based
inspection APIs.
This is much faster.
The new syntax is slightly different:
guestfish -a disk.img -i
guestfish -d guest -i
However, the old syntax still works.
|
|
|
|
|
|
|
|
| |
The -d option lets you specify libvirt domains. The disks from
these domains are found and added, as if you'd named them with -a.
The -c option lets you specify a libvirt URI, which is needed
when we consult libvirt to implement the above.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit converts (some of) the Perl inspection code to C and
makes it available through core APIs. The new APIs are:
inspect-os - Does the inspection, returns list of OSes
inspect-get-* - Get results of the inspection
where '*' is one of:
type - 'windows' or 'linux'
distro - Linux distro
arch - architecture
product-name - long product name string
major-version
minor-version - major.minor version of OS
mountpoints - get a list of the mountpoints
filesystems - get all filesystems associated with the OS
This works for all existing supported Linux and Windows OSes.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
These two calls wrap up the /sbin/findfs command, allowing you
to find a filesystem by only knowing its label or UUID.
This is especially useful when resolving LABEL=... or UUID=...
entries in /etc/fstab.
Sample guestfish session:
><fs> vfs-uuid /dev/vda1
277dd61c-bf34-4253-a8dc-df500a05e7df
><fs> findfs-uuid 277dd61c-bf34-4253-a8dc-df500a05e7df
/dev/vda1
><fs> vfs-label /dev/vda1
/boot
><fs> findfs-label /boot
/dev/vda1
><fs> vfs-uuid /dev/VolGroup00/LogVol00
40ce7c36-82ce-4a12-a99d-48f5e054162c
><fs> findfs-uuid 40ce7c36-82ce-4a12-a99d-48f5e054162c
/dev/mapper/VolGroup00-LogVol00
><fs> findfs-uuid 12345678
libguestfs: error: findfs_uuid: findfs: unable to resolve 'UUID=12345678'
|
|
|
|
|
|
| |
This change simply converts the existing Perl-only function
file_architecture into a core API call. The core API call is
written in C and available in all languages and from guestfish.
|
|
|
|
|
| |
These are already defined in "guestfs-internal.h" which is
included in the .c file.
|
| |
|
|
|
|
|
| |
Trace output sent to stdout can be lost in the event of a crash due to
buffering. This patch sends it to stderr instead.
|
|
|
|
|
| |
See:
http://lists.fedoraproject.org/pipermail/devel/2010-August/141064.html
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This adds a new API, guestfs_is_lv (g, device), which returns true iff
the named device is an LVM2 logical volume.
A sample guestfish session:
><fs> lvs
/dev/vg_f13x64/lv_root
/dev/vg_f13x64/lv_swap
><fs> list-devices
/dev/vda
><fs> list-partitions
/dev/vda1
/dev/vda2
><fs> is-lv /dev/vg_f13x64/lv_root
true
><fs> is-lv /dev/vg_f13x64/lv_swap
true
><fs> is-lv /dev/vda
false
><fs> is-lv /dev/vda1
false
><fs> is-lv /dev/vda2
false
|
|
|
|
|
|
|
| |
This is an update to commit 41f25ab3df5f306ac717fa7a6efd58328d30c1ae.
Internal functions should be named guestfs___* (3 underscores) to
avoid clashing with the implementation of actions (2 underscores).
|
|
|
|
|
|
|
|
|
|
|
|
| |
We split the library code into these separate files:
- guestfs.c: creating handles, closing handles, handle-related variables
- actions.c: generated library-side stubs for each action
- bindtests.c: generated code to test bindings
- launch.c: launching the appliance
- proto.c: the library side of the daemon communications protocol
This is just code movement.
|
|
|
|
|
| |
Rename these two generated files, in preparation for splitting
up the main src/guestfs.c file.
|
| |
|
| |
|
| |
|