| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
| |
This implements set_event_callback and delete_event_callback so that
Python programs can use the new event mechanism.
|
|
|
|
|
|
|
| |
Move the hand-written functions into two new files:
guestfs-py.h and guestfs-py-byhand.c
This is just code motion.
|
|
|
|
| |
This updates commit bc468c87d04b34faacd208c49cca4a5096e5103c.
|
|
|
|
|
| |
The virt-v2v transfer ISO had a /windows directory. The core
inspection code thought this was a Windows root filesystem.
|
|
|
|
|
| |
virt-inspector would exit silently if list-applications failed along
this error path.
|
|
|
|
| |
Previously we returned "rhel" for these, which was not accurate.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Release the Python global interpreter lock while running libguestfs
calls.
We don't release it around guestfs_create() because that is a short
call that just allocates memory. We do release it around
guestfs_close() since that is a potentially long-running (it can call
wait(2) amongst other things). We also release it around all the
other generated Python calls.
We don't yet support callbacks into Python code (ie. the new event
API). But when we do in future, we will need to also handle the GIL
around those callbacks.
This code is adapted from libvirt's python/typewrappers.h. Thanks to
Dan Berrange for showing us how to do this properly.
|
| |
|
| |
|
| |
|
|
|
|
| |
Also use 'exec' to run the program.
|
| |
|
|
|
|
| |
This updates commit d95874db3dc6c415061b86275d03770b4f28ffbb.
|
|
|
|
|
|
|
|
|
|
|
| |
Remove the hack that let you run ./fish/guestfish or
./fuse/guestmount. You now have to do:
./run ./fish/guestfish
or
./run ./fuse/guestmount
to run these programs without installing.
|
|
|
|
|
| |
Remove all the run*locally scripts and replace with a single top level
./run shell script.
|
| |
|
|
|
|
|
|
|
|
| |
It turns out that db_load incrementally updates the database (instead
of writing a new one). Remove the old database to force db_load to
write a new one.
This also ensures that we handle write failure gracefully.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
This commit downloads the Packages RPM database allowing us to find
other details about installed RPM packages (via
inspect-list-applications). This adds version and release. Epoch
cannot yet be found.
This commit also updates the Fedora example image so that it contains
a dummy RPM Packages database with some data.
|
|
|
|
|
|
|
|
|
|
|
| |
There are two changes here:
(1) The code for listing RPM applications ran db_dump and parsed the
output. We abstract out that parsing code into a separate reusable
module (src/dbdump.c).
(2) The old db_dump parsing code used db_dump -p (printable) format.
Instead use db_dump -k (hex) format so we can read binary fields.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The src/inspect.c file had grown rather large -- 3,500 lines. Split
it across several files according to function.
This is just moving code.
After the split the files are more evenly divided:
536 src/inspect_apps.c
766 src/inspect.c
537 src/inspect_fs.c
404 src/inspect_fs_cd.c
785 src/inspect_fs_unix.c
535 src/inspect_fs_windows.c
3563 total
|
|
|
|
| |
This is just moving code around.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
During inspection we download various files such as the Windows
'software' and 'system' registries. Previously these were downloaded
as temporary files and discarded immediately after use. This meant
that the 'software' registry was being downloaded twice by
virt-inspector (it's required once for basic OS inspection, and a
second time to list Windows applications).
This commit changes this so that these files are cached in g->tmpdir,
and thus the second time we just reuse the file we've already
downloaded.
Callers shouldn't be relying on inspect-list-applications to reread
the actual registry from the VM (unless you close and reopen the
handle). It says in the documentation that the results of inspection
may be cached in the handle.
|
|
|
|
|
|
|
|
| |
In preparation for caching inspection information in the temporary
directory (g->tmpdir), allow the temporary directory to contain
arbitrary files, and remove all of them when the handle is closed.
This just generalizes the previous method of cleaning up the tmpdir.
|
|
|
|
|
|
|
|
|
| |
* df/df.c: As above.
* df/main.c: As above.
* df/output.c: As above.
* fuse/guestmount.c: As above.
* inspector/virt-inspector.c: As above.
* rescue/virt-rescue.c: As above.
|
|
|
|
|
|
| |
* cat/virt-cat.c: Include string.h and libintl.h.
* cat/virt-filesystems.c: Likewise.
* cat/virt-ls.c: Likewise.
|
| |
|
|
|
|
|
|
| |
* fish/config.c: Include string.h, for use of strlen.
* fish/keys.c: Likewise, but for use of memcpy.
* fish/man.c: Likewise, but for use of memset.
|
|
|
|
| |
* src/events.c: Include <string.h>, for use of strlen.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
We can now get drive letter mappings through the inspection API.
|
|
|
|
| |
Found using valgrind.
|
|
|
|
|
|
| |
This allows you to mount disks on (eg) /c and /e and have the
guestfish win:... path mechanism map drive letters to the
right places.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|