search for: str_btrfsimage

Displaying 20 results from an estimated 29 matches for "str_btrfsimage".

2015 Mar 03
0
[PATCH 1/2] New API: btrfs-image
...s.c b/daemon/btrfs.c index d4b3207..be648bc 100644 --- a/daemon/btrfs.c +++ b/daemon/btrfs.c @@ -37,6 +37,7 @@ GUESTFSD_EXT_CMD(str_btrfstune, btrfstune); GUESTFSD_EXT_CMD(str_btrfsck, btrfsck); GUESTFSD_EXT_CMD(str_mkfs_btrfs, mkfs.btrfs); GUESTFSD_EXT_CMD(str_umount, umount); +GUESTFSD_EXT_CMD(str_btrfsimage, btrfs-image); int optgroup_btrfs_available (void) @@ -2005,3 +2006,51 @@ do_btrfstune_enable_skinny_metadata_extent_refs (const char *device) return 0; } + +int +do_btrfs_image (char *const *sources, const char *image, + int compresslevel, int numthreads) +{ + size_t nr_sources = count...
2015 Mar 03
4
[PATCH 0/2] btrfs: add support to btrfs-image
This series adds new APIs to support btrfstune. Chen Hanxiao (2): New API: btrfs-image New API: btrfs_image_restore daemon/btrfs.c | 87 ++++++++++++++++++++++++++++++++++++++++++++++++++++ generator/actions.ml | 45 +++++++++++++++++++++++++++ src/MAX_PROC_NR | 2 +- 3 files changed, 133 insertions(+), 1 deletion(-) -- 2.1.0
2015 Mar 24
1
[PATCH v3] New API: btrfs-image
...s.c b/daemon/btrfs.c index fabb00b..39392f7 100644 --- a/daemon/btrfs.c +++ b/daemon/btrfs.c @@ -37,6 +37,7 @@ GUESTFSD_EXT_CMD(str_btrfstune, btrfstune); GUESTFSD_EXT_CMD(str_btrfsck, btrfsck); GUESTFSD_EXT_CMD(str_mkfs_btrfs, mkfs.btrfs); GUESTFSD_EXT_CMD(str_umount, umount); +GUESTFSD_EXT_CMD(str_btrfsimage, btrfs-image); int optgroup_btrfs_available (void) @@ -2040,3 +2041,45 @@ do_btrfstune_enable_skinny_metadata_extent_refs (const char *device) return 0; } + +int +do_btrfs_image (char *const *sources, const char *image, + int compresslevel) +{ + size_t nr_sources = count_strings (source...
2015 Jun 04
3
[PATCH RFC][Resend] New API: btrfs_convert
...d, 47 insertions(+) diff --git a/daemon/btrfs.c b/daemon/btrfs.c index 39392f7..fd679cf 100644 --- a/daemon/btrfs.c +++ b/daemon/btrfs.c @@ -38,6 +38,7 @@ GUESTFSD_EXT_CMD(str_btrfsck, btrfsck); GUESTFSD_EXT_CMD(str_mkfs_btrfs, mkfs.btrfs); GUESTFSD_EXT_CMD(str_umount, umount); GUESTFSD_EXT_CMD(str_btrfsimage, btrfs-image); +GUESTFSD_EXT_CMD(str_btrfsconvert, btrfs-convert); int optgroup_btrfs_available (void) @@ -2083,3 +2084,31 @@ do_btrfs_image (char *const *sources, const char *image, return 0; } + +int +do_btrfs_convert (const char *device, int rollback) +{ + const size_t MAX_ARGS = 64;...
2015 Mar 17
2
[PATCH v2] New API: btrfs-image
...s.c b/daemon/btrfs.c index d4b3207..340b548 100644 --- a/daemon/btrfs.c +++ b/daemon/btrfs.c @@ -37,6 +37,7 @@ GUESTFSD_EXT_CMD(str_btrfstune, btrfstune); GUESTFSD_EXT_CMD(str_btrfsck, btrfsck); GUESTFSD_EXT_CMD(str_mkfs_btrfs, mkfs.btrfs); GUESTFSD_EXT_CMD(str_umount, umount); +GUESTFSD_EXT_CMD(str_btrfsimage, btrfs-image); int optgroup_btrfs_available (void) @@ -2005,3 +2006,54 @@ do_btrfstune_enable_skinny_metadata_extent_refs (const char *device) return 0; } + +int +do_btrfs_image (char *const *sources, const char *image, + int compresslevel, int numthreads) +{ + size_t nr_sources = count...
2015 May 27
0
[PATCH RFC] New API: btrfs_convert
...d, 47 insertions(+) diff --git a/daemon/btrfs.c b/daemon/btrfs.c index 39392f7..7f10792 100644 --- a/daemon/btrfs.c +++ b/daemon/btrfs.c @@ -38,6 +38,7 @@ GUESTFSD_EXT_CMD(str_btrfsck, btrfsck); GUESTFSD_EXT_CMD(str_mkfs_btrfs, mkfs.btrfs); GUESTFSD_EXT_CMD(str_umount, umount); GUESTFSD_EXT_CMD(str_btrfsimage, btrfs-image); +GUESTFSD_EXT_CMD(str_btrfsconvert, btrfs-convert); int optgroup_btrfs_available (void) @@ -2083,3 +2084,31 @@ do_btrfs_image (char *const *sources, const char *image, return 0; } + +int +do_btrfs_convert (const char *device, int rollback) +{ + const size_t MAX_ARGS = 64;...
2015 Mar 03
0
[PATCH 2/2] New API: btrfs_image_restore
...ARGS = 64 + nr_sources; + const char *argv[MAX_ARGS]; + size_t i = 0, j; + CLEANUP_FREE char *err = NULL; + CLEANUP_FREE char *out = NULL; + int r; + + if (nr_sources == 0) { + reply_with_error ("list of sources must be non-empty"); + return -1; + } + + ADD_ARG (argv, i, str_btrfsimage); + ADD_ARG (argv, i, "-r"); + + if (nr_sources > 1) + ADD_ARG (argv, i, "-m"); + + ADD_ARG (argv, i, image); + + for (j = 0; j < nr_sources; ++j) + ADD_ARG (argv, i, sources[j]); + + ADD_ARG (argv, i, NULL); + + r = commandv (&out, &err, argv); + if (...
2015 Jun 04
0
Re: [PATCH RFC][Resend] New API: btrfs_convert
...aemon/btrfs.c b/daemon/btrfs.c > index 39392f7..fd679cf 100644 > --- a/daemon/btrfs.c > +++ b/daemon/btrfs.c > @@ -38,6 +38,7 @@ GUESTFSD_EXT_CMD(str_btrfsck, btrfsck); > GUESTFSD_EXT_CMD(str_mkfs_btrfs, mkfs.btrfs); > GUESTFSD_EXT_CMD(str_umount, umount); > GUESTFSD_EXT_CMD(str_btrfsimage, btrfs-image); > +GUESTFSD_EXT_CMD(str_btrfsconvert, btrfs-convert); > > int > optgroup_btrfs_available (void) > @@ -2083,3 +2084,31 @@ do_btrfs_image (char *const *sources, const char *image, > > return 0; > } > + > +int > +do_btrfs_convert (const char *d...
2016 Feb 23
3
[PATCH 1/2] lib: Allow the COMPILE_REGEXP macro to be used everywhere.
Since the daemon links to pcre and use regular expressions, and since the COMPILE_REGEXP macro doesn't depend on any aspects of the library-side code (eg. the guestfs_h handle etc), we can allow the daemon to use the COMPILE_REGEXP macro. Move the macro to "guestfs-internal-all.h" to permit this. --- src/guestfs-internal-all.h | 26 ++++++++++++++++++++++++++ src/guestfs-internal.h
2017 Jul 14
0
[PATCH 09/27] daemon: Reimplement ‘mount’, ‘mount_ro’, ‘mount_options’, ‘mount_vfs’ APIs in OCaml.
...+ b/daemon/btrfs.c @@ -37,6 +37,7 @@ GUESTFSD_EXT_CMD(str_btrfs, btrfs); GUESTFSD_EXT_CMD(str_btrfstune, btrfstune); GUESTFSD_EXT_CMD(str_btrfsck, btrfsck); GUESTFSD_EXT_CMD(str_mkfs_btrfs, mkfs.btrfs); +GUESTFSD_EXT_CMD(str_mount, mount); GUESTFSD_EXT_CMD(str_umount, umount); GUESTFSD_EXT_CMD(str_btrfsimage, btrfs-image); @@ -387,6 +388,48 @@ do_btrfs_subvolume_create (const char *dest, const char *qgroupid) return 0; } +static int +mount_vfs_nochroot (const char *options, const char *vfstype, + const mountable_t *mountable, + const char *mp, const char *u...
2015 Jun 05
2
Re: [PATCH RFC][Resend] New API: btrfs_convert
...>> index 39392f7..fd679cf 100644 >> --- a/daemon/btrfs.c >> +++ b/daemon/btrfs.c >> @@ -38,6 +38,7 @@ GUESTFSD_EXT_CMD(str_btrfsck, btrfsck); >> GUESTFSD_EXT_CMD(str_mkfs_btrfs, mkfs.btrfs); >> GUESTFSD_EXT_CMD(str_umount, umount); >> GUESTFSD_EXT_CMD(str_btrfsimage, btrfs-image); >> +GUESTFSD_EXT_CMD(str_btrfsconvert, btrfs-convert); >> >> int >> optgroup_btrfs_available (void) >> @@ -2083,3 +2084,31 @@ do_btrfs_image (char *const *sources, const char *image, >> >> return 0; >> } >> + >> +i...
2017 Jul 21
0
[PATCH v2 15/23] daemon: Reimplement ‘btrfs_subvolume_list’ and ‘btrfs_subvolume_get_default’ in OCaml.
...kid.ml \ + btrfs.ml \ devsparts.ml \ file.ml \ filearch.ml \ diff --git a/daemon/btrfs.c b/daemon/btrfs.c index 4f52b71e8..d9043d53c 100644 --- a/daemon/btrfs.c +++ b/daemon/btrfs.c @@ -41,11 +41,6 @@ GUESTFSD_EXT_CMD(str_mount, mount); GUESTFSD_EXT_CMD(str_umount, umount); GUESTFSD_EXT_CMD(str_btrfsimage, btrfs-image); -COMPILE_REGEXP (re_btrfs_subvolume_list, - "ID\\s+(\\d+).*\\s" - "top level\\s+(\\d+).*\\s" - "path\\s(.*)", - 0) COMPILE_REGEXP (re_btrfs_balance_status, "Balance on '.*' is (....
2017 Jul 14
0
[PATCH 18/27] daemon: Reimplement ‘btrfs_subvolume_list’ and ‘btrfs_subvolume_get_default’ in OCaml.
...kid.ml \ + btrfs.ml \ devsparts.ml \ file.ml \ filearch.ml \ diff --git a/daemon/btrfs.c b/daemon/btrfs.c index 4f52b71e8..d9043d53c 100644 --- a/daemon/btrfs.c +++ b/daemon/btrfs.c @@ -41,11 +41,6 @@ GUESTFSD_EXT_CMD(str_mount, mount); GUESTFSD_EXT_CMD(str_umount, umount); GUESTFSD_EXT_CMD(str_btrfsimage, btrfs-image); -COMPILE_REGEXP (re_btrfs_subvolume_list, - "ID\\s+(\\d+).*\\s" - "top level\\s+(\\d+).*\\s" - "path\\s(.*)", - 0) COMPILE_REGEXP (re_btrfs_balance_status, "Balance on '.*' is (....
2015 Jun 23
10
[PATCH 0/7] Better testing of the guestfsd daemon.
Currently we are unable to properly run guestfsd (the daemon) under valgrind. Attempts to run valgrind inside the appliance have not been successful (see patch 1/7). However we desperately need better valgrind coverage of the daemon, particularly because it is doing a lot of complex parsing of program output. This has been a problem for a long time. A better way to attack this problem is to
2017 Jul 27
0
[PATCH v2] daemon: Remove GUESTFSD_EXT_CMD.
...@ #include "c-ctype.h" #include "ignore-value.h" -GUESTFSD_EXT_CMD(str_btrfs, btrfs); -GUESTFSD_EXT_CMD(str_btrfstune, btrfstune); -GUESTFSD_EXT_CMD(str_btrfsck, btrfsck); -GUESTFSD_EXT_CMD(str_mkfs_btrfs, mkfs.btrfs); -GUESTFSD_EXT_CMD(str_umount, umount); -GUESTFSD_EXT_CMD(str_btrfsimage, btrfs-image); - COMPILE_REGEXP (re_btrfs_subvolume_list, "ID\\s+(\\d+).*\\s" "top level\\s+(\\d+).*\\s" @@ -51,7 +44,7 @@ int optgroup_btrfs_available (void) { return test_mode || - (prog_exists (str_btrfs) && filesystem_availa...
2015 Jun 25
13
[PATCH v2 0/9] Better testing of the guestfsd daemon.
In v2: - Kernel command line parsing now moved to the appliance. - In the captive daemon test, the daemon cleanly shuts down on exit. - Add another btrfs test. Rich.
2017 Jul 24
0
[PATCH 2/2] daemon: Replace GUESTFSD_EXT_CMD with --print-external-commands.
...@ #include "c-ctype.h" #include "ignore-value.h" -GUESTFSD_EXT_CMD(str_btrfs, btrfs); -GUESTFSD_EXT_CMD(str_btrfstune, btrfstune); -GUESTFSD_EXT_CMD(str_btrfsck, btrfsck); -GUESTFSD_EXT_CMD(str_mkfs_btrfs, mkfs.btrfs); -GUESTFSD_EXT_CMD(str_umount, umount); -GUESTFSD_EXT_CMD(str_btrfsimage, btrfs-image); +DECLARE_EXTERNAL_COMMANDS ("btrfs", "btrfstune", "btrfsck", "mkfs.btrfs", + "umount", "btrfs-image") COMPILE_REGEXP (re_btrfs_subvolume_list, "ID\\s+(\\d+).*\\s" @@ -5...
2017 Jul 27
3
[PATCH v2] daemon: Remove GUESTFSD_EXT_CMD.
This is a simpler patch that removes GUESTFSD_EXT_CMD completely.
2017 Jul 24
6
[PATCH 0/2] daemon: Replace GUESTFSD_EXT_CMD with --print-external-commands.
Replace GUESTFSD_EXT_CMD with a command line option ‘./guestfsd --print-external-commands’
2015 Oct 05
0
[PATCH 2/2] Fix whitespace.
...o_btrfs_image (char *const *sources, const char *image, int r; if (nr_sources == 0) { - reply_with_error ("list of sources must be non-empty"); - return -1; + reply_with_error ("list of sources must be non-empty"); + return -1; } ADD_ARG (argv, i, str_btrfsimage); if ((optargs_bitmask & GUESTFS_BTRFS_IMAGE_COMPRESSLEVEL_BITMASK) - && compresslevel >= 0) { + && compresslevel >= 0) { snprintf (compresslevel_s, sizeof compresslevel_s, "%d", compresslevel); ADD_ARG (argv, i, "-c"); ADD_A...