diff options
author | Amar Tumballi <amar@gluster.com> | 2010-08-09 05:38:46 +0000 |
---|---|---|
committer | Anand V. Avati <avati@dev.gluster.com> | 2010-08-11 22:24:32 -0700 |
commit | 0b501ac95edc0ef5945228eb47e6482cfc4efa41 (patch) | |
tree | 58fa16eb100868a65e754f704b2a19817250ca91 /rpc | |
parent | 6ff316dca7c9eebab14e71b6ad0908c2e45a5ee2 (diff) |
'gluster volume rebalance' related fixes
Signed-off-by: Amar Tumballi <amar@gluster.com>
Signed-off-by: Anand V. Avati <avati@dev.gluster.com>
BUG: 1307 (gluster volume defrag <VOLNAME> status)
URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=1307
Diffstat (limited to 'rpc')
-rw-r--r-- | rpc/xdr/src/cli1-xdr.c | 8 | ||||
-rw-r--r-- | rpc/xdr/src/cli1-xdr.h | 4 | ||||
-rw-r--r-- | rpc/xdr/src/cli1.h | 4 |
3 files changed, 16 insertions, 0 deletions
diff --git a/rpc/xdr/src/cli1-xdr.c b/rpc/xdr/src/cli1-xdr.c index 32e42c21c..3dddde15f 100644 --- a/rpc/xdr/src/cli1-xdr.c +++ b/rpc/xdr/src/cli1-xdr.c @@ -301,6 +301,8 @@ bool_t xdr_gf1_cli_defrag_vol_req (XDR *xdrs, gf1_cli_defrag_vol_req *objp) { + if (!xdr_int (xdrs, &objp->cmd)) + return FALSE; if (!xdr_string (xdrs, &objp->volname, ~0)) return FALSE; return TRUE; @@ -316,6 +318,12 @@ xdr_gf1_cli_defrag_vol_rsp (XDR *xdrs, gf1_cli_defrag_vol_rsp *objp) return FALSE; if (!xdr_string (xdrs, &objp->volname, ~0)) return FALSE; + if (!xdr_u_quad_t (xdrs, &objp->files)) + return FALSE; + if (!xdr_u_quad_t (xdrs, &objp->size)) + return FALSE; + if (!xdr_u_quad_t (xdrs, &objp->lookedup_files)) + return FALSE; return TRUE; } diff --git a/rpc/xdr/src/cli1-xdr.h b/rpc/xdr/src/cli1-xdr.h index 3580ebb76..ed45d89a7 100644 --- a/rpc/xdr/src/cli1-xdr.h +++ b/rpc/xdr/src/cli1-xdr.h @@ -175,6 +175,7 @@ struct gf1_cli_rename_vol_rsp { typedef struct gf1_cli_rename_vol_rsp gf1_cli_rename_vol_rsp; struct gf1_cli_defrag_vol_req { + int cmd; char *volname; }; typedef struct gf1_cli_defrag_vol_req gf1_cli_defrag_vol_req; @@ -183,6 +184,9 @@ struct gf1_cli_defrag_vol_rsp { int op_ret; int op_errno; char *volname; + u_quad_t files; + u_quad_t size; + u_quad_t lookedup_files; }; typedef struct gf1_cli_defrag_vol_rsp gf1_cli_defrag_vol_rsp; diff --git a/rpc/xdr/src/cli1.h b/rpc/xdr/src/cli1.h index 73f9f8d7b..578b8225c 100644 --- a/rpc/xdr/src/cli1.h +++ b/rpc/xdr/src/cli1.h @@ -25,6 +25,10 @@ #include "cli1-xdr.h" +#define GF_DEFRAG_CMD_START 1 +#define GF_DEFRAG_CMD_STOP 2 +#define GF_DEFRAG_CMD_STATUS 3 + ssize_t gf_xdr_serialize_cli_probe_rsp (struct iovec outmsg, void *rsp); |