Displaying 20 results from an estimated 68 matches for "guestfs_tar_out".
2013 Dec 10
1
Error in chunked encoding
Hello,
Oz is a program that does automated installation of virtual
machines. It is written in python and uses libguestfs pretty heavily
to manipulate ISOs and disks.
Someone reported an error against Oz here:
https://github.com/clalancette/oz/issues/140
There are some more details in the issue, but it essentially looks
like something happened during libguestfs tar_out:
RuntimeError:
2014 Jul 15
2
Re: working with mount-local
2014-07-16 1:12 GMT+04:00 Richard W.M. Jones <rjones@redhat.com>:
> I believe I investigates making a squashfs from within libguestfs, and
> although it's possible, it is not possible to stream the output
> (unlike, say, guestfs_tar_out or guestfs_cpio_out). This means that
> the maximum size of the squashfs would be quite small.
>
> Nevertheless we could add an API to do it. (Even better if you can
> find a way to stream mksquashfs).
May be i'm wrong but does it possible to create ability to export
guest file...
2014 Jul 15
2
Re: working with mount-local
2014-07-16 0:58 GMT+04:00 Richard W.M. Jones <rjones@redhat.com>:
> BTW is there any reason to use FUSE instead of using the libguestfs
> API directly? Using the API is going to be much more robust.
I'm need to create squashfs from root file system. I see some methods
like tar and cpio, but i can't find anything suitable for creating
squashfs. Also i can't use root
2017 Feb 15
1
[PATCH v2] copy-out: new optional arguments
...st char *remotepath, const char *localdir,
+ const struct guestfs_copy_out_opts_argv *optargs)
{
struct stat statbuf;
int r;
@@ -170,6 +171,7 @@ guestfs_impl_copy_out (guestfs_h *g,
struct copy_out_child_data data;
char fdbuf[64];
int fd;
+ struct guestfs_tar_out_opts_argv tar_optargs = { .bitmask = 0 };
r = guestfs_is_dir (g, remotepath);
if (r == -1)
@@ -210,7 +212,28 @@ guestfs_impl_copy_out (guestfs_h *g,
snprintf (fdbuf, sizeof fdbuf, "/dev/fd/%d", fd);
- r = guestfs_tar_out (g, remotepath, fdbuf);
+ if (optargs->...
2017 Feb 14
0
[PATCH 06/10] copy-out: new 'excludes' optional argument
...st char *remotepath, const char *localdir,
+ const struct guestfs_copy_out_opts_argv *optargs)
{
struct stat statbuf;
int r;
@@ -170,6 +171,7 @@ guestfs_impl_copy_out (guestfs_h *g,
struct copy_out_child_data data;
char fdbuf[64];
int fd;
+ struct guestfs_tar_out_opts_argv tar_optargs = { .bitmask = 0 };
r = guestfs_is_dir (g, remotepath);
if (r == -1)
@@ -210,7 +212,12 @@ guestfs_impl_copy_out (guestfs_h *g,
snprintf (fdbuf, sizeof fdbuf, "/dev/fd/%d", fd);
- r = guestfs_tar_out (g, remotepath, fdbuf);
+ if (optargs->...
2015 May 26
6
[PATCH 0/6] Update the way that API versions are generated for the man page.
The existing mechanism was clunky, slow and used ~ 10 MB of
local disk.
Rich.
2015 Feb 02
1
Re: [PATCH 5/6] New APIs: copy-in and copy-out
...cmd, "-xf");
> + guestfs___cmd_add_arg (cmd, "-");
> +
> + r = guestfs___cmd_run_async (cmd, NULL, &fd, NULL, NULL);
> + if (r == -1)
> + return -1;
> +
> + snprintf (fdbuf, sizeof fdbuf, "/dev/fd/%d", fd);
> +
> + r = guestfs_tar_out (g, remotepath, fdbuf);
> +
> + if (close (fd) == -1) {
> + perror ("close (tar-output subprocess)");
> + return -1;
> + }
> +
> + r = guestfs___cmd_wait (cmd);
> + if (r == -1)
> + return -1;
> + if (!(WIFEXITED (r) && W...
2012 Mar 08
2
mounting using guestfish
[Please remember to post all questions on the mailing list]
On Thu, Mar 08, 2012 at 09:41:19PM +0700, Tho Huynh wrote:
> Can I mount the guest's file system into a folder/path (mountpoint)
> in the host machine using guestfish?
No, but you don't need to.
> And accessing that folder equal to accessing the guest's file
> system. What I'm trying to do is to copy a file
2012 Jul 23
1
[PATCH V3 1/2] umount: add force umount and lazy umount
...;
- ["umount"; "/"];
+ ["umount"; "/"; "false"; "false"];
["mounts"]], [])
];
shortdesc = "unmount a filesystem";
@@ -3444,12 +3445,12 @@ To download an uncompressed tarball, use C<guestfs_tar_out>." };
proc_nr = Some 73;
tests = [
InitBasicFS, Always, TestLastFail (
- [["umount"; "/"];
+ [["umount"; "/"; "false"; "false"];
["mount_ro"; "/dev/sda1"; "/"];...
2015 Jan 26
6
[PATCH 1/6] cmd: add a way to run (and wait) asynchronously commands
---
src/command.c | 64 +++++++++++++++++++++++++++++++++++++++++++-------
src/guestfs-internal.h | 3 +++
2 files changed, 58 insertions(+), 9 deletions(-)
diff --git a/src/command.c b/src/command.c
index 4bb469b..e26573d 100644
--- a/src/command.c
+++ b/src/command.c
@@ -360,7 +360,7 @@ debug_command (struct command *cmd)
}
static int
-run_command (struct command *cmd)
2015 Jan 26
0
[PATCH 5/6] New APIs: copy-in and copy-out
...quot;tar");
+ guestfs___cmd_add_arg (cmd, "-xf");
+ guestfs___cmd_add_arg (cmd, "-");
+
+ r = guestfs___cmd_run_async (cmd, NULL, &fd, NULL, NULL);
+ if (r == -1)
+ return -1;
+
+ snprintf (fdbuf, sizeof fdbuf, "/dev/fd/%d", fd);
+
+ r = guestfs_tar_out (g, remotepath, fdbuf);
+
+ if (close (fd) == -1) {
+ perror ("close (tar-output subprocess)");
+ return -1;
+ }
+
+ r = guestfs___cmd_wait (cmd);
+ if (r == -1)
+ return -1;
+ if (!(WIFEXITED (r) && WEXITSTATUS (r) == 0))
+ return -1;
+ }
+
+...
2012 Mar 09
1
[PATCH 1/2] Close all file descriptors in the recovery process.
From: "Richard W.M. Jones" <rjones at redhat.com>
If the parent process uses a pipe (or any fd, but pipes are a
particular problem), then the recovery process would hold open the
file descriptor(s) of the pipe, meaning that it could not be fully
closed in the parent. Because the recovery process doesn't use
exec(2), this wasn't avoidable even using FD_CLOEXEC.
Avoid this
2012 Jul 24
3
[PATCH V4 1/3] umount: add force umount and lazy umount
...;
- ["umount"; "/"];
+ ["umount"; "/"; "false"; "false"];
["mounts"]], [])
];
shortdesc = "unmount a filesystem";
@@ -3467,12 +3468,12 @@ To download an uncompressed tarball, use C<guestfs_tar_out>." };
proc_nr = Some 73;
tests = [
InitBasicFS, Always, TestLastFail (
- [["umount"; "/"];
+ [["umount"; "/"; "false"; "false"];
["mount_ro"; "/dev/sda1"; "/"];...
2012 Jul 23
3
[PATCH V2 1/4] mount: add a macro to resolve path or device
Add a macro STRDUP_RESOLVE_DEVICE_OR_PATH to resolve path or device.
Signed-off-by: Wanlong Gao <gaowanlong at cn.fujitsu.com>
---
daemon/daemon.h | 16 ++++++++++++++++
daemon/mount.c | 13 ++-----------
2 files changed, 18 insertions(+), 11 deletions(-)
diff --git a/daemon/daemon.h b/daemon/daemon.h
index 85eec45..f7d0c75 100644
--- a/daemon/daemon.h
+++ b/daemon/daemon.h
@@ -336,6
2015 Feb 02
8
[PATCH 0/7 v2] Make copy_in & copy_out APIs, and use copy_in in customize
Hi,
attached there is the second version of the patch series adding
copy_in and copy_out in the library, mostly moving them from guestfish.
It also adds the copy_in usage in virt-customize, as aid in a new image
building.
Thanks,
Pino Toscano (7):
cmd: add a way to run (and wait) asynchronously commands
cmd: add a child-setup callback
cmd: add the possibility to get a fd to the process
2012 Jul 21
5
[PATCH 1/5] mount: add a macro to resolve path or device
Add a macro DUP_RESOLVE_DEVICE_OR_PATH to resolve path or device.
Signed-off-by: Wanlong Gao <gaowanlong at cn.fujitsu.com>
---
daemon/daemon.h | 18 ++++++++++++++++++
daemon/mount.c | 13 ++-----------
po/POTFILES | 8 ++++++++
3 files changed, 28 insertions(+), 11 deletions(-)
diff --git a/daemon/daemon.h b/daemon/daemon.h
index 85eec45..39cc3f3 100644
--- a/daemon/daemon.h
+++
2016 Jan 06
0
ANNOUNCE: libguestfs 1.32 released
...a
synonym for "off".
It also adds "full", which corresponds to fully allocated, but uses
posix_fallocate(3) for efficiency.
"guestfs_tar_in": new "xattrs", "selinux", "acl" parameters.
"guestfs_tar_out": new "xattrs", "selinux", "acl" parameters.
These extra parameters control whether extended attributes, SELinux
contexts and/or POSIX ACLs are restored from / saved to tarballs.
"guestfs_add_drive"
The existing &...
2017 Feb 14
14
[PATCH 00/10] dib/API: improvements and fixes
Hi,
this patch series does changes mostly in virt-dib, few bug fixes and
a couple of new features (mostly implemented upstream already).
In addition, one new API is added, and a new optional argument for an
existing API is added (the latter is not needed, but could be useful
anyway).
Thanks,
Pino Toscano (10):
dib: fix listing envvars in fake-sudo
dib: source dib "die" script in
2012 Aug 14
7
[PATCH 0/7] Add tar compress, numericowner, excludes flags.
https://bugzilla.redhat.com/show_bug.cgi?id=847880
https://bugzilla.redhat.com/show_bug.cgi?id=847881
This patch series adds various optional arguments to the tar-in and
tar-out commands.
Firstly (1/7) an optional "compress" flag is added to select
compression. This makes the calls tgz-in/tgz-out/txz-in/txz-out
deprecated, and expands the range of compression types available.
2009 Aug 12
23
[PATCH 0/23] factor and const-correctness
This started as a simple warning-elimination change.
I'll get back to that series shortly ;-)
It turned into a factorization and constification exercise
during which I got a taste of ocaml. Thanks to Rich Jones
for help with a few snippets in generator.ml.
The overall result is that many previously-manually-maintained
bits from daemon/*.c functions are now hoisted into the automatically-