Displaying 20 results from an estimated 23 matches for "do_resize2fs_m".
Did you mean:
do_resize2fs_p
2012 Jan 16
2
[PATCH] ext2: fix double the double free
...he double free of err.
Signed-off-by: Wanlong Gao <gaowanlong at cn.fujitsu.com>
---
daemon/ext2.c | 1 -
1 files changed, 0 insertions(+), 1 deletions(-)
diff --git a/daemon/ext2.c b/daemon/ext2.c
index 2cd3da3..5deff24 100644
--- a/daemon/ext2.c
+++ b/daemon/ext2.c
@@ -280,7 +280,6 @@ do_resize2fs_M (const char *device)
r = command (NULL, &err, prog, "-M", device, NULL);
if (r == -1) {
if (strstr (err, "e2fsck -f")) {
- free (err);
reply_with_error ("you need to run e2fsck with the correct and/or forceall options first");
} else {...
2012 Jan 13
4
[PATCH 1/3] ext2: tweak the error returned message of resize2fs-M(BZ755729)
...eall options.
Signed-off-by: Wanlong Gao <gaowanlong at cn.fujitsu.com>
---
daemon/ext2.c | 9 +++++++--
1 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/daemon/ext2.c b/daemon/ext2.c
index 79fd354..c280ca2 100644
--- a/daemon/ext2.c
+++ b/daemon/ext2.c
@@ -277,9 +277,14 @@ do_resize2fs_M (const char *device)
if (e2prog (prog) == -1)
return -1;
- r = command (NULL, &err, prog, "-M" , device, NULL);
+ r = command (NULL, &err, prog, "-M", device, NULL);
if (r == -1) {
- reply_with_error ("%s", err);
+ if (strstr (err, "e2...
2012 Jan 13
3
[PATCH v2 1/3] ext2: tweak the error returned message of resize2fs-M(BZ755729)
...eall options.
Signed-off-by: Wanlong Gao <gaowanlong at cn.fujitsu.com>
---
daemon/ext2.c | 9 +++++++--
1 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/daemon/ext2.c b/daemon/ext2.c
index 79fd354..c280ca2 100644
--- a/daemon/ext2.c
+++ b/daemon/ext2.c
@@ -277,9 +277,14 @@ do_resize2fs_M (const char *device)
if (e2prog (prog) == -1)
return -1;
- r = command (NULL, &err, prog, "-M" , device, NULL);
+ r = command (NULL, &err, prog, "-M", device, NULL);
if (r == -1) {
- reply_with_error ("%s", err);
+ if (strstr (err, "e2...
2015 Oct 14
1
[PATCH v2] New API: resize2fs_P
...| 35 +++++++++++++++++++++++++++++++++++
generator/actions.ml | 14 ++++++++++++++
src/MAX_PROC_NR | 2 +-
3 files changed, 50 insertions(+), 1 deletion(-)
diff --git a/daemon/ext2.c b/daemon/ext2.c
index ebaf0f0..0cd6a66 100644
--- a/daemon/ext2.c
+++ b/daemon/ext2.c
@@ -279,6 +279,41 @@ do_resize2fs_M (const char *device)
return 0;
}
+int64_t
+do_resize2fs_P (const char *device)
+{
+ CLEANUP_FREE char *err = NULL, *out = NULL;
+ CLEANUP_FREE_STRING_LIST char **lines = NULL;
+ int r;
+ size_t i;
+ char *p;
+ int64_t ret;
+ const char *pattern = "Estimated minimum size of the file...
2012 Jan 13
2
[PATCH 1/2] ext2: tweak the error returned message of resize2fs-M(BZ755729)
....
Signed-off-by: Wanlong Gao <gaowanlong at cn.fujitsu.com>
---
daemon/ext2.c | 20 ++++++++++++++++++--
1 files changed, 18 insertions(+), 2 deletions(-)
diff --git a/daemon/ext2.c b/daemon/ext2.c
index 79fd354..9fe938e 100644
--- a/daemon/ext2.c
+++ b/daemon/ext2.c
@@ -277,9 +277,25 @@ do_resize2fs_M (const char *device)
if (e2prog (prog) == -1)
return -1;
- r = command (NULL, &err, prog, "-M" , device, NULL);
+ r = command (NULL, &err, prog, "-M", device, NULL);
if (r == -1) {
- reply_with_error ("%s", err);
+ int i = 0;
+ int len =...
2012 Mar 09
5
[PATCH 0/5] Fixes to resize2fs (RHBZ#755729, RHBZ#801640)
https://bugzilla.redhat.com/show_bug.cgi?id=755729
This bug reports that the error message printed by the resize2fs API
calls (which comes directly from the resize2fs command) says:
Please run 'e2fsck -f /dev/vda1' first.
That command is not possible from guestfish (where it would be
'e2fsck-f' or 'e2fsck ... forceall:true').
Fixing that bug caused this bug:
2015 Oct 13
4
[PATCH] New API: resize2fs_P
...| 35 +++++++++++++++++++++++++++++++++++
generator/actions.ml | 10 ++++++++++
src/MAX_PROC_NR | 2 +-
3 files changed, 46 insertions(+), 1 deletion(-)
diff --git a/daemon/ext2.c b/daemon/ext2.c
index ebaf0f0..3dae40f 100644
--- a/daemon/ext2.c
+++ b/daemon/ext2.c
@@ -279,6 +279,41 @@ do_resize2fs_M (const char *device)
return 0;
}
+int64_t
+do_resize2fs_P (const char *device)
+{
+ CLEANUP_FREE char *err = NULL, *out = NULL;
+ CLEANUP_FREE_STRING_LIST char **lines = NULL;
+ int r;
+ size_t i;
+ char *p;
+ int64_t ret;
+ char pattern[] = "Estimated minimum size of the filesyste...
2015 Oct 13
0
Re: [PATCH] New API: resize2fs_P
...+
> generator/actions.ml | 10 ++++++++++
> src/MAX_PROC_NR | 2 +-
> 3 files changed, 46 insertions(+), 1 deletion(-)
>
> diff --git a/daemon/ext2.c b/daemon/ext2.c
> index ebaf0f0..3dae40f 100644
> --- a/daemon/ext2.c
> +++ b/daemon/ext2.c
> @@ -279,6 +279,41 @@ do_resize2fs_M (const char *device)
> return 0;
> }
>
> +int64_t
> +do_resize2fs_P (const char *device)
> +{
> + CLEANUP_FREE char *err = NULL, *out = NULL;
> + CLEANUP_FREE_STRING_LIST char **lines = NULL;
> + int r;
> + size_t i;
> + char *p;
> + int64_t ret;
>...
2011 Jan 14
0
Patch. not working
...tdiff;h=4ffa2d6798f7a2bf0baec8e1084659cf6358bc31
Rich.
> diff --git a/daemon/ext2.c b/daemon/ext2.c
> index 725352e..85ce316 100644
> --- a/daemon/ext2.c
> +++ b/daemon/ext2.c
> @@ -266,6 +266,27 @@ do_resize2fs_size (const char *device, int64_t size)
> }
>
> int
> +do_resize2fs_M (const char *device)
> +{
> + char *err;
> + int r;
> +
> + char prog[] = "resize2fs";
> + if (e2prog (prog) == -1)
> + return -1;
> +
> + r = command (NULL, &err, prog, "-M" , device, NULL);
> + if (r == -1) {
> + reply_with_erro...
2015 Oct 16
0
[PATCH 2/2] Include resize2fs_P into get_min_size.
...onst char *device);
+extern int64_t ext_get_min_size (const char *device);
/*-- in blkid.c --*/
extern char *get_blkid_tag (const char *device, const char *tag);
diff --git a/daemon/ext2.c b/daemon/ext2.c
index 0cd6a66..fcf39de 100644
--- a/daemon/ext2.c
+++ b/daemon/ext2.c
@@ -279,8 +279,31 @@ do_resize2fs_M (const char *device)
return 0;
}
+static int32_t
+get_block_size (const char *device)
+{
+ CLEANUP_FREE_STRING_LIST char **params = NULL;
+ const char *block_pattern = "Block size";
+ size_t i;
+ int32_t block_size;
+
+ params = do_tune2fs_l (device);
+ if (params == NULL)
+...
2015 Oct 19
0
[PATCH 2/2] Include resize2fs_P into vfs_min_size.
...m (const char *device);
+extern int64_t ext_min_size (const char *device);
/*-- in blkid.c --*/
extern char *get_blkid_tag (const char *device, const char *tag);
diff --git a/daemon/ext2.c b/daemon/ext2.c
index 0cd6a66..f00e081 100644
--- a/daemon/ext2.c
+++ b/daemon/ext2.c
@@ -279,8 +279,34 @@ do_resize2fs_M (const char *device)
return 0;
}
+static int32_t
+get_block_size (const char *device)
+{
+ CLEANUP_FREE_STRING_LIST char **params = NULL;
+ const char *block_pattern = "Block size";
+ size_t i;
+ int32_t block_size;
+
+ params = do_tune2fs_l (device);
+ if (params == NULL)
+...
2015 Oct 20
0
[PATCHv3 2/2] Include resize2fs_P into vfs_min_size.
...--git a/daemon/ext2.c b/daemon/ext2.c
index 0cd6a66..01f934b 100644
--- a/daemon/ext2.c
+++ b/daemon/ext2.c
@@ -29,6 +29,7 @@
#include "daemon.h"
#include "c-ctype.h"
#include "actions.h"
+#include "xstrtol.h"
#define MAX_ARGS 128
@@ -279,15 +280,41 @@ do_resize2fs_M (const char *device)
return 0;
}
+static long
+get_block_size (const char *device)
+{
+ CLEANUP_FREE_STRING_LIST char **params = NULL;
+ const char *block_pattern = "Block size";
+ size_t i;
+ long block_size;
+
+ params = do_tune2fs_l (device);
+ if (params == NULL)
+ retur...
2015 Oct 19
1
Re: [PATCH 2/2] Include resize2fs_P into vfs_min_size.
...ext_min_size (const char *device);
>
> /*-- in blkid.c --*/
> extern char *get_blkid_tag (const char *device, const char *tag);
> diff --git a/daemon/ext2.c b/daemon/ext2.c
> index 0cd6a66..f00e081 100644
> --- a/daemon/ext2.c
> +++ b/daemon/ext2.c
> @@ -279,8 +279,34 @@ do_resize2fs_M (const char *device)
> return 0;
> }
>
> +static int32_t
> +get_block_size (const char *device)
> +{
> + CLEANUP_FREE_STRING_LIST char **params = NULL;
> + const char *block_pattern = "Block size";
> + size_t i;
> + int32_t block_size;
> +
> +...
2015 Oct 19
5
[PATCHv2 0/2] Introduce vfs_min_size API to get minimum filesystem size.
Tried to make it in accordance with your comments.
Difference to v1:
Added reply_with_error where necessary.
Changed name get_min_size -> vfs_min_size.
Maxim Perevedentsev (2):
New API: vfs_min_size
Include resize2fs_P into vfs_min_size.
daemon/Makefile.am | 1 +
daemon/daemon.h | 2 ++
daemon/ext2.c | 45 ++++++++++++++++++++++++++-----
daemon/fs-min-size.c | 49
2015 Oct 20
4
[PATCHv3 0/2] Introduce vfs_min_size API to get minimum filesystem size.
Tried to make it in accordance with your comments.
Difference to v1:
Added reply_with_error where necessary.
Changed name get_min_size -> vfs_min_size.
Difference to v2:
Changed name to vfs_minimum_size.
Changed parsing to xstrtol + STR* macros where possible.
Maxim Perevedentsev (2):
New API: vfs_min_size
Include resize2fs_P into vfs_min_size.
daemon/Makefile.am | 1 +
2015 Oct 16
4
[PATCH 0/2] Introduce get_min_size API to get minimum filesystem size.
Tried to make it in accordance with your comments.
Maybe you can suggest a better name for API?
Maxim Perevedentsev (2):
New API: get_min_size
Include resize2fs_P into get_min_size.
daemon/Makefile.am | 1 +
daemon/daemon.h | 2 ++
daemon/ext2.c | 37 ++++++++++++++++++++++++----
daemon/fs-min-size.c | 49 +++++++++++++++++++++++++++++++++++++
daemon/ntfs.c | 68
2015 Oct 20
8
[PATCHv4 0/2] Introduce vfs_minimum_size API to get minimum filesystem size.
Tried to make it in accordance with your comments.
Difference to v1:
Added reply_with_error where necessary.
Changed name get_min_size -> vfs_min_size.
Difference to v2:
Changed name to vfs_minimum_size.
Changed parsing to xstrtol + STR* macros where possible.
Difference to v3:
Decapitalize error messages.
Maxim Perevedentsev (2):
New API: vfs_minimum_size
Include resize2fs_P into
2012 Aug 30
2
[PATCH v2] daemon: collect list of called external commands
...sizeof buf, "%" PRIi64 "K", size);
- r = command (NULL, &err, "resize2fs", device, buf, NULL);
+ r = command (NULL, &err, str_resize2fs, device, buf, NULL);
if (r == -1) {
reply_with_error ("%s", err);
free (err);
@@ -239,7 +246,7 @@ do_resize2fs_M (const char *device)
if (if_not_mounted_run_e2fsck (device) == -1)
return -1;
- r = command (NULL, &err, "resize2fs", "-M", device, NULL);
+ r = command (NULL, &err, str_resize2fs, "-M", device, NULL);
if (r == -1) {
reply_with_error ("...
2012 Aug 30
1
[PATCH] collect list of called external commands
...snprintf (buf, sizeof buf, "%" PRIi64 "K", size);
- r = command (NULL, &err, prog, device, buf, NULL);
+ r = command (NULL, &err, str_resize2fs, device, buf, NULL);
if (r == -1) {
reply_with_error ("%s", err);
free (err);
@@ -282,14 +285,13 @@ do_resize2fs_M (const char *device)
char *err;
int r;
- char prog[] = "resize2fs";
- if (e2prog (prog) == -1)
+ if (e2prog (str_resize2fs) == -1)
return -1;
if (if_not_mounted_run_e2fsck (device) == -1)
return -1;
- r = command (NULL, &err, prog, "-M", device,...
2017 Jul 27
0
[PATCH v2] daemon: Remove GUESTFSD_EXT_CMD.
..., sizeof buf, "%" PRIi64 "K", size);
- r = command (NULL, &err, str_resize2fs, device, buf, NULL);
+ r = command (NULL, &err, "resize2fs", device, buf, NULL);
if (r == -1) {
reply_with_error ("%s", err);
return -1;
@@ -265,7 +257,7 @@ do_resize2fs_M (const char *device)
if (if_not_mounted_run_e2fsck (device) == -1)
return -1;
- r = command (NULL, &err, str_resize2fs, "-M", device, NULL);
+ r = command (NULL, &err, "resize2fs", "-M", device, NULL);
if (r == -1) {
reply_with_error ("...