| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
| |
(cherry picked from commit 287f8957fea3efe411c7ac55595d5d6c7b613e4e
and modified to apply to the stable branch. Note that the original
commit message contains a typo 'string-e' instead of 'strings-e')
|
|
|
|
|
|
|
|
| |
Move the config state check first in the guestfs_launch function,
so that we don't reset g->launch_t or calculate the temporary
directory in the case where the launch function will immediately
return with an error.
(cherry picked from commit 55e9707f8591488542da48fc89738234b4d85016)
|
|
|
|
| |
(cherry picked from commit fc6dd9daa13ac774156d0822b5aa7830171feb85)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Pengzhen Cao noticed that read-file would fail for files
larger than the protocol size; this is *not* the bug. However
it would also lose protocol synchronization after this.
The reason was that functions which return RBufferOut in the
generator must not 'touch' the *size_r parameter along error
return paths.
I fixed read-file and initrd-cat, and I checked that pread was
doing the right thing.
This also adds regression tests for read-file with various categories
of large file.
(cherry picked from commit 42f59b28f123f53ae038df23a9abee08e959e46b)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Change the network configuration so everything is set using
some macros at the top of src/guestfs.c.
Also, rename the macros used in the daemon so they are not the
same. It was a very long time since these sets of macros had to
match the ones defined in src/guestfs.c, despite what the comment
said.
Note that this commit should not change the semantics of the
program at all.
(cherry picked from commit 8a9f2ca65521d093ac14307aca4370d9497ac840)
|
|
|
|
|
|
| |
Only affects tests when run with LIBGUESTFS_DEBUG=1. Lets you easily
see when each test starts and ends.
(cherry picked from commit 097266e01cfa28319834bf750649650f3c22006f)
|
|
|
|
|
|
| |
(RHBZ#587582).
(cherry picked from commit fd2d10d6ed91f417a9b99bb61526b45bb7ed3e4e)
|
|
|
|
|
| |
This also adds a regression test for this bug.
(cherry picked from commit c24de46d06cc3ecccf00bfaaffb06172659cdd0a)
|
|
|
|
| |
(cherry picked from commit 55641f5d1e9964f8a039005b511b8e688c92cddb)
|
|
|
|
|
|
|
| |
For stable branch:
- cherry picked from commit ce95be8b185ce69
- updated the patch so it doesn't refer to any new guestfish features
in the 1.3 branch
|
|
|
|
|
| |
(Thanks to Yufang Zhang for helping to debug this issue).
(cherry picked from commit 199f218bf431b77c12a728f7072bed1553a0f0af)
|
|
|
|
|
|
|
|
|
| |
See discussion on mailing list:
https://www.redhat.com/archives/libguestfs/2010-April/msg00005.html
https://www.redhat.com/archives/libguestfs/2010-April/msg00057.html
https://www.redhat.com/archives/libguestfs/2010-April/msg00058.html
(cherry picked from commit 54a8f8f30de2f3132da97c54d07ca4639c405de1)
|
|
|
|
| |
(cherry picked from commit c2a8efc548d6f997049cbb3d63bab360b0d946b6)
|
|
|
|
| |
(cherry picked from commit 42e43db927dac13da0afe6dba39708295eb06021)
|
|
|
|
|
|
| |
By convention we use 'g' for handles. Copy this convention
through to all the documentation.
(cherry picked from commit 2e0f3ed54b978925c79ca0d33e76bec338b23631)
|
|
|
|
| |
(cherry picked from commit 6e4bf8e278f5c8bd28eba7152d2f11d1e537ee1b)
|
|
|
|
| |
(cherry picked from commit 4680c732585b2c2d292f521f393215c7943096fa)
|
|
|
|
| |
(cherry picked from commit 68467cb1c2f8b1cc7844ed6512b7f76ef2aba1d1)
|
|
|
|
|
|
|
|
|
|
|
|
| |
chmod: Disallow negative mode, document mode affected by umask.
mkdir-mode: Disallow negative mode, document that filesystems
may interpret the mode in different ways.
mknod: Disallow negative mode, document mode affected by umask.
umask: Check the range of umask mask value carefully.
(cherry picked from commit 61ab83d19009a8006dd73ebe16d22494b78be4d1)
|
|
|
|
| |
(cherry picked from commit 116d497c68c2e57f6e92abf8834112a794a145f0)
|
|
|
|
| |
(cherry picked from commit e64c1e5aacd605ea177972e56ede5be22ae13d4f)
|
|
|
|
|
|
|
|
|
| |
Fix copyright years.
Fix URLs to point to new PRC site.
Make sure guestfish(1) and guestfs(3) manpages reference the
current list of tools.
(cherry picked from commit 9a608a1516bd339dc6d5ebe9952d3bced273c416)
|
|
|
|
|
|
|
|
|
| |
These APIs flesh out further the partitioning API.
Note for stable-1.2 branch:
Cherry picked from b68c030adfdbefe65bc9 and modified
to apply against stable-1.2. We need these new APIs
in order to support bugfixes in virt-resize.
|
|
|
|
| |
(cherry picked from commit 30752ac7ca042f533b8d0c4c6144400a8532b154)
|
|
|
|
|
|
|
| |
Detect if qemu dies during launch by wait(2)-ing for it, and
then getting EOF on the qemu pipe. This was broken in null
vmchannel mode, causing a hang.
(cherry picked from commit e35debd642bea240609775610b68145dab0a634b)
|
|
|
|
|
|
|
| |
Always check that pid > 0 before calling kill (pid, 9). The
issue was that sometimes pid == 0, and this ends up killing
ourselves.
(cherry picked from commit dc5df3bfec706803e75a5f2454293db30e753249)
|
|
|
|
|
|
|
|
|
| |
This warning is currently a fatal error. The code attempts
to retry the accept call, but because we don't reset sock = -1
the retry doesn't happen and it dies anyway.
Set sock = -1 so the retry attempt can happen.
(cherry picked from commit fb4ec82d97f71963ea7f830cb0bc38abefcbac99)
|
|
|
|
|
|
|
|
|
| |
$ guestfish /tmp/disk.img
/tmp/disk.img: unknown command
Did you mean to open a disk image? guestfish -a disk.img
For a list of commands: guestfish -h
For complete documentation: man guestfish
(cherry picked from commit 4c50f4c38d9a50fbf983c79dd208d1b1598fef8a)
|
|
|
|
| |
This is a re-fix for RHBZ#505329.
|
|
|
|
|
| |
We set it on the kernel command line, then get it out from
there when the rescue appliance boots.
|
|
|
|
|
|
| |
Change the appliance so PATH includes common directories. Thus
we don't need to hard-code paths to binaries (eg. "/sbin/fdisk")
everywhere.
|
|
|
|
|
|
|
| |
Previously we used newSVpv (str, len), but if len == 0 then
this means Perl tries to calculate the string length using
strlen(3). This is not desirable when we know the length, in
which case we should use newSVpvn instead.
|
|
|
|
|
|
|
| |
This is similar to 'guestfs_dd', but it copies just a fixed
number of bytes from the source to the destination. It's an
error if the source is too short or if the destination is too
small.
|
| |
|
|
|
|
|
|
|
|
| |
This allows programs to work if they just
#include <guestfs.h>
and no other headers. It's not useful in the general
case, but fixes some configure-time tests, particularly
the one for Ruby on OS X.
|
|
|
|
|
|
|
|
|
| |
As far as I can tell, Darwin has no way to check the peer euid
of a _loopback_ TCP socket. This is required for the "null vmchannel"
implementation to work securely.
Therefore disable this - Darwin will use one of the other supported
vmchannel implementations instead.
|
| |
|
|
|
|
|
| |
OS X has an older version of readline with some differences
in the names of functions.
|
|
|
|
|
|
| |
In PortableXDR this is not included automatically so we
have to include it explicitly to get definitions for the
XDR types.
|
|
|
|
| |
This is required because guestfs-actions.c uses 'memset'.
|
| |
|
|
|
|
|
| |
Really this should be turned into a configure-time test.
Perhaps one exists already?
|
| |
|
| |
|
|
|
|
|
| |
GODI has an odd package layout, so the generator was unable to
find xml-light. Add the GODI directory to the search path.
|
|
|
|
|
| |
On Mac OS X this prevents a short "flash" as qemu opens a
toplevel window.
|
|
|
|
|
|
|
|
|
| |
These calls allow you to query the relationship between
LVM objects, for example, which PVs contain a VG, or which
LVs are contained in a VG.
See the example / test program 'regressions/test-lvm-mapping.pl'
for an example of how to do this from Perl.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Change the add_drive_ro call so it adds the readonly=on option
if qemu supports that.
This just means that qemu will not try to open the drive with
O_RDWR, and should not otherwise change the behaviour of qemu or
libguestfs. (In particular, writes to the read-only drive are
still permitted, and are just discarded when the handle is closed).
However it should alleviate RHBZ#571714 where udev was deciding
to incorrectly relabel a device because we had opened the device
for writing (even though we didn't actually write to it).
|
|
|
|
|
|
|
| |
Reimplement qemu_supports() internal function. Allow it to run
before launch so we can test qemu features. Document that you
should run guestfs_set_qemu as early as possible to make sure
these tests are reliable.
|
| |
|