Displaying 15 results from an estimated 15 matches for "do_xfs_growfs".
2015 Jul 17
1
[PATCH] daemon: add a space after func/macro to fit code-style
...stems",
+ NOT_SUPPORTED (-1, "don't know how to set the random UUID for '%s' filesystems",
vfs_type);
return r;
}
diff --git a/daemon/xfs.c b/daemon/xfs.c
index e5e8b62..c1a1854 100644
--- a/daemon/xfs.c
+++ b/daemon/xfs.c
@@ -408,7 +408,7 @@ do_xfs_growfs (const char *path,
reply_with_error ("logsize must be >= 0");
return -1;
}
- snprintf(logsize_s, sizeof logsize_s, "%" PRIi64, logsize);
+ snprintf (logsize_s, sizeof logsize_s, "%" PRIi64, logsize);
ADD_ARG (argv, i, "-L");...
2012 Aug 06
1
[PATCH] xfs: fix a possible memory leak
free out when failure.
Signed-off-by: Wanlong Gao <gaowanlong at cn.fujitsu.com>
---
daemon/xfs.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/daemon/xfs.c b/daemon/xfs.c
index 73ba791..b331b9b 100644
--- a/daemon/xfs.c
+++ b/daemon/xfs.c
@@ -457,5 +457,6 @@ do_xfs_growfs (const char *path,
error:
if (buf) free (buf);
if (err) free (err);
+ if (out) free (out);
return NULL;
}
--
1.7.12.rc1
2012 Jul 31
1
[PATCH] xfs: add new api xfs-growfs
...c/MAX_PROC_NR | 2 +-
5 files changed, 140 insertions(+), 3 deletions(-)
diff --git a/daemon/xfs.c b/daemon/xfs.c
index e0f0062..97da3f1 100644
--- a/daemon/xfs.c
+++ b/daemon/xfs.c
@@ -348,3 +348,122 @@ error:
free_strings (lines);
return ret;
}
+
+guestfs_int_xfsinfo *
+do_xfs_growfs (const char *path,
+ int datasec, int logsec, int rtsec,
+ int64_t datasize, int64_t logsize, int64_t rtsize,
+ int64_t rtextsize, int32_t maxpct)
+{
+
+#define MAX_ARGS 64
+
+ int r;
+ char *buf;
+ char *out = NULL, *err = NULL;
+ char **lines = NULL;...
2015 Jun 24
0
[PATCH 3/5] uuid: use newly introduced do_xfs_admin_uuid of xfs
...e, NULL);
- if (r == -1) {
- reply_with_error ("%s", err);
- return -1;
- }
-
- return 0;
+ return do_xfs_admin_uuid (device, uuid);
}
static int
diff --git a/daemon/xfs.c b/daemon/xfs.c
index 687013b..aaeff3e 100644
--- a/daemon/xfs.c
+++ b/daemon/xfs.c
@@ -456,6 +456,13 @@ do_xfs_growfs (const char *path,
}
int
+do_xfs_admin_uuid (const char *device, const char *uuid)
+{
+ optargs_bitmask = GUESTFS_XFS_ADMIN_UUID_BITMASK;
+ return do_xfs_admin (device, 0, 0, 0, 0, 0, NULL, uuid);
+}
+
+int
do_xfs_admin (const char *device,
int extunwritten, int imgfile, int v...
2015 Jun 30
0
[PATCH v4 3/7] uuid: use newly introduced xfs_set_uuid of xfs
...device, NULL);
- if (r == -1) {
- reply_with_error ("%s", err);
- return -1;
- }
-
- return 0;
+ return xfs_set_uuid (device, uuid);
}
static int
diff --git a/daemon/xfs.c b/daemon/xfs.c
index 687013b..fb7acb4 100644
--- a/daemon/xfs.c
+++ b/daemon/xfs.c
@@ -456,6 +456,13 @@ do_xfs_growfs (const char *path,
}
int
+xfs_set_uuid (const char *device, const char *uuid)
+{
+ optargs_bitmask = GUESTFS_XFS_ADMIN_UUID_BITMASK;
+ return do_xfs_admin (device, 0, 0, 0, 0, 0, NULL, uuid);
+}
+
+int
do_xfs_admin (const char *device,
int extunwritten, int imgfile, int v2log,...
2015 Jun 24
10
[PATCH 0/5] uuid: add btrfs uuid change support and some rework
- Btrfs-progs v4.1 introduced new feature of changing
uuid of btrfs partition.
This patch add support of this.
- uuids.c did a lot of deplicated work for changing uuid
of fs. Use existed functions.
-- Introduce new API: btrfstune_set_uuid_random
Chen Hanxiao (5):
uuid: add support to change uuid of btrfs partition
uuid: use existed function of ext2
uuid: use newly introduced
2015 Jun 26
5
[PATCH v3 0/4] uuid: add btrfs uuid change support and some rework
- Btrfs-progs v4.1 introduced new feature of changing
uuid of btrfs partition.
This patch add support of this.
- uuids.c did a lot of deplicated work for changing uuid
of fs. Use existing functions.
v3: set errno if feature is not available.
Chen Hanxiao (4):
uuid: add support to change uuid of btrfs partition
uuid: use existing function of ext2
uuid: use newly introduced
2015 Jun 30
13
[PATCH v4 0/7] uuid: add btrfs uuid change support and set_uuid_random
- Btrfs-progs v4.1 introduced new feature of changing
uuid of btrfs partition.
This patch add support of this.
- Introduce set_uuid_random
- uuids.c did a lot of deplicated work for changing uuid
of fs. Use existing functions.
v4: introduce get_random_uuid
improve testcases
squash internal API patches
v3.1: fix typos
v3: set errno if feature is not available.
Chen Hanxiao (7):
2015 Jun 26
14
[PATCH v3.1 0/9] uuid: add btrfs uuid change support and set_uuid_random
- Btrfs-progs v4.1 introduced new feature of changing
uuid of btrfs partition.
This patch add support of this.
- Introduce set_uuid_random
- uuids.c did a lot of deplicated work for changing uuid
of fs. Use existing functions.
v3.1: fix typos
v3: set errno if feature is not available.
Chen Hanxiao (9):
uuid: add support to change uuid of btrfs partition
uuid: use existing function of
2012 Aug 30
2
[PATCH v2] daemon: collect list of called external commands
...,7 @@ do_xfs_info (const char *pathordevice)
return NULL;
}
- r = command (&out, &err, "xfs_info", buf, NULL);
+ r = command (&out, &err, str_xfs_info, buf, NULL);
free (buf);
if (r == -1) {
reply_with_error ("%s", err);
@@ -374,7 +380,7 @@ do_xfs_growfs (const char *path,
return -1;
}
- ADD_ARG (argv, i, "xfs_growfs");
+ ADD_ARG (argv, i, str_xfs_growfs);
/* Optional arguments */
if (!(optargs_bitmask & GUESTFS_XFS_GROWFS_DATASEC_BITMASK))
@@ -471,7 +477,7 @@ do_xfs_admin (const char *device,
const char *argv[M...
2012 Aug 30
1
[PATCH] collect list of called external commands
...,7 @@ do_xfs_info (const char *pathordevice)
return NULL;
}
- r = command (&out, &err, "xfs_info", buf, NULL);
+ r = command (&out, &err, str_xfs_info, buf, NULL);
free (buf);
if (r == -1) {
reply_with_error ("%s", err);
@@ -374,7 +379,7 @@ do_xfs_growfs (const char *path,
return -1;
}
- ADD_ARG (argv, i, "xfs_growfs");
+ ADD_ARG (argv, i, str_xfs_growfs);
/* Optional arguments */
if (!(optargs_bitmask & GUESTFS_XFS_GROWFS_DATASEC_BITMASK))
@@ -471,7 +476,7 @@ do_xfs_admin (const char *device,
const char *argv[M...
2017 Jul 27
0
[PATCH v2] daemon: Remove GUESTFSD_EXT_CMD.
...@@ do_xfs_info (const char *pathordevice)
return NULL;
}
- r = command (&out, &err, str_xfs_info, buf, NULL);
+ r = command (&out, &err, "xfs_info", buf, NULL);
if (r == -1) {
reply_with_error ("%s", err);
return NULL;
@@ -376,7 +370,7 @@ do_xfs_growfs (const char *path,
return -1;
}
- ADD_ARG (argv, i, str_xfs_growfs);
+ ADD_ARG (argv, i, "xfs_growfs");
/* Optional arguments */
if (!(optargs_bitmask & GUESTFS_XFS_GROWFS_DATASEC_BITMASK))
@@ -487,7 +481,7 @@ do_xfs_admin (const char *device,
const char *argv[M...
2017 Jul 24
0
[PATCH 2/2] daemon: Replace GUESTFSD_EXT_CMD with --print-external-commands.
...@@ do_xfs_info (const char *pathordevice)
return NULL;
}
- r = command (&out, &err, str_xfs_info, buf, NULL);
+ r = command (&out, &err, "xfs_info", buf, NULL);
if (r == -1) {
reply_with_error ("%s", err);
return NULL;
@@ -376,7 +373,7 @@ do_xfs_growfs (const char *path,
return -1;
}
- ADD_ARG (argv, i, str_xfs_growfs);
+ ADD_ARG (argv, i, "xfs_growfs");
/* Optional arguments */
if (!(optargs_bitmask & GUESTFS_XFS_GROWFS_DATASEC_BITMASK))
@@ -487,7 +484,7 @@ do_xfs_admin (const char *device,
const char *argv[M...
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’