| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
| |
It always has done. The documentation was wrong.
(cherry picked from commit 70f44cc0ea0bcdd025ed657461e07f6778be44ba)
|
|
|
|
| |
(cherry picked from commit 3cf31c2fe0b356ea5c04117c5235b0a3cfe34971)
|
|
|
|
| |
Cherry picked from commit bad3f4b54a959685f3c0697238fc5753096834fb.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If the blkid command returns 2, that means the value was not found.
Note that this changes the output of the vfs-type API when the
filesystem has no type (eg when it is empty). Previously this would
return an error. Now it returns empty string "".
We did not document this either way. Making it return empty string is
consistent with vfs-label and vfs-uuid.
This change broke list-filesystems, since that code was assuming that
vfs-type could only return a filesystem type or an error.
(cherry picked from commit 168fd4ad5d1e5da93e11388095d41aaa8f804ceb)
|
|
|
|
| |
(cherry picked from commit 8b2e60ce4b46e86da093ee64d4e0b0ae3c998d55)
|
|
|
|
| |
(cherry picked from commit 70daccfe4e9939078436c2830928d8e53432dd84)
|
|
|
|
|
|
|
| |
Not that I'm paranoid about qemu breaking snapshots of anything like
that ...
Cherry picked from commit f3ada2c7653866f2529c9f18aaa99f76cd984844.
|
|
|
|
|
|
| |
Make this error more informative, since it is a common error when the
appliance fails to start up.
(cherry picked from commit 2f73ea343cc4a3433f20e99a7835152767a70f80)
|
|
|
|
|
|
|
|
| |
The virt-v2v transfer ISO had a /windows directory. The core
inspection code thought this was a Windows root filesystem.
Cherry picked and backported from
commit 0da6f55a6745686ca056c6bc8ebf647f111cb8e8.
|
|
|
|
|
|
|
|
| |
virt-inspector would exit silently if list-applications failed along
this error path.
Cherry picked and backported from
commit 782f3a36469ca396dbf998ea82af2699153be3ed.
|
|
|
|
|
|
| |
rpcgen generates source which can't be safely compiled with strict-aliasing
enabled.
(cherry picked from commit 3a84e0784e1e3ab7b56850d0f8c9aa42f1ae3da1)
|
|
|
|
|
|
|
| |
A more accurate description of what this function does.
This is just code motion.
(cherry picked from commit f3eea44f97340f747e46b0df6931a04b53abaf01)
|
|
|
|
|
|
| |
This is just code motion.
Cherry picked from commit 1e6be6afe58de5bfb1ac056b80d3210888edfead.
|
|
|
|
|
|
| |
This should be obvious, and now it is documented to avoid any
confusion.
(cherry picked from commit 05dbe09a5c5be3d5f68dc6eb033c4f642fbac8bf)
|
|
|
|
|
|
| |
No functional change; this simply makes the purpose of the
socket clearer.
(cherry picked from commit 110bfe1fcc9964b82acf7df6d4d60774471f9157)
|
|
|
|
|
| |
Cherry picked from commit d06fee159c14d4fe7654a02bae8849c4f82565f8
and backported to stable-1.8 branch.
|
|
|
|
|
|
|
| |
Add special is_file_nocase and is_dir_nocase functions and
remove the duplicate checks for files and directories with
different cases.
(cherry picked from commit 5776c145d411e5ae00072ecf422055f3d0bd29e2)
|
|
|
|
| |
(cherry picked from commit 1541f3a564f8ff14c1a63298120e4dc618ea3274)
|
|
|
|
| |
(cherry picked from commit cf6f380c544456ee3e84fd41a480ea4cab3d94dd)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In the case where both ends cancel at the same time (eg. both ends
realize there are errors before or during the transfer), previously we
skipped sending back an error from the daemon, on the spurious basis
that the library would not need it (the library is cancelling because
of its own error).
However this is wrong: we should always send back an error message
from the daemon in order to preserve synchronization of the protocol.
A simple test case is:
$ guestfish -N fs -m /dev/sda1 upload nosuchfile /
libguestfs: error: open: nosuchfile: No such file or directory
libguestfs: error: unexpected procedure number (66/282)
(Notice two things: there are errors at both ends, and the
loss of synchronization).
After applying this commit, the loss of synchronization does not occur
and we just see the library error:
$ guestfish -N fs -m /dev/sda1 upload nosuchfile /
libguestfs: error: open: nosuchfile: No such file or directory
The choice of displaying the library or the daemon error is fairly
arbitrary in this case -- it would be valid to display either or even
to combine them into one error. Displaying the library error only
makes the code considerably simpler.
This commit also (re-)enables a test for this case.
Cherry picked and rebased from
commit f4d996fd26762053d68f46de5790aae893f03d38.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is a (potential) fix for the long standing protocol bug
which causes loss of synchronization when a FileIn action
fails very early on the daemon side. The canonical example
would be the 'upload' action failing immediately if no filesystem
is mounted.
What's supposed to happen is this:
(1) library sends
request message (2) daemon processes request
first chunk of data and sees that it will fail,
sends cancellation
(3) discards chunks of data
(4) library sees daemon
cancellation and stops
sending chunks
It was going wrong in step (1), in guestfs___send_to_daemon.
In some (timing related) circumstances, send_to_daemon could
receive the cancellation before sending the first chunk, at
which point it would exit, *discarding the first chunk*.
This causes the daemon to fail in step (3) since it reads the
next request as if it was a chunk, thus losing synchronization.
(The protocol specifies that you always have to send at least
one chunk if there is a FileIn or FileOut parameter).
The patch changes guestfs___send_to_daemon so that if it detects
cancellation, it sends the remaining data in its output buffer
instead of discarding it. (This also fixes another edge case
to do with sending partial data although I don't think we
ever saw that in practice).
(cherry picked from commit c7368ce167d6dbfd3e69ba208301c5af3f17a8a1)
|
|
|
|
|
| |
Signed-off-by: Angus Salkeld <asalkeld@redhat.com>
(cherry picked from commit d1f1f74e5f45fa5b94ebb096fa65fa33ecc23d09)
|
|
|
|
|
| |
Signed-off-by: Angus Salkeld <asalkeld@redhat.com>
(cherry picked from commit 6f7c1a9f9d76bdf9f112e12e1508531fb41abfb2)
|
|
|
|
| |
(cherry picked from commit 003fbdfe5d8b237f42f575199b742c8dde9b8a11)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
/etc/redhat-release on Red Hat Desktop contains the following
string:
Red Hat Desktop release 4 (Nahant Update 8)
Previously we matched against the string "Red Hat Enterprise Linux"
but since this does not contain that string, this distro wasn't being
detected correctly.
Note this also changes the obsolete Perl code, for the benefit of
virt-v2v.
(cherry picked from commit c1a227a960066fb9552e0c225bc473be365b67b0)
|
|
|
|
| |
(cherry picked from commit 2b26c7f721fc8ed2e6f64963289981ac286c02aa)
|
|
|
|
|
| |
This is just code motion.
(cherry picked from commit 99f0d8859fdc8f6c81873d4cdd1c8c780ac25e84)
|
|
|
|
| |
(cherry picked from commit 82f5fdb0dbbc0c7b04861edeadf70c86c9342df2)
|
|
|
|
|
|
|
| |
This also bumps the file size limit for "small text files"
up to 2 MB, since we want to parse Windows CD txtsetup.sif
files that are usually around 500K in size.
(cherry picked from commit 4402e6048fb2a56461f9e4d474fc2f1391248781)
|
|
|
|
| |
(cherry picked from commit 86a53e17de672a79a994b905676b4566da9f072c)
|
|
|
|
| |
(cherry picked from commit 33e9639f2037540a89a9bbaf7212683e8a60fe84)
|
|
|
|
| |
(cherry picked from commit cdc798ac3558e416dc756a0fcefad2af5ca307e0)
|
|
|
|
| |
(cherry picked from commit 22042693cc1e0455a4a503dba93a9fedc9c74f04)
|
|
|
|
| |
(cherry picked from commit 1a9b7df8f2092701fdc5a77a4d9edfcaa1a20acf)
|
| |
|
|
|
|
|
|
| |
Because we didn't match on word boundaries, the previous
code would get confused by similar APIs, eg. getxattr vs getxattrs.
(cherry picked from commit 7ba1b55aa79c56ded770f8ea46716eb054fbfe78)
|
|
|
|
|
|
|
| |
Add a new section called "EXTENDING LIBGUESTFS" to the
guestfs manual page which contains all the information
previously in "HACKING".
(cherry picked from commit d2400da92e5e2cc7fd5e33e61220a33214d5241c)
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
These APIs are essentially required to work around a problem
with ntfs-3g. This filesystem (or FUSE?) does not list all
extended attributes of a file when you call listxattr(2). However
if you know the name of an extended attribute, you can retrieve
it directly using getxattr(2).
The current APIs (getxattrs etc) are simple to use, but they
don't work if we can't list out the extended attributes (ie.
by calling listxattr(2)).
Example using the new APIs on an ntfs-3g filesystem:
><fs> lgetxattr "/Documents and Settings" system.ntfs_attrib | hexdump -C
00000000 16 24 00 00 |.$..|
00000004
><fs> lgetxattr "/Documents and Settings" system.ntfs_reparse_data | hexdump -C
00000000 03 00 00 a0 34 00 00 00 00 00 18 00 1a 00 10 00 |....4...........|
00000010 5c 00 3f 00 3f 00 5c 00 43 00 3a 00 5c 00 55 00 |\.?.?.\.C.:.\.U.|
00000020 73 00 65 00 72 00 73 00 00 00 43 00 3a 00 5c 00 |s.e.r.s...C.:.\.|
00000030 55 00 73 00 65 00 72 00 73 00 00 00 |U.s.e.r.s...|
0000003c
><fs> getxattr "/Documents and Settings" system.ntfs_reparse_data | hexdump -C
libguestfs: error: getxattr: getxattr: No such file or directory
><fs> getxattr "/Documents and Settings" system.ntfs_attrib | hexdump -C
libguestfs: error: getxattr: getxattr: No such file or directory
><fs> lgetxattr "/Documents and Settings" system.ntfs_attrib | hexdump -C
00000000 16 24 00 00 |.$..|
00000004
><fs> getxattr "/Users" system.ntfs_attrib | hexdump -C
00000000 11 00 00 00 |....|
00000004
|
|
|
|
|
| |
This could be used to touch an arbitrary file (albeit one which
must already exist), and this could have been a security problem.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
This change resolves several issues with current appliance
building:
(1) Old appliances are cleaned up.
(2) Race conditions between appliance building is handled better.
(3) Several bugs fixed.
|
|
|
|
| |
(Revealed by compiling under Debian where this is a warning).
|
|
|
|
|
|
|
| |
With the new package building system, it is no longer dangerous to run
'configure', 'make' or 'make check' as root (although it is still not
necessary and not advisable). In any case we don't need to check
this.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
| |
This removes all support for building the ordinary / old
style appliance using febootstrap 2.x, debootstrap, debirf,
fakeroot and fakechroot.
Instead this uses febootstrap 3.x to build the supermin appliance
in a simpler cross-distro manner.
|
|
|
|
| |
This file is not used for building the supermin appliance.
|