summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt
diff options
context:
space:
mode:
Diffstat (limited to 'xlators/mgmt')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-bitd-svc.h16
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-conn-helper.h2
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-conn-mgmt.h34
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-errno.h34
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-geo-rep.h33
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-gfproxyd-svc-helper.h34
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-gfproxyd-svc.h22
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-hooks.h86
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-locks.h36
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-mem-types.h119
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-messages.h892
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-mgmt.h71
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-mountbroker.h37
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-nfs-svc.h6
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-op-sm.h304
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-peer-utils.h66
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-pmap.h47
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-proc-mgmt.h34
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-quota.h4
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-quotad-svc.h10
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-rcu.h4
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-scrub-svc.h22
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-server-quorum.h26
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-shd-svc.h10
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-sm.h240
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-snapd-svc-helper.h16
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-snapd-svc.h20
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-snapshot-utils.h141
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-statedump.h2
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-store.h240
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-svc-helper.h26
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-svc-mgmt.h57
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-syncop.h100
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-tierd-svc-helper.h20
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-tierd-svc.h17
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-utils.h850
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-volgen.h325
-rw-r--r--xlators/mgmt/glusterd/src/glusterd.h2030
38 files changed, 2867 insertions, 3166 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-bitd-svc.h b/xlators/mgmt/glusterd/src/glusterd-bitd-svc.h
index 7f276fb0b5c..1bff084a9a8 100644
--- a/xlators/mgmt/glusterd/src/glusterd-bitd-svc.h
+++ b/xlators/mgmt/glusterd/src/glusterd-bitd-svc.h
@@ -16,25 +16,25 @@
#define bitd_svc_name "bitd"
void
-glusterd_bitdsvc_build (glusterd_svc_t *svc);
+glusterd_bitdsvc_build(glusterd_svc_t *svc);
int
-glusterd_bitdsvc_init (glusterd_svc_t *svc);
+glusterd_bitdsvc_init(glusterd_svc_t *svc);
int
-glusterd_bitdsvc_manager (glusterd_svc_t *svc, void *data, int flags);
+glusterd_bitdsvc_manager(glusterd_svc_t *svc, void *data, int flags);
int
-glusterd_bitdsvc_start (glusterd_svc_t *svc, int flags);
+glusterd_bitdsvc_start(glusterd_svc_t *svc, int flags);
int
-glusterd_bitdsvc_stop (glusterd_svc_t *svc, int sig);
+glusterd_bitdsvc_stop(glusterd_svc_t *svc, int sig);
int
-glusterd_bitdsvc_reconfigure ();
+glusterd_bitdsvc_reconfigure();
void
-glusterd_bitdsvc_build_volfile_path (char *server, char *workdir,
- char *volfile, size_t len);
+glusterd_bitdsvc_build_volfile_path(char *server, char *workdir, char *volfile,
+ size_t len);
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-conn-helper.h b/xlators/mgmt/glusterd/src/glusterd-conn-helper.h
index 80468d6de75..6f500309175 100644
--- a/xlators/mgmt/glusterd/src/glusterd-conn-helper.h
+++ b/xlators/mgmt/glusterd/src/glusterd-conn-helper.h
@@ -16,6 +16,6 @@
#include "glusterd-conn-mgmt.h"
glusterd_svc_t *
-glusterd_conn_get_svc_object (glusterd_conn_t *conn);
+glusterd_conn_get_svc_object(glusterd_conn_t *conn);
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-conn-mgmt.h b/xlators/mgmt/glusterd/src/glusterd-conn-mgmt.h
index 5820419dbf5..602c0ba7b84 100644
--- a/xlators/mgmt/glusterd/src/glusterd-conn-mgmt.h
+++ b/xlators/mgmt/glusterd/src/glusterd-conn-mgmt.h
@@ -15,37 +15,37 @@
typedef struct glusterd_conn_ glusterd_conn_t;
-typedef int (*glusterd_conn_notify_t)
- (glusterd_conn_t *conn, rpc_clnt_event_t event);
+typedef int (*glusterd_conn_notify_t)(glusterd_conn_t *conn,
+ rpc_clnt_event_t event);
struct glusterd_conn_ {
- struct rpc_clnt *rpc;
- char sockpath[PATH_MAX];
- int frame_timeout;
- /* Existing daemons tend to specialize their respective
- * notify implementations, so ... */
- glusterd_conn_notify_t notify;
+ struct rpc_clnt *rpc;
+ char sockpath[PATH_MAX];
+ int frame_timeout;
+ /* Existing daemons tend to specialize their respective
+ * notify implementations, so ... */
+ glusterd_conn_notify_t notify;
};
int
-glusterd_conn_init (glusterd_conn_t *conn, char *sockpath,
- int frame_timeout, glusterd_conn_notify_t notify);
+glusterd_conn_init(glusterd_conn_t *conn, char *sockpath, int frame_timeout,
+ glusterd_conn_notify_t notify);
int
-glusterd_conn_term (glusterd_conn_t *conn);
+glusterd_conn_term(glusterd_conn_t *conn);
int
-glusterd_conn_connect (glusterd_conn_t *conn);
+glusterd_conn_connect(glusterd_conn_t *conn);
int
-glusterd_conn_disconnect (glusterd_conn_t *conn);
+glusterd_conn_disconnect(glusterd_conn_t *conn);
int
-glusterd_conn_common_notify (struct rpc_clnt *rpc, void *mydata,
- rpc_clnt_event_t event, void *data);
+glusterd_conn_common_notify(struct rpc_clnt *rpc, void *mydata,
+ rpc_clnt_event_t event, void *data);
int32_t
-glusterd_conn_build_socket_filepath (char *rundir, uuid_t uuid,
- char *socketpath, int len);
+glusterd_conn_build_socket_filepath(char *rundir, uuid_t uuid, char *socketpath,
+ int len);
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-errno.h b/xlators/mgmt/glusterd/src/glusterd-errno.h
index bfb56b56240..7e1575b57af 100644
--- a/xlators/mgmt/glusterd/src/glusterd-errno.h
+++ b/xlators/mgmt/glusterd/src/glusterd-errno.h
@@ -11,23 +11,23 @@
#define _GLUSTERD_ERRNO_H
enum glusterd_op_errno {
- EG_INTRNL = 30800, /* Internal Error */
- EG_OPNOTSUP = 30801, /* Gluster Op Not Supported */
- EG_ANOTRANS = 30802, /* Another Transaction in Progress */
- EG_BRCKDWN = 30803, /* One or more brick is down */
- EG_NODEDWN = 30804, /* One or more node is down */
- EG_HRDLMT = 30805, /* Hard Limit is reached */
- EG_NOVOL = 30806, /* Volume does not exist */
- EG_NOSNAP = 30807, /* Snap does not exist */
- EG_RBALRUN = 30808, /* Rebalance is running */
- EG_VOLRUN = 30809, /* Volume is running */
- EG_VOLSTP = 30810, /* Volume is not running */
- EG_VOLEXST = 30811, /* Volume exists */
- EG_SNAPEXST = 30812, /* Snapshot exists */
- EG_ISSNAP = 30813, /* Volume is a snap volume */
- EG_GEOREPRUN = 30814, /* Geo-Replication is running */
- EG_NOTTHINP = 30815, /* Bricks are not thinly provisioned */
- EG_NOGANESHA = 30816, /* obsolete ganesha is not enabled */
+ EG_INTRNL = 30800, /* Internal Error */
+ EG_OPNOTSUP = 30801, /* Gluster Op Not Supported */
+ EG_ANOTRANS = 30802, /* Another Transaction in Progress */
+ EG_BRCKDWN = 30803, /* One or more brick is down */
+ EG_NODEDWN = 30804, /* One or more node is down */
+ EG_HRDLMT = 30805, /* Hard Limit is reached */
+ EG_NOVOL = 30806, /* Volume does not exist */
+ EG_NOSNAP = 30807, /* Snap does not exist */
+ EG_RBALRUN = 30808, /* Rebalance is running */
+ EG_VOLRUN = 30809, /* Volume is running */
+ EG_VOLSTP = 30810, /* Volume is not running */
+ EG_VOLEXST = 30811, /* Volume exists */
+ EG_SNAPEXST = 30812, /* Snapshot exists */
+ EG_ISSNAP = 30813, /* Volume is a snap volume */
+ EG_GEOREPRUN = 30814, /* Geo-Replication is running */
+ EG_NOTTHINP = 30815, /* Bricks are not thinly provisioned */
+ EG_NOGANESHA = 30816, /* obsolete ganesha is not enabled */
};
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-geo-rep.h b/xlators/mgmt/glusterd/src/glusterd-geo-rep.h
index 8d08bcda50e..5f5fe344406 100644
--- a/xlators/mgmt/glusterd/src/glusterd-geo-rep.h
+++ b/xlators/mgmt/glusterd/src/glusterd-geo-rep.h
@@ -11,7 +11,7 @@
#define _GLUSTERD_GEO_REP_H_
#ifndef GSYNC_CONF_TEMPLATE
-#define GSYNC_CONF_TEMPLATE GEOREP"/gsyncd_template.conf"
+#define GSYNC_CONF_TEMPLATE GEOREP "/gsyncd_template.conf"
#endif
/* <slave host>::<slave volume> */
@@ -20,34 +20,33 @@
/* slave info format:
* <master host uuid>:ssh://{<slave_user>@}<slave host>::<slave volume> \
* :<slave volume uuid> */
-#define VOLINFO_SLAVE_URL_MAX (LOGIN_NAME_MAX + (2*GF_UUID_BUF_SIZE) \
- + SLAVE_URL_INFO_MAX + 10)
+#define VOLINFO_SLAVE_URL_MAX \
+ (LOGIN_NAME_MAX + (2 * GF_UUID_BUF_SIZE) + SLAVE_URL_INFO_MAX + 10)
typedef struct glusterd_gsync_status_temp {
- dict_t *rsp_dict;
- glusterd_volinfo_t *volinfo;
- char *node;
+ dict_t *rsp_dict;
+ glusterd_volinfo_t *volinfo;
+ char *node;
} glusterd_gsync_status_temp_t;
typedef struct gsync_status_param {
- int is_active;
- glusterd_volinfo_t *volinfo;
+ int is_active;
+ glusterd_volinfo_t *volinfo;
} gsync_status_param_t;
int
-gsync_status (char *master, char *slave, char *conf_path,
- int *status, gf_boolean_t *is_template_in_use);
+gsync_status(char *master, char *slave, char *conf_path, int *status,
+ gf_boolean_t *is_template_in_use);
void
-glusterd_check_geo_rep_configured (glusterd_volinfo_t *volinfo,
- gf_boolean_t *flag);
+glusterd_check_geo_rep_configured(glusterd_volinfo_t *volinfo,
+ gf_boolean_t *flag);
int
-_get_slave_status (dict_t *dict, char *key, data_t *value, void *data);
+_get_slave_status(dict_t *dict, char *key, data_t *value, void *data);
int
-glusterd_check_geo_rep_running (gsync_status_param_t *param, char **op_errstr);
+glusterd_check_geo_rep_running(gsync_status_param_t *param, char **op_errstr);
int
-glusterd_get_gsync_status_mst (glusterd_volinfo_t *volinfo, dict_t *rsp_dict,
- char *node);
+glusterd_get_gsync_status_mst(glusterd_volinfo_t *volinfo, dict_t *rsp_dict,
+ char *node);
#endif
-
diff --git a/xlators/mgmt/glusterd/src/glusterd-gfproxyd-svc-helper.h b/xlators/mgmt/glusterd/src/glusterd-gfproxyd-svc-helper.h
index 34a0e62a85a..3aca218a65d 100644
--- a/xlators/mgmt/glusterd/src/glusterd-gfproxyd-svc-helper.h
+++ b/xlators/mgmt/glusterd/src/glusterd-gfproxyd-svc-helper.h
@@ -14,38 +14,38 @@
#include "glusterd.h"
void
-glusterd_svc_build_gfproxyd_rundir (glusterd_volinfo_t *volinfo,
- char *path, int path_len);
+glusterd_svc_build_gfproxyd_rundir(glusterd_volinfo_t *volinfo, char *path,
+ int path_len);
void
-glusterd_svc_build_gfproxyd_socket_filepath (glusterd_volinfo_t *volinfo,
- char *path, int path_len);
+glusterd_svc_build_gfproxyd_socket_filepath(glusterd_volinfo_t *volinfo,
+ char *path, int path_len);
void
-glusterd_svc_build_gfproxyd_pidfile (glusterd_volinfo_t *volinfo,
- char *path, int path_len);
+glusterd_svc_build_gfproxyd_pidfile(glusterd_volinfo_t *volinfo, char *path,
+ int path_len);
void
-glusterd_svc_build_gfproxyd_volfile_path (glusterd_volinfo_t *volinfo,
- char *path, int path_len);
+glusterd_svc_build_gfproxyd_volfile_path(glusterd_volinfo_t *volinfo,
+ char *path, int path_len);
void
-glusterd_svc_build_gfproxyd_logdir (char *logdir, char *volname, size_t len);
+glusterd_svc_build_gfproxyd_logdir(char *logdir, char *volname, size_t len);
void
-glusterd_svc_build_gfproxyd_logfile (char *logfile, char *logdir, size_t len);
+glusterd_svc_build_gfproxyd_logfile(char *logfile, char *logdir, size_t len);
int
-glusterd_svc_check_gfproxyd_volfile_identical (char *svc_name,
+glusterd_svc_check_gfproxyd_volfile_identical(char *svc_name,
+ glusterd_volinfo_t *volinfo,
+ gf_boolean_t *identical);
+int
+glusterd_svc_check_gfproxyd_topology_identical(char *svc_name,
glusterd_volinfo_t *volinfo,
gf_boolean_t *identical);
int
-glusterd_svc_check_gfproxyd_topology_identical (char *svc_name,
- glusterd_volinfo_t *volinfo,
- gf_boolean_t *identical);
-int
-glusterd_is_gfproxyd_enabled (glusterd_volinfo_t *volinfo);
+glusterd_is_gfproxyd_enabled(glusterd_volinfo_t *volinfo);
glusterd_volinfo_t *
-glusterd_gfproxyd_volinfo_from_svc (glusterd_svc_t *svc);
+glusterd_gfproxyd_volinfo_from_svc(glusterd_svc_t *svc);
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-gfproxyd-svc.h b/xlators/mgmt/glusterd/src/glusterd-gfproxyd-svc.h
index a4af632a5b0..db1c8b1e7b0 100644
--- a/xlators/mgmt/glusterd/src/glusterd-gfproxyd-svc.h
+++ b/xlators/mgmt/glusterd/src/glusterd-gfproxyd-svc.h
@@ -16,32 +16,32 @@
#define gfproxyd_svc_name "gfproxyd"
struct glusterd_gfproxydsvc_ {
- glusterd_svc_t svc;
- int port;
- gf_store_handle_t *handle;
+ glusterd_svc_t svc;
+ int port;
+ gf_store_handle_t *handle;
};
typedef struct glusterd_gfproxydsvc_ glusterd_gfproxydsvc_t;
void
-glusterd_gfproxydsvc_build (glusterd_svc_t *svc);
+glusterd_gfproxydsvc_build(glusterd_svc_t *svc);
int
-glusterd_gfproxydsvc_manager (glusterd_svc_t *svc, void *data, int flags);
+glusterd_gfproxydsvc_manager(glusterd_svc_t *svc, void *data, int flags);
int
-glusterd_gfproxydsvc_start (glusterd_svc_t *svc, int flags);
+glusterd_gfproxydsvc_start(glusterd_svc_t *svc, int flags);
int
-glusterd_gfproxydsvc_stop (glusterd_svc_t *svc, int sig);
+glusterd_gfproxydsvc_stop(glusterd_svc_t *svc, int sig);
int
-glusterd_gfproxydsvc_reconfigure ();
+glusterd_gfproxydsvc_reconfigure();
void
-glusterd_gfproxydsvc_build_volfile_path (char *server, char *workdir,
- char *volfile, size_t len);
+glusterd_gfproxydsvc_build_volfile_path(char *server, char *workdir,
+ char *volfile, size_t len);
int
-glusterd_gfproxydsvc_restart ();
+glusterd_gfproxydsvc_restart();
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-hooks.h b/xlators/mgmt/glusterd/src/glusterd-hooks.h
index 752e459f89c..3813c18e989 100644
--- a/xlators/mgmt/glusterd/src/glusterd-hooks.h
+++ b/xlators/mgmt/glusterd/src/glusterd-hooks.h
@@ -12,79 +12,77 @@
#include <fnmatch.h>
-#define GLUSTERD_GET_HOOKS_DIR(path, version, priv) \
- do { \
- int32_t len; \
- len = snprintf (path, PATH_MAX, "%s/hooks/%d", priv->workdir,\
- version); \
- if (len < 0) { \
- path[0] = 0; \
- } \
- } while (0)
+#define GLUSTERD_GET_HOOKS_DIR(path, version, priv) \
+ do { \
+ int32_t len; \
+ len = snprintf(path, PATH_MAX, "%s/hooks/%d", priv->workdir, version); \
+ if (len < 0) { \
+ path[0] = 0; \
+ } \
+ } while (0)
-#define GLUSTERD_HOOK_VER 1
+#define GLUSTERD_HOOK_VER 1
-#define GD_HOOKS_SPECIFIC_KEY "user.*"
+#define GD_HOOKS_SPECIFIC_KEY "user.*"
typedef enum glusterd_commit_hook_type {
- GD_COMMIT_HOOK_NONE = 0,
- GD_COMMIT_HOOK_PRE,
- GD_COMMIT_HOOK_POST,
- GD_COMMIT_HOOK_MAX
+ GD_COMMIT_HOOK_NONE = 0,
+ GD_COMMIT_HOOK_PRE,
+ GD_COMMIT_HOOK_POST,
+ GD_COMMIT_HOOK_MAX
} glusterd_commit_hook_type_t;
typedef struct hooks_private {
- struct cds_list_head list;
- int waitcount; //debug purposes
- pthread_mutex_t mutex;
- pthread_cond_t cond;
- pthread_t worker;
+ struct cds_list_head list;
+ int waitcount; // debug purposes
+ pthread_mutex_t mutex;
+ pthread_cond_t cond;
+ pthread_t worker;
} glusterd_hooks_private_t;
typedef struct hooks_stub {
- struct cds_list_head all_hooks;
- char *scriptdir;
- glusterd_op_t op;
- dict_t *op_ctx;
+ struct cds_list_head all_hooks;
+ char *scriptdir;
+ glusterd_op_t op;
+ dict_t *op_ctx;
} glusterd_hooks_stub_t;
-
static inline gf_boolean_t
-is_key_glusterd_hooks_friendly (char *key)
+is_key_glusterd_hooks_friendly(char *key)
{
- gf_boolean_t is_friendly = _gf_false;
+ gf_boolean_t is_friendly = _gf_false;
- /* This is very specific to hooks friendly behavior */
- if (fnmatch (GD_HOOKS_SPECIFIC_KEY, key, FNM_NOESCAPE) == 0) {
- gf_msg_debug (THIS->name, 0, "user namespace key %s", key);
- is_friendly = _gf_true;
- }
+ /* This is very specific to hooks friendly behavior */
+ if (fnmatch(GD_HOOKS_SPECIFIC_KEY, key, FNM_NOESCAPE) == 0) {
+ gf_msg_debug(THIS->name, 0, "user namespace key %s", key);
+ is_friendly = _gf_true;
+ }
- return is_friendly;
+ return is_friendly;
}
int
-glusterd_hooks_create_hooks_directory (char *basedir);
+glusterd_hooks_create_hooks_directory(char *basedir);
char *
-glusterd_hooks_get_hooks_cmd_subdir (glusterd_op_t op);
+glusterd_hooks_get_hooks_cmd_subdir(glusterd_op_t op);
int
-glusterd_hooks_run_hooks (char *hooks_path, glusterd_op_t op, dict_t *op_ctx,
- glusterd_commit_hook_type_t type);
+glusterd_hooks_run_hooks(char *hooks_path, glusterd_op_t op, dict_t *op_ctx,
+ glusterd_commit_hook_type_t type);
int
-glusterd_hooks_spawn_worker (xlator_t *this);
+glusterd_hooks_spawn_worker(xlator_t *this);
int
-glusterd_hooks_stub_init (glusterd_hooks_stub_t **stub, char *scriptdir,
- glusterd_op_t op, dict_t *op_ctx);
+glusterd_hooks_stub_init(glusterd_hooks_stub_t **stub, char *scriptdir,
+ glusterd_op_t op, dict_t *op_ctx);
void
-glusterd_hooks_stub_cleanup (glusterd_hooks_stub_t *stub);
+glusterd_hooks_stub_cleanup(glusterd_hooks_stub_t *stub);
int
-glusterd_hooks_post_stub_enqueue (char *scriptdir, glusterd_op_t op,
- dict_t *op_ctx);
+glusterd_hooks_post_stub_enqueue(char *scriptdir, glusterd_op_t op,
+ dict_t *op_ctx);
int
-glusterd_hooks_priv_init (glusterd_hooks_private_t **new);
+glusterd_hooks_priv_init(glusterd_hooks_private_t **new);
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-locks.h b/xlators/mgmt/glusterd/src/glusterd-locks.h
index 226d5c6bd7f..8878a30d0bf 100644
--- a/xlators/mgmt/glusterd/src/glusterd-locks.h
+++ b/xlators/mgmt/glusterd/src/glusterd-locks.h
@@ -11,49 +11,49 @@
#define _GLUSTERD_LOCKS_H_
typedef struct glusterd_mgmt_v3_lock_object_ {
- uuid_t lock_owner;
+ uuid_t lock_owner;
} glusterd_mgmt_v3_lock_obj;
typedef struct glusterd_mgmt_v3_lock_timer_ {
- gf_timer_t *timer;
- xlator_t *xl;
+ gf_timer_t *timer;
+ xlator_t *xl;
} glusterd_mgmt_v3_lock_timer;
typedef struct glusterd_mgmt_v3_lock_valid_entities {
- char *type; /* Entity type like vol, snap */
- gf_boolean_t default_value; /* The default value that *
- * determines if the locks *
- * should be held for that *
- * entity */
+ char *type; /* Entity type like vol, snap */
+ gf_boolean_t default_value; /* The default value that *
+ * determines if the locks *
+ * should be held for that *
+ * entity */
} glusterd_valid_entities;
int32_t
-glusterd_mgmt_v3_lock_init ();
+glusterd_mgmt_v3_lock_init();
void
-glusterd_mgmt_v3_lock_fini ();
+glusterd_mgmt_v3_lock_fini();
int32_t
-glusterd_mgmt_v3_lock_timer_init ();
+glusterd_mgmt_v3_lock_timer_init();
void
-glusterd_mgmt_v3_lock_timer_fini ();
+glusterd_mgmt_v3_lock_timer_fini();
int32_t
-glusterd_get_mgmt_v3_lock_owner (char *volname, uuid_t *uuid);
+glusterd_get_mgmt_v3_lock_owner(char *volname, uuid_t *uuid);
int32_t
-glusterd_mgmt_v3_lock (const char *key, uuid_t uuid, uint32_t *op_errno,
- char *type);
+glusterd_mgmt_v3_lock(const char *key, uuid_t uuid, uint32_t *op_errno,
+ char *type);
int32_t
-glusterd_mgmt_v3_unlock (const char *key, uuid_t uuid, char *type);
+glusterd_mgmt_v3_unlock(const char *key, uuid_t uuid, char *type);
int32_t
-glusterd_multiple_mgmt_v3_lock (dict_t *dict, uuid_t uuid, uint32_t *op_errno);
+glusterd_multiple_mgmt_v3_lock(dict_t *dict, uuid_t uuid, uint32_t *op_errno);
int32_t
-glusterd_multiple_mgmt_v3_unlock (dict_t *dict, uuid_t uuid);
+glusterd_multiple_mgmt_v3_unlock(dict_t *dict, uuid_t uuid);
void
gd_mgmt_v3_unlock_timer_cbk(void *data);
diff --git a/xlators/mgmt/glusterd/src/glusterd-mem-types.h b/xlators/mgmt/glusterd/src/glusterd-mem-types.h
index 33aac2f3dc8..210d0f8658c 100644
--- a/xlators/mgmt/glusterd/src/glusterd-mem-types.h
+++ b/xlators/mgmt/glusterd/src/glusterd-mem-types.h
@@ -14,65 +14,64 @@
#include "mem-types.h"
typedef enum gf_gld_mem_types_ {
- gf_gld_mt_dir_entry_t = gf_common_mt_end + 1,
- gf_gld_mt_volfile_ctx = gf_common_mt_end + 2,
- gf_gld_mt_glusterd_state_t = gf_common_mt_end + 3,
- gf_gld_mt_glusterd_conf_t = gf_common_mt_end + 4,
- gf_gld_mt_locker = gf_common_mt_end + 5,
- gf_gld_mt_string = gf_common_mt_end + 6,
- gf_gld_mt_lock_table = gf_common_mt_end + 7,
- gf_gld_mt_char = gf_common_mt_end + 8,
- gf_gld_mt_glusterd_connection_t = gf_common_mt_end + 9,
- gf_gld_mt_resolve_comp = gf_common_mt_end + 10,
- gf_gld_mt_peerinfo_t = gf_common_mt_end + 11,
- gf_gld_mt_friend_sm_event_t = gf_common_mt_end + 12,
- gf_gld_mt_friend_req_ctx_t = gf_common_mt_end + 13,
- gf_gld_mt_friend_update_ctx_t = gf_common_mt_end + 14,
- gf_gld_mt_op_sm_event_t = gf_common_mt_end + 15,
- gf_gld_mt_op_lock_ctx_t = gf_common_mt_end + 16,
- gf_gld_mt_op_stage_ctx_t = gf_common_mt_end + 17,
- gf_gld_mt_op_commit_ctx_t = gf_common_mt_end + 18,
- gf_gld_mt_mop_stage_req_t = gf_common_mt_end + 19,
- gf_gld_mt_probe_ctx_t = gf_common_mt_end + 20,
- gf_gld_mt_create_volume_ctx_t = gf_common_mt_end + 21,
- gf_gld_mt_start_volume_ctx_t = gf_common_mt_end + 22,
- gf_gld_mt_stop_volume_ctx_t = gf_common_mt_end + 23,
- gf_gld_mt_delete_volume_ctx_t = gf_common_mt_end + 24,
- gf_gld_mt_glusterd_volinfo_t = gf_common_mt_end + 25,
- gf_gld_mt_glusterd_brickinfo_t = gf_common_mt_end + 26,
- gf_gld_mt_peer_hostname_t = gf_common_mt_end + 27,
- gf_gld_mt_ifreq = gf_common_mt_end + 28,
- gf_gld_mt_store_handle_t = gf_common_mt_end + 29,
- gf_gld_mt_store_iter_t = gf_common_mt_end + 30,
- gf_gld_mt_defrag_info = gf_common_mt_end + 31,
- gf_gld_mt_log_filename_ctx_t = gf_common_mt_end + 32,
- gf_gld_mt_log_locate_ctx_t = gf_common_mt_end + 33,
- gf_gld_mt_log_rotate_ctx_t = gf_common_mt_end + 34,
- gf_gld_mt_peerctx_t = gf_common_mt_end + 35,
- gf_gld_mt_sm_tr_log_t = gf_common_mt_end + 36,
- gf_gld_mt_pending_node_t = gf_common_mt_end + 37,
- gf_gld_mt_brick_rsp_ctx_t = gf_common_mt_end + 38,
- gf_gld_mt_mop_brick_req_t = gf_common_mt_end + 39,
- gf_gld_mt_op_allack_ctx_t = gf_common_mt_end + 40,
- gf_gld_mt_linearr = gf_common_mt_end + 41,
- gf_gld_mt_linebuf = gf_common_mt_end + 42,
- gf_gld_mt_mount_pattern = gf_common_mt_end + 43,
- gf_gld_mt_mount_comp_container = gf_common_mt_end + 44,
- gf_gld_mt_mount_component = gf_common_mt_end + 45,
- gf_gld_mt_mount_spec = gf_common_mt_end + 46,
- gf_gld_mt_georep_meet_spec = gf_common_mt_end + 47,
- gf_gld_mt_nodesrv_t = gf_common_mt_end + 48,
- gf_gld_mt_charptr = gf_common_mt_end + 49,
- gf_gld_mt_hooks_stub_t = gf_common_mt_end + 50,
- gf_gld_mt_hooks_priv_t = gf_common_mt_end + 51,
- gf_gld_mt_mop_commit_req_t = gf_common_mt_end + 52,
- gf_gld_mt_int = gf_common_mt_end + 53,
- gf_gld_mt_snap_t = gf_common_mt_end + 54,
- gf_gld_mt_missed_snapinfo_t = gf_common_mt_end + 55,
- gf_gld_mt_snap_create_args_t = gf_common_mt_end + 56,
- gf_gld_mt_local_peers_t = gf_common_mt_end + 57,
- gf_gld_mt_glusterd_brick_proc_t = gf_common_mt_end + 58,
- gf_gld_mt_end = gf_common_mt_end + 59,
+ gf_gld_mt_dir_entry_t = gf_common_mt_end + 1,
+ gf_gld_mt_volfile_ctx = gf_common_mt_end + 2,
+ gf_gld_mt_glusterd_state_t = gf_common_mt_end + 3,
+ gf_gld_mt_glusterd_conf_t = gf_common_mt_end + 4,
+ gf_gld_mt_locker = gf_common_mt_end + 5,
+ gf_gld_mt_string = gf_common_mt_end + 6,
+ gf_gld_mt_lock_table = gf_common_mt_end + 7,
+ gf_gld_mt_char = gf_common_mt_end + 8,
+ gf_gld_mt_glusterd_connection_t = gf_common_mt_end + 9,
+ gf_gld_mt_resolve_comp = gf_common_mt_end + 10,
+ gf_gld_mt_peerinfo_t = gf_common_mt_end + 11,
+ gf_gld_mt_friend_sm_event_t = gf_common_mt_end + 12,
+ gf_gld_mt_friend_req_ctx_t = gf_common_mt_end + 13,
+ gf_gld_mt_friend_update_ctx_t = gf_common_mt_end + 14,
+ gf_gld_mt_op_sm_event_t = gf_common_mt_end + 15,
+ gf_gld_mt_op_lock_ctx_t = gf_common_mt_end + 16,
+ gf_gld_mt_op_stage_ctx_t = gf_common_mt_end + 17,
+ gf_gld_mt_op_commit_ctx_t = gf_common_mt_end + 18,
+ gf_gld_mt_mop_stage_req_t = gf_common_mt_end + 19,
+ gf_gld_mt_probe_ctx_t = gf_common_mt_end + 20,
+ gf_gld_mt_create_volume_ctx_t = gf_common_mt_end + 21,
+ gf_gld_mt_start_volume_ctx_t = gf_common_mt_end + 22,
+ gf_gld_mt_stop_volume_ctx_t = gf_common_mt_end + 23,
+ gf_gld_mt_delete_volume_ctx_t = gf_common_mt_end + 24,
+ gf_gld_mt_glusterd_volinfo_t = gf_common_mt_end + 25,
+ gf_gld_mt_glusterd_brickinfo_t = gf_common_mt_end + 26,
+ gf_gld_mt_peer_hostname_t = gf_common_mt_end + 27,
+ gf_gld_mt_ifreq = gf_common_mt_end + 28,
+ gf_gld_mt_store_handle_t = gf_common_mt_end + 29,
+ gf_gld_mt_store_iter_t = gf_common_mt_end + 30,
+ gf_gld_mt_defrag_info = gf_common_mt_end + 31,
+ gf_gld_mt_log_filename_ctx_t = gf_common_mt_end + 32,
+ gf_gld_mt_log_locate_ctx_t = gf_common_mt_end + 33,
+ gf_gld_mt_log_rotate_ctx_t = gf_common_mt_end + 34,
+ gf_gld_mt_peerctx_t = gf_common_mt_end + 35,
+ gf_gld_mt_sm_tr_log_t = gf_common_mt_end + 36,
+ gf_gld_mt_pending_node_t = gf_common_mt_end + 37,
+ gf_gld_mt_brick_rsp_ctx_t = gf_common_mt_end + 38,
+ gf_gld_mt_mop_brick_req_t = gf_common_mt_end + 39,
+ gf_gld_mt_op_allack_ctx_t = gf_common_mt_end + 40,
+ gf_gld_mt_linearr = gf_common_mt_end + 41,
+ gf_gld_mt_linebuf = gf_common_mt_end + 42,
+ gf_gld_mt_mount_pattern = gf_common_mt_end + 43,
+ gf_gld_mt_mount_comp_container = gf_common_mt_end + 44,
+ gf_gld_mt_mount_component = gf_common_mt_end + 45,
+ gf_gld_mt_mount_spec = gf_common_mt_end + 46,
+ gf_gld_mt_georep_meet_spec = gf_common_mt_end + 47,
+ gf_gld_mt_nodesrv_t = gf_common_mt_end + 48,
+ gf_gld_mt_charptr = gf_common_mt_end + 49,
+ gf_gld_mt_hooks_stub_t = gf_common_mt_end + 50,
+ gf_gld_mt_hooks_priv_t = gf_common_mt_end + 51,
+ gf_gld_mt_mop_commit_req_t = gf_common_mt_end + 52,
+ gf_gld_mt_int = gf_common_mt_end + 53,
+ gf_gld_mt_snap_t = gf_common_mt_end + 54,
+ gf_gld_mt_missed_snapinfo_t = gf_common_mt_end + 55,
+ gf_gld_mt_snap_create_args_t = gf_common_mt_end + 56,
+ gf_gld_mt_local_peers_t = gf_common_mt_end + 57,
+ gf_gld_mt_glusterd_brick_proc_t = gf_common_mt_end + 58,
+ gf_gld_mt_end = gf_common_mt_end + 59,
} gf_gld_mem_types_t;
#endif
-
diff --git a/xlators/mgmt/glusterd/src/glusterd-messages.h b/xlators/mgmt/glusterd/src/glusterd-messages.h
index 29b97570630..41fedf9e288 100644
--- a/xlators/mgmt/glusterd/src/glusterd-messages.h
+++ b/xlators/mgmt/glusterd/src/glusterd-messages.h
@@ -23,621 +23,281 @@
* glfs-message-id.h.
*/
-GLFS_MSGID(GLUSTERD,
- GD_MSG_SERVER_QUORUM_NOT_MET,
- GD_MSG_SERVER_QUORUM_LOST_STOPPING_BRICKS,
- GD_MSG_SERVER_QUORUM_MET_STARTING_BRICKS,
- GD_MSG_PEER_DISCONNECTED,
- GD_MSG_BRICK_DISCONNECTED,
- GD_MSG_NODE_DISCONNECTED,
- GD_MSG_REBALANCE_DISCONNECTED,
- GD_MSG_VOL_CLEANUP_FAIL,
- GD_MSG_VOL_VERS_MISMATCH,
- GD_MSG_CKSUM_VERS_MISMATCH,
- GD_MSG_QUOTA_CONFIG_VERS_MISMATCH,
- GD_MSG_QUOTA_CONFIG_CKSUM_MISMATCH,
- GD_MSG_BRICK_STOP_FAIL,
- GD_MSG_SVC_KILL_FAIL,
- GD_MSG_PID_KILL_FAIL,
- GD_MSG_REBAL_NO_SOCK_FILE,
- GD_MSG_UNIX_OP_BUILD_FAIL,
- GD_MSG_RPC_CREATE_FAIL,
- GD_MSG_FAIL_DEFAULT_OPT_SET,
- GD_MSG_CLUSTER_UNLOCK_FAILED,
- GD_MSG_NO_MEMORY,
- GD_MSG_UNSUPPORTED_VERSION,
- GD_MSG_COMMAND_NOT_FOUND,
- GD_MSG_SNAPSHOT_OP_FAILED,
- GD_MSG_INVALID_ENTRY,
- GD_MSG_VOL_NOT_FOUND,
- GD_MSG_REG_COMPILE_FAILED,
- GD_MSG_FILE_OP_FAILED,
- GD_MSG_SNAP_CREATION_FAIL,
- GD_MSG_VOL_OP_FAILED,
- GD_MSG_CREATE_DIR_FAILED,
- GD_MSG_DIR_OP_FAILED,
- GD_MSG_VOL_STOP_FAILED,
- GD_MSG_NO_CLI_RESP,
- GD_MSG_LOCK_INIT_FAILED,
- GD_MSG_SNAP_LIST_GET_FAIL,
- GD_MSG_UNOUNT_FAILED,
- GD_MSG_LOCK_DESTROY_FAILED,
- GD_MSG_SNAP_CLEANUP_FAIL,
- GD_MSG_SNAP_ACTIVATE_FAIL,
- GD_MSG_SNAP_DEACTIVATE_FAIL,
- GD_MSG_SNAP_RESTORE_FAIL,
- GD_MSG_SNAP_REMOVE_FAIL,
- GD_MSG_SNAP_CONFIG_FAIL,
- GD_MSG_SNAP_STATUS_FAIL,
- GD_MSG_SNAP_INIT_FAIL,
- GD_MSG_VOLINFO_SET_FAIL,
- GD_MSG_VOLINFO_GET_FAIL,
- GD_MSG_BRICK_CREATION_FAIL,
- GD_MSG_BRICK_GET_INFO_FAIL,
- GD_MSG_BRICK_NEW_INFO_FAIL,
- GD_MSG_LVS_FAIL,
- GD_MSG_SETXATTR_FAIL,
- GD_MSG_UMOUNTING_SNAP_BRICK,
- GD_MSG_OP_UNSUPPORTED,
- GD_MSG_SNAP_NOT_FOUND,
- GD_MSG_FS_LABEL_UPDATE_FAIL,
- GD_MSG_LVM_MOUNT_FAILED,
- GD_MSG_DICT_SET_FAILED,
- GD_MSG_CANONICALIZE_FAIL,
- GD_MSG_DICT_GET_FAILED,
- GD_MSG_SNAP_INFO_FAIL,
- GD_MSG_SNAP_VOL_CONFIG_FAIL,
- GD_MSG_SNAP_OBJECT_STORE_FAIL,
- GD_MSG_DICT_UNSERIALIZE_FAIL,
- GD_MSG_SNAP_RESTORE_REVERT_FAIL,
- GD_MSG_SNAP_LIST_SET_FAIL,
- GD_MSG_VOLFILE_CREATE_FAIL,
- GD_MSG_VOLINFO_REMOVE_FAIL,
- GD_MSG_VOL_DELETE_FAIL,
- GD_MSG_SNAPSHOT_PENDING,
- GD_MSG_BRICK_PATH_UNMOUNTED,
- GD_MSG_BRICK_ADD_FAIL,
- GD_MSG_BRICK_SET_INFO_FAIL,
- GD_MSG_LVCREATE_FAIL,
- GD_MSG_VG_GET_FAIL,
- GD_MSG_TPOOL_GET_FAIL,
- GD_MSG_LVM_REMOVE_FAILED,
- GD_MSG_MISSEDSNAP_INFO_SET_FAIL,
- GD_MSG_BRK_MOUNTOPTS_FAIL,
- GD_MSG_MISSED_SNAP_LIST_STORE_FAIL,
- GD_MSG_INVALID_MISSED_SNAP_ENTRY,
- GD_MSG_MISSED_SNAP_GET_FAIL,
- GD_MSG_MISSED_SNAP_CREATE_FAIL,
- GD_MSG_DUP_ENTRY,
- GD_MSG_MISSED_SNAP_STATUS_DONE,
- GD_MSG_NO_EXEC_PERMS,
- GD_MSG_GLOBAL_OP_VERSION_SET_FAIL,
- GD_MSG_HARD_LIMIT_SET_FAIL,
- GD_MSG_OP_SUCCESS,
- GD_MSG_STORE_FAIL,
- GD_MSG_GLOBAL_OP_VERSION_GET_FAIL,
- GD_MSG_GEOREP_GET_FAILED,
- GD_MSG_GLUSTERD_UMOUNT_FAIL,
- GD_MSG_QUORUM_CHECK_FAIL,
- GD_MSG_QUORUM_COUNT_IGNORED,
- GD_MSG_SNAP_MOUNT_FAIL,
- GD_MSG_RSP_DICT_USE_FAIL,
- GD_MSG_SNAP_IMPORT_FAIL,
- GD_MSG_SNAP_CONFLICT,
- GD_MSG_MISSED_SNAP_DELETE,
- GD_MSG_QUOTA_CONFIG_IMPORT_FAIL,
- GD_MSG_SNAPDIR_CREATE_FAIL,
- GD_MSG_MISSED_SNAP_PRESENT,
- GD_MSG_UUID_NULL,
- GD_MSG_TSTAMP_SET_FAIL,
- GD_MSG_RESP_AGGR_FAIL,
- GD_MSG_DICT_EMPTY,
- GD_MSG_DICT_CREATE_FAIL,
- GD_MSG_SNAPD_STOP_FAIL,
- GD_MSG_SOFT_LIMIT_REACHED,
- GD_MSG_SNAPD_START_FAIL,
- GD_MSG_SNAPD_CREATE_FAIL,
- GD_MSG_SNAPD_INIT_FAIL,
- GD_MSG_MGMTV3_OP_FAIL,
- GD_MSG_MGMTV3_PAYLOAD_BUILD_FAIL,
- GD_MSG_MGMTV3_UNLOCK_FAIL,
- GD_MSG_MGMTV3_LOCK_GET_FAIL,
- GD_MSG_MGMTV3_LOCKDOWN_FAIL,
- GD_MSG_POST_VALIDATION_FAIL,
- GD_MSG_PRE_VALIDATION_FAIL,
- GD_MSG_COMMIT_OP_FAIL,
- GD_MSG_PEER_LIST_CREATE_FAIL,
- GD_MSG_BRICK_OP_FAIL,
- GD_MSG_OPINFO_SET_FAIL,
- GD_MSG_OP_EVENT_UNLOCK_FAIL,
- GD_MSG_MGMTV3_OP_RESP_FAIL,
- GD_MSG_PEER_NOT_FOUND,
- GD_MSG_REQ_DECODE_FAIL,
- GD_MSG_DICT_SERL_LENGTH_GET_FAIL,
- GD_MSG_ALREADY_STOPPED,
- GD_MSG_PRE_VALD_RESP_FAIL,
- GD_MSG_SVC_GET_FAIL,
- GD_MSG_VOLFILE_NOT_FOUND,
- GD_MSG_OP_EVENT_LOCK_FAIL,
- GD_MSG_NON_STRIPE_VOL,
- GD_MSG_SNAPD_OBJ_GET_FAIL,
- GD_MSG_QUOTA_DISABLED,
- GD_MSG_CACHE_MINMAX_SIZE_INVALID,
- GD_MSG_QUOTA_GET_STAT_FAIL,
- GD_MSG_SUBVOLUMES_EXCEED,
- GD_MSG_BRICK_ADD,
- GD_MSG_BRICK_REMOVE,
- GD_MSG_CREATE_KEY_FAIL,
- GD_MSG_MULTIPLE_LOCK_ACQUIRE_FAIL,
- GD_MSG_MULTIPLE_LOCK_RELEASE_FAIL,
- GD_MSG_RESP_FROM_UNKNOWN_PEER,
- GD_MSG_BRICK_MOUNDIRS_AGGR_FAIL,
- GD_MSG_GFID_VALIDATE_SET_FAIL,
- GD_MSG_PEER_LOCK_FAIL,
- GD_MSG_PEER_UNLOCK_FAIL,
- GD_MSG_MGMT_OP_FAIL,
- GD_MSG_TRANS_OPINFO_CLEAR_FAIL,
- GD_MSG_GLUSTERD_LOCK_FAIL,
- GD_MSG_TRANS_OPINFO_SET_FAIL,
- GD_MSG_TRANS_IDGEN_FAIL,
- GD_MSG_RPC_FAILURE,
- GD_MSG_OP_VERS_ADJUST_FAIL,
- GD_MSG_SNAP_DEVICE_NAME_GET_FAIL,
- GD_MSG_SNAP_STATUS_NOT_PENDING,
- GD_MSG_MGMT_PGM_SET_FAIL,
- GD_MSG_EVENT_INJECT_FAIL,
- GD_MSG_VERS_INFO,
- GD_MSG_VOL_INFO_REQ_RECVD,
- GD_MSG_VERS_GET_FAIL,
- GD_MSG_EVENT_NEW_GET_FAIL,
- GD_MSG_RPC_LAYER_ERROR,
- GD_MSG_NO_HANDSHAKE_ACK,
- GD_MSG_OP_VERSION_MISMATCH,
- GD_MSG_HANDSHAKE_REQ_REJECTED,
- GD_MSG_UNKNOWN_MODE,
- GD_MSG_DEFRAG_STATUS_UPDATED,
- GD_MSG_NO_FLAG_SET,
- GD_MSG_VERSION_UNSUPPORTED,
- GD_MSG_UUID_SET_FAIL,
- GD_MSG_MOUNT_REQ_FAIL,
- GD_MSG_GLUSTERD_GLOBAL_INFO_STORE_FAIL,
- GD_MSG_OP_VERS_STORE_FAIL,
- GD_MSG_SNAP_AUTOMIC_UPDATE_FAIL,
- GD_MSG_SNAPINFO_WRITE_FAIL,
- GD_MSG_SNAPINFO_CREATE_FAIL,
- GD_MSG_SNAPD_INFO_STORE_FAIL,
- GD_MSG_BRK_MNTPATH_MOUNT_FAIL,
- GD_MSG_BRK_MNTPATH_GET_FAIL,
- GD_MSG_SNAP_BRK_MNT_RECREATE_FAIL,
- GD_MSG_SNAP_RESOLVE_BRICK_FAIL,
- GD_MSG_RESOLVE_BRICK_FAIL,
- GD_MSG_BRK_MNT_RECREATE_FAIL,
- GD_MSG_TMP_FILE_UNLINK_FAIL,
- GD_MSG_VOL_VALS_WRITE_FAIL,
- GD_MSG_STORE_HANDLE_GET_FAIL,
- GD_MSG_STORE_HANDLE_WRITE_FAIL,
- GD_MSG_MISSED_SNAP_LIST_STORE_HANDLE_GET_FAIL,
- GD_MSG_MISSED_SNAP_LIST_EMPTY,
- GD_MSG_SNAP_VOL_RETRIEVE_FAIL,
- GD_MSG_SNAPSHOT_UPDATE_FAIL,
- GD_MSG_SNAPD_PORT_STORE_FAIL,
- GD_MSG_CKSUM_STORE_FAIL,
- GD_MSG_STORE_HANDLE_CREATE_FAIL,
- GD_MSG_HANDLE_NULL,
- GD_MSG_VOL_RESTORE_FAIL,
- GD_MSG_NAME_TOO_LONG,
- GD_MSG_UUID_PARSE_FAIL,
- GD_MSG_UNKNOWN_KEY,
- GD_MSG_STORE_ITER_DESTROY_FAIL,
- GD_MSG_STORE_ITER_GET_FAIL,
- GD_MSG_VOLINFO_UPDATE_FAIL,
- GD_MSG_PARSE_BRICKINFO_FAIL,
- GD_MSG_VERS_STORE_FAIL,
- GD_MSG_HEADER_ADD_FAIL,
- GD_MSG_QUOTA_CONF_WRITE_FAIL,
- GD_MSG_QUOTA_CONF_CORRUPT,
- GD_MSG_FORK_FAIL,
- GD_MSG_CKSUM_COMPUTE_FAIL,
- GD_MSG_VERS_CKSUM_STORE_FAIL,
- GD_MSG_GETXATTR_FAIL,
- GD_MSG_CONVERSION_FAILED,
- GD_MSG_VOL_NOT_DISTRIBUTE,
- GD_MSG_VOL_STOPPED,
- GD_MSG_OPCTX_GET_FAIL,
- GD_MSG_TASKID_GEN_FAIL,
- GD_MSG_REBALANCE_ID_MISSING,
- GD_MSG_NO_REBALANCE_PFX_IN_VOLNAME,
- GD_MSG_DEFRAG_STATUS_UPDATE_FAIL,
- GD_MSG_UUID_GEN_STORE_FAIL,
- GD_MSG_UUID_STORE_FAIL,
- GD_MSG_NO_INIT,
- GD_MSG_MODULE_NOT_INSTALLED,
- GD_MSG_MODULE_NOT_WORKING,
- GD_MSG_WRITE_ACCESS_GRANT_FAIL,
- GD_MSG_DIRPATH_TOO_LONG,
- GD_MSG_LOGGROUP_INVALID,
- GD_MSG_DIR_PERM_LIBERAL,
- GD_MSG_DIR_PERM_STRICT,
- GD_MSG_MOUNT_SPEC_INSTALL_FAIL,
- GD_MSG_GLUSTERD_SOCK_LISTENER_START_FAIL,
- GD_MSG_DIR_NOT_FOUND,
- GD_MSG_FAILED_INIT_SHDSVC,
- GD_MSG_FAILED_INIT_NFSSVC,
- GD_MSG_FAILED_INIT_QUOTASVC,
- GD_MSG_RPC_INIT_FAIL,
- GD_MSG_RPCSVC_REG_NOTIFY_RETURNED,
- GD_MSG_RPC_TRANSPORT_COUNT_GET_FAIL,
- GD_MSG_RPC_LISTENER_CREATE_FAIL,
- GD_MSG_OP_VERS_RESTORE_FAIL,
- GD_MSG_SELF_HEALD_DISABLED,
- GD_MSG_PRIV_NULL,
- GD_MSG_GSYNC_VALIDATION_FAIL,
- GD_MSG_SLAVE_CONFPATH_DETAILS_FETCH_FAIL,
- GD_MSG_OP_NOT_PERMITTED_AC_REQD,
- GD_MSG_OP_NOT_PERMITTED,
- GD_MSG_REBALANCE_START_FAIL,
- GD_MSG_NFS_RECONF_FAIL,
- GD_MSG_REMOVE_BRICK_ID_SET_FAIL,
- GD_MSG_BRICK_MOUNTDIR_GET_FAIL,
- GD_MSG_BRICK_NOT_FOUND,
- GD_MSG_BRKPATH_TOO_LONG,
- GD_MSG_CLRLOCKS_CLNT_UMOUNT_FAIL,
- GD_MSG_CLRLOCKS_CLNT_MOUNT_FAIL,
- GD_MSG_CLRLOCKS_MOUNTDIR_CREATE_FAIL,
- GD_MSG_BRK_PORT_NUM_GET_FAIL,
- GD_MSG_BRK_STATEDUMP_FAIL,
- GD_MSG_VOL_GRAPH_CHANGE_NOTIFY_FAIL,
- GD_MSG_INVALID_VG,
- GD_MSG_GLUSTERD_OP_FAILED,
- GD_MSG_HOSTNAME_ADD_TO_PEERLIST_FAIL,
- GD_MSG_STALE_PEERINFO_REMOVE_FAIL,
- GD_MSG_TRANS_ID_GET_FAIL,
- GD_MSG_RES_DECODE_FAIL,
- GD_MSG_VOL_ALREADY_EXIST,
- GD_MSG_BAD_BRKORDER,
- GD_MSG_BAD_BRKORDER_CHECK_FAIL,
- GD_MSG_BRICK_SELECT_FAIL,
- GD_MSG_NO_LOCK_RESP_FROM_PEER,
- GD_MSG_MGMTV3_LOCK_FROM_UUID_REJCT,
- GD_MSG_STAGE_FROM_UUID_REJCT,
- GD_MSG_UNLOCK_FROM_UUID_REJCT,
- GD_MSG_MGMTV3_UNLOCK_FROM_UUID_REJCT,
- GD_MSG_COMMIT_FROM_UUID_REJCT,
- GD_MSG_VOL_NOT_STARTED,
- GD_MSG_VOL_NOT_REPLICA,
- GD_MSG_VOL_NOT_DISPERSE,
- GD_MSG_OLD_REMOVE_BRICK_EXISTS,
- GD_MSG_USE_THE_FORCE,
- GD_MSG_OIP,
- GD_MSG_OIP_RETRY_LATER,
- GD_MSG_GSYNC_RESTART_FAIL,
- GD_MSG_LOCK_FROM_UUID_REJCT,
- GD_MSG_BRICK_OP_PAYLOAD_BUILD_FAIL,
- GD_MSG_HOSTNAME_RESOLVE_FAIL,
- GD_MSG_COUNT_VALIDATE_FAILED,
- GD_MSG_SPAWNING_CHILD_FAILED,
- GD_MSG_READ_CHILD_DATA_FAILED,
- GD_MSG_DEFAULT_TEMP_CONFIG,
- GD_MSG_PIDFILE_CREATE_FAILED,
- GD_MSG_GSYNCD_SPAWN_FAILED,
- GD_MSG_SUBOP_NOT_FOUND,
- GD_MSG_RESERVED_OPTION,
- GD_MSG_GLUSTERD_PRIV_NOT_FOUND,
- GD_MSG_SLAVEINFO_FETCH_ERROR,
- GD_MSG_VALIDATE_FAILED,
- GD_MSG_INVOKE_ERROR,
- GD_MSG_SESSION_CREATE_ERROR,
- GD_MSG_STOP_FORCE,
- GD_MSG_GET_CONFIG_INFO_FAILED,
- GD_MSG_STAT_FILE_READ_FAILED,
- GD_MSG_CONF_PATH_ASSIGN_FAILED,
- GD_MSG_SESSION_INACTIVE,
- GD_MSG_PIDFILE_NOT_FOUND,
- GD_MSG_PEER_CMD_ERROR,
- GD_MSG_SRC_FILE_ERROR,
- GD_MSG_GET_STATEFILE_NAME_FAILED,
- GD_MSG_STATUS_NULL,
- GD_MSG_STATUSFILE_CREATE_FAILED,
- GD_MSG_SLAVE_URL_INVALID,
- GD_MSG_INVALID_SLAVE,
- GD_MSG_READ_ERROR,
- GD_MSG_ARG_FETCH_ERROR,
- GD_MSG_REG_FILE_MISSING,
- GD_MSG_STATEFILE_NAME_NOT_FOUND,
- GD_MSG_GEO_REP_START_FAILED,
- GD_MSG_GSYNCD_ERROR,
- GD_MSG_UPDATE_STATEFILE_FAILED,
- GD_MSG_STATUS_UPDATE_FAILED,
- GD_MSG_GSYNCD_OP_SET_FAILED,
- GD_MSG_BUFFER_EMPTY,
- GD_MSG_CONFIG_INFO,
- GD_MSG_FETCH_CONFIG_VAL_FAILED,
- GD_MSG_GSYNCD_PARSE_ERROR,
- GD_MSG_SESSION_ALREADY_EXIST,
- GD_MSG_FORCE_CREATE_SESSION,
- GD_MSG_GET_KEY_FAILED,
- GD_MSG_SESSION_DEL_FAILED,
- GD_MSG_CMD_EXEC_FAIL,
- GD_MSG_STRDUP_FAILED,
- GD_MSG_UNABLE_TO_END,
- GD_MSG_PAUSE_FAILED,
- GD_MSG_NORMALIZE_URL_FAIL,
- GD_MSG_MODULE_ERROR,
- GD_MSG_SLAVEINFO_STORE_ERROR,
- GD_MSG_MARKER_START_FAIL,
- GD_MSG_RESUME_FAILED,
- GD_MSG_GLUSTERFS_START_FAIL,
- GD_MSG_GLUSTERFS_STOP_FAIL,
- GD_MSG_RBOP_STATE_STORE_FAIL,
- GD_MSG_PUMP_XLATOR_DISABLED,
- GD_MSG_ABORT_OP_FAIL,
- GD_MSG_PAUSE_OP_FAIL,
- GD_MSG_GLUSTER_SERVICE_START_FAIL,
- GD_MSG_HANDSHAKE_FAILED,
- GD_MSG_CLI_REQ_EMPTY,
- GD_MSG_PEER_ADD_FAIL,
- GD_MSG_SYNC_FROM_LOCALHOST_UNALLOWED,
- GD_MSG_UUIDS_SAME_RETRY,
- GD_MSG_TSP_ALREADY_FORMED,
- GD_MSG_VOLS_ALREADY_PRESENT,
- GD_MSG_REQ_CTX_CREATE_FAIL,
- GD_MSG_PEER_INFO_UPDATE_FAIL,
- GD_MSG_PEERINFO_CREATE_FAIL,
- GD_MSG_REQ_FROM_UNKNOWN_PEER,
- GD_MSG_STATUS_REPLY_STRING_CREATE_FAIL,
- GD_MSG_TOKENIZE_FAIL,
- GD_MSG_LAZY_UMOUNT_FAIL,
- GD_MSG_NFS_SERVER_START_FAIL,
- GD_MSG_GLUSTER_SERVICES_STOP_FAIL,
- GD_MSG_BRK_CLEANUP_FAIL,
- GD_MSG_RB_ALREADY_STARTED,
- GD_MSG_RB_BRICKINFO_GET_FAIL,
- GD_MSG_BAD_FORMAT,
- GD_MSG_RB_CMD_FAIL,
- GD_MSG_RB_NOT_STARTED_OR_PAUSED,
- GD_MSG_RB_NOT_STARTED,
- GD_MSG_RB_PAUSED_ALREADY,
- GD_MSG_NO_FREE_PORTS,
- GD_MSG_EVENT_STATE_TRANSITION_FAIL,
- GD_MSG_HANDLER_RETURNED,
- GD_MSG_SNAP_COMPARE_CONFLICT,
- GD_MSG_PEER_DETACH_CLEANUP_FAIL,
- GD_MSG_STALE_VOL_REMOVE_FAIL,
- GD_MSG_AC_ERROR,
- GD_MSG_LOCK_FAIL,
- GD_MSG_MGMTV3_LOCK_REQ_SEND_FAIL,
- GD_MSG_GLUSTERD_UNLOCK_FAIL,
- GD_MSG_RBOP_START_FAIL,
- GD_MSG_UNKNOWN_RESPONSE,
- GD_MSG_COMMIT_REQ_SEND_FAIL,
- GD_MSG_OPCTX_UPDATE_FAIL,
- GD_MSG_OPCTX_NULL,
- GD_MSG_DICT_COPY_FAIL,
- GD_MSG_SHD_STATUS_SET_FAIL,
- GD_MSG_REPLICA_INDEX_GET_FAIL,
- GD_MSG_NFS_SERVER_NOT_RUNNING,
- GD_MSG_STAGE_REQ_SEND_FAIL,
- GD_MSG_LOCK_REQ_SEND_FAIL,
- GD_MSG_VOLNAMES_GET_FAIL,
- GD_MSG_NO_TASK_ID,
- GD_MSG_ADD_REMOVE_BRICK_FAIL,
- GD_MSG_SVC_RESTART_FAIL,
- GD_MSG_VOL_SET_FAIL,
- GD_MSG_QUOTAD_NOT_RUNNING,
- GD_MSG_XLATOR_COUNT_GET_FAIL,
- GD_MSG_TRANS_OPINFO_GET_FAIL,
- GD_MSG_TRANS_ID_INVALID,
- GD_MSG_NO_OPTIONS_GIVEN,
- GD_MSG_SNAPD_NOT_RUNNING,
- GD_MSG_ADD_ADDRESS_TO_PEER_FAIL,
- GD_MSG_PEER_ADDRESS_GET_FAIL,
- GD_MSG_GETADDRINFO_FAIL,
- GD_MSG_PEERINFO_DELETE_FAIL,
- GD_MSG_KEY_NULL,
- GD_MSG_SPAWN_SVCS_FAIL,
- GD_MSG_DICT_ITER_FAIL,
- GD_MSG_TASK_STATUS_UPDATE_FAIL,
- GD_MSG_VOL_ID_MISMATCH,
- GD_MSG_STR_TO_BOOL_FAIL,
- GD_MSG_RB_MNT_BRICKS_MISMATCH,
- GD_MSG_RB_SRC_BRICKS_MISMATCH,
- GD_MSG_MNTENTRY_GET_FAIL,
- GD_MSG_INODE_SIZE_GET_FAIL,
- GD_MSG_NO_STATEFILE_ENTRY,
- GD_MSG_PMAP_UNSET_FAIL,
- GD_MSG_GLOBAL_OPT_IMPORT_FAIL,
- GD_MSD_BRICK_DISCONNECT_FAIL,
- GD_MSG_SNAP_DETAILS_IMPORT_FAIL,
- GD_MSG_BRICKINFO_CREATE_FAIL,
- GD_MSG_QUOTA_CKSUM_VER_STORE_FAIL,
- GD_MSG_CKSUM_GET_FAIL,
- GD_MSG_BRICKPATH_ROOT_GET_FAIL,
- GD_MSG_HOSTNAME_TO_UUID_FAIL,
- GD_MSG_REPLY_SUBMIT_FAIL,
- GD_MSG_SERIALIZE_MSG_FAIL,
- GD_MSG_ENCODE_FAIL,
- GD_MSG_RB_DST_BRICKS_MISMATCH,
- GD_MSG_XLATOR_VOLOPT_DYNLOAD_ERROR,
- GD_MSG_VOLNAME_NOTFOUND_IN_DICT,
- GD_MSG_FLAGS_NOTFOUND_IN_DICT,
- GD_MSG_HOSTNAME_NOTFOUND_IN_DICT,
- GD_MSG_PORT_NOTFOUND_IN_DICT,
- GD_MSG_CMDSTR_NOTFOUND_IN_DICT,
- GD_MSG_SNAP_OBJ_NEW_FAIL,
- GD_MSG_SNAP_BACKEND_MAKE_FAIL,
- GD_MSG_SNAP_CLONE_FAILED,
- GD_MSG_SNAP_CLONE_PREVAL_FAILED,
- GD_MSG_SNAP_CLONE_POSTVAL_FAILED,
- GD_MSG_VOLINFO_STORE_FAIL,
- GD_MSG_NEW_FRIEND_SM_EVENT_GET_FAIL,
- GD_MSG_VOL_TYPE_CHANGING_INFO,
- GD_MSG_BRKPATH_MNTPNT_MISMATCH,
- GD_MSG_TASKS_COUNT_MISMATCH,
- GD_MSG_WRONG_OPTS_SETTING,
- GD_MSG_PATH_ALREADY_PART_OF_VOL,
- GD_MSG_BRICK_VALIDATE_FAIL,
- GD_MSG_READIN_FILE_FAILED,
- GD_MSG_IMPORT_PRDICT_DICT,
- GD_MSG_VOL_OPTS_IMPORT_FAIL,
- GD_MSG_BRICK_IMPORT_FAIL,
- GD_MSG_VOLINFO_IMPORT_FAIL,
- GD_MSG_BRICK_ID_GEN_FAILED,
- GD_MSG_GET_STATUS_DATA_FAIL,
- GD_MSG_BITROT_NOT_RUNNING,
- GD_MSG_SCRUBBER_NOT_RUNNING,
- GD_MSG_SRC_BRICK_PORT_UNAVAIL,
- GD_MSG_BITD_INIT_FAIL,
- GD_MSG_SCRUB_INIT_FAIL,
- GD_MSG_VAR_RUN_DIR_INIT_FAIL,
- GD_MSG_VAR_RUN_DIR_FIND_FAIL,
- GD_MSG_SCRUBSVC_RECONF_FAIL,
- GD_MSG_BITDSVC_RECONF_FAIL,
- GD_MSG_NFS_GNS_START_FAIL,
- GD_MSG_NFS_GNS_SETUP_FAIL,
- GD_MSG_UNRECOGNIZED_SVC_MNGR,
- GD_MSG_NFS_GNS_OP_HANDLE_FAIL,
- GD_MSG_EXPORT_FILE_CREATE_FAIL,
- GD_MSG_NFS_GNS_HOST_FOUND,
- GD_MSG_REBALANCE_CMD_IN_TIER_VOL,
- GD_MSG_INCOMPATIBLE_VALUE,
- GD_MSG_GENERATED_UUID,
- GD_MSG_FILE_DESC_LIMIT_SET,
- GD_MSG_CURR_WORK_DIR_INFO,
- GD_MSG_STRIPE_COUNT_CHANGE_INFO,
- GD_MSG_REPLICA_COUNT_CHANGE_INFO,
- GD_MSG_ADD_BRICK_REQ_RECVD,
- GD_MSG_VOL_ALREADY_TIER,
- GD_MSG_REM_BRICK_REQ_RECVD,
- GD_MSG_VOL_NOT_TIER,
- GD_MSG_LOG_ROTATE_REQ_RECVD,
- GD_MSG_CLI_REQ_RECVD,
- GD_MSG_GET_VOL_REQ_RCVD,
- GD_MSG_VOL_SYNC_REQ_RCVD,
- GD_MSG_PROBE_RCVD,
- GD_MSG_UNFRIEND_REQ_RCVD,
- GD_MSG_FRIEND_UPDATE_RCVD,
- GD_MSG_RESPONSE_INFO,
- GD_MSG_VOL_PROFILE_REQ_RCVD,
- GD_MSG_GETWD_REQ_RCVD,
- GD_MSG_MOUNT_REQ_RCVD,
- GD_MSG_UMOUNT_REQ_RCVD,
- GD_MSG_CONNECT_RETURNED,
- GD_MSG_STATUS_VOL_REQ_RCVD,
- GD_MSG_CLRCLK_VOL_REQ_RCVD,
- GD_MSG_BARRIER_VOL_REQ_RCVD,
- GD_MSG_UUID_RECEIVED,
- GD_MSG_REPLACE_BRK_COMMIT_FORCE_REQ_RCVD,
- GD_MSG_BRK_PORT_NO_ADD_INDO,
- GD_MSG_REPLACE_BRK_REQ_RCVD,
- GD_MSG_ADD_OP_ARGS_FAIL,
- GD_MSG_POST_HOOK_STUB_INIT_FAIL,
- GD_MSG_HOOK_STUB_NULL,
- GD_MSG_SPAWN_THREADS_FAIL,
- GD_MSG_STALE_VOL_DELETE_INFO,
- GD_MSG_PROBE_REQ_RESP_RCVD,
- GD_MSG_HOST_PRESENT_ALREADY,
- GD_MSG_OP_VERS_INFO,
- GD_MSG_OP_VERS_SET_INFO,
- GD_MSG_NEW_NODE_STATE_CREATION,
- GD_MSG_ALREADY_MOUNTED,
- GD_MSG_SHARED_STRG_VOL_OPT_VALIDATE_FAIL,
- GD_MSG_NFS_GNS_STOP_FAIL,
- GD_MSG_NFS_GNS_RESET_FAIL,
- GD_MSG_SHARED_STRG_SET_FAIL,
- GD_MSG_VOL_TRANSPORT_TYPE_CHANGE,
- GD_MSG_PEER_COUNT_GET_FAIL,
- GD_MSG_INSUFFICIENT_UP_NODES,
- GD_MSG_OP_STAGE_STATS_VOL_FAIL,
- GD_MSG_VOL_ID_SET_FAIL,
- GD_MSG_OP_STAGE_RESET_VOL_FAIL,
- GD_MSG_OP_STAGE_BITROT_FAIL,
- GD_MSG_OP_STAGE_QUOTA_FAIL,
- GD_MSG_OP_STAGE_DELETE_VOL_FAIL,
- GD_MSG_HANDLE_HEAL_CMD_FAIL,
- GD_MSG_CLRCLK_SND_CMD_FAIL,
- GD_MSG_DISPERSE_CLUSTER_FOUND,
- GD_MSG_HEAL_VOL_REQ_RCVD,
- GD_MSG_STATEDUMP_VOL_REQ_RCVD,
- GD_MSG_THINPOOLS_FOR_THINLVS,
- GD_MSG_OP_STAGE_CREATE_VOL_FAIL,
- GD_MSG_OP_STAGE_START_VOL_FAIL,
- GD_MSG_NFS_GNS_UNEXPRT_VOL_FAIL,
- GD_MSG_TASK_ID_INFO,
- GD_MSG_DEREGISTER_SUCCESS,
- GD_MSG_STATEDUMP_OPTS_RCVD,
- GD_MSG_STATEDUMP_INFO,
- GD_MSG_RECOVERING_CORRUPT_CONF,
- GD_MSG_RETRIEVED_UUID,
- GD_MSG_XLATOR_CREATE_FAIL,
- GD_MSG_GRAPH_ENTRY_ADD_FAIL,
- GD_MSG_ERROR_ENCOUNTERED,
- GD_MSG_FILTER_RUN_FAILED,
- GD_MSG_DEFAULT_OPT_INFO,
- GD_MSG_MARKER_STATUS_GET_FAIL,
- GD_MSG_MARKER_DISABLE_FAIL,
- GD_MSG_GRAPH_FEATURE_ADD_FAIL,
- GD_MSG_XLATOR_SET_OPT_FAIL,
- GD_MSG_BUILD_GRAPH_FAILED,
- GD_MSG_XML_TEXT_WRITE_FAIL,
- GD_MSG_XML_DOC_START_FAIL,
- GD_MSG_XML_ELE_CREATE_FAIL,
- GD_MSG_VOLUME_INCONSISTENCY,
- GD_MSG_XLATOR_LINK_FAIL,
- GD_MSG_REMOTE_HOST_GET_FAIL,
- GD_MSG_GRAPH_SET_OPT_FAIL,
- GD_MSG_ROOT_SQUASH_ENABLED,
- GD_MSG_ROOT_SQUASH_FAILED,
- GD_MSG_LOCK_OWNER_MISMATCH,
- GD_MSG_LOCK_NOT_HELD,
- GD_MSG_LOCK_ALREADY_HELD,
- GD_MSG_SVC_START_SUCCESS,
- GD_MSG_SVC_STOP_SUCCESS,
- GD_MSG_PARAM_NULL,
- GD_MSG_SVC_STOP_FAIL,
- GD_MSG_SHARED_STORAGE_DOES_NOT_EXIST,
- GD_MSG_SNAP_PAUSE_TIER_FAIL,
- GD_MSG_SNAP_RESUME_TIER_FAIL,
- GD_MSG_FILE_NOT_FOUND,
- GD_MSG_RETRY_WITH_NEW_PORT,
- GD_MSG_REMOTE_VOL_UUID_FAIL,
- GD_MSG_SLAVE_VOL_PARSE_FAIL,
- GD_MSG_DICT_GET_SUCCESS,
- GD_MSG_PMAP_REGISTRY_REMOVE_FAIL,
- GD_MSG_MNTBROKER_LABEL_NULL,
- GD_MSG_MNTBROKER_LABEL_MISS,
- GD_MSG_MNTBROKER_SPEC_MISMATCH,
- GD_MSG_SYSCALL_FAIL,
- GD_MSG_DAEMON_STATE_REQ_RCVD,
- GD_MSG_BRICK_CLEANUP_SUCCESS,
- GD_MSG_STATE_STR_GET_FAILED,
- GD_MSG_RESET_BRICK_COMMIT_FORCE_REQ_RCVD,
- GD_MSG_RESET_BRICK_CMD_FAIL,
- GD_MSG_TIERD_STOP_FAIL,
- GD_MSG_TIERD_CREATE_FAIL,
- GD_MSG_TIERD_START_FAIL,
- GD_MSG_TIERD_OBJ_GET_FAIL,
- GD_MSG_TIERD_NOT_RUNNING,
- GD_MSG_TIERD_INIT_FAIL,
- GD_MSG_BRICK_MX_SET_FAIL,
- GD_MSG_NO_SIG_TO_PID_ZERO,
- GD_MSG_TIER_WATERMARK_RESET_FAIL,
- GD_MSG_CLIENTS_GET_STATE_FAILED,
- GD_MSG_GNFS_XLATOR_NOT_INSTALLED,
- GD_MSG_PIDFILE_UNLINKING,
- GD_MSG_VOL_SET_VALIDATION_INFO,
- GD_MSG_NO_MUX_LIMIT,
- GD_MSG_BRICKPROC_REM_BRICK_FAILED,
- GD_MSG_BRICKPROC_ADD_BRICK_FAILED,
- GD_MSG_BRICKPROC_NEW_FAILED,
- GD_MSG_STATVFS_FAILED,
- GD_MSG_GARBAGE_ARGS,
- GD_MSG_LOCALTIME_LOGGING_VOL_OPT_VALIDATE_FAIL,
- GD_MSG_LOCALTIME_LOGGING_ENABLE,
- GD_MSG_LOCALTIME_LOGGING_DISABLE,
- GD_MSG_PORTS_EXHAUSTED,
- GD_MSG_CHANGELOG_GET_FAIL,
- GD_MSG_MANAGER_FUNCTION_FAILED,
- GD_MSG_DAEMON_LOG_LEVEL_VOL_OPT_VALIDATE_FAIL
-);
+GLFS_MSGID(
+ GLUSTERD, GD_MSG_SERVER_QUORUM_NOT_MET,
+ GD_MSG_SERVER_QUORUM_LOST_STOPPING_BRICKS,
+ GD_MSG_SERVER_QUORUM_MET_STARTING_BRICKS, GD_MSG_PEER_DISCONNECTED,
+ GD_MSG_BRICK_DISCONNECTED, GD_MSG_NODE_DISCONNECTED,
+ GD_MSG_REBALANCE_DISCONNECTED, GD_MSG_VOL_CLEANUP_FAIL,
+ GD_MSG_VOL_VERS_MISMATCH, GD_MSG_CKSUM_VERS_MISMATCH,
+ GD_MSG_QUOTA_CONFIG_VERS_MISMATCH, GD_MSG_QUOTA_CONFIG_CKSUM_MISMATCH,
+ GD_MSG_BRICK_STOP_FAIL, GD_MSG_SVC_KILL_FAIL, GD_MSG_PID_KILL_FAIL,
+ GD_MSG_REBAL_NO_SOCK_FILE, GD_MSG_UNIX_OP_BUILD_FAIL,
+ GD_MSG_RPC_CREATE_FAIL, GD_MSG_FAIL_DEFAULT_OPT_SET,
+ GD_MSG_CLUSTER_UNLOCK_FAILED, GD_MSG_NO_MEMORY, GD_MSG_UNSUPPORTED_VERSION,
+ GD_MSG_COMMAND_NOT_FOUND, GD_MSG_SNAPSHOT_OP_FAILED, GD_MSG_INVALID_ENTRY,
+ GD_MSG_VOL_NOT_FOUND, GD_MSG_REG_COMPILE_FAILED, GD_MSG_FILE_OP_FAILED,
+ GD_MSG_SNAP_CREATION_FAIL, GD_MSG_VOL_OP_FAILED, GD_MSG_CREATE_DIR_FAILED,
+ GD_MSG_DIR_OP_FAILED, GD_MSG_VOL_STOP_FAILED, GD_MSG_NO_CLI_RESP,
+ GD_MSG_LOCK_INIT_FAILED, GD_MSG_SNAP_LIST_GET_FAIL, GD_MSG_UNOUNT_FAILED,
+ GD_MSG_LOCK_DESTROY_FAILED, GD_MSG_SNAP_CLEANUP_FAIL,
+ GD_MSG_SNAP_ACTIVATE_FAIL, GD_MSG_SNAP_DEACTIVATE_FAIL,
+ GD_MSG_SNAP_RESTORE_FAIL, GD_MSG_SNAP_REMOVE_FAIL, GD_MSG_SNAP_CONFIG_FAIL,
+ GD_MSG_SNAP_STATUS_FAIL, GD_MSG_SNAP_INIT_FAIL, GD_MSG_VOLINFO_SET_FAIL,
+ GD_MSG_VOLINFO_GET_FAIL, GD_MSG_BRICK_CREATION_FAIL,
+ GD_MSG_BRICK_GET_INFO_FAIL, GD_MSG_BRICK_NEW_INFO_FAIL, GD_MSG_LVS_FAIL,
+ GD_MSG_SETXATTR_FAIL, GD_MSG_UMOUNTING_SNAP_BRICK, GD_MSG_OP_UNSUPPORTED,
+ GD_MSG_SNAP_NOT_FOUND, GD_MSG_FS_LABEL_UPDATE_FAIL, GD_MSG_LVM_MOUNT_FAILED,
+ GD_MSG_DICT_SET_FAILED, GD_MSG_CANONICALIZE_FAIL, GD_MSG_DICT_GET_FAILED,
+ GD_MSG_SNAP_INFO_FAIL, GD_MSG_SNAP_VOL_CONFIG_FAIL,
+ GD_MSG_SNAP_OBJECT_STORE_FAIL, GD_MSG_DICT_UNSERIALIZE_FAIL,
+ GD_MSG_SNAP_RESTORE_REVERT_FAIL, GD_MSG_SNAP_LIST_SET_FAIL,
+ GD_MSG_VOLFILE_CREATE_FAIL, GD_MSG_VOLINFO_REMOVE_FAIL,
+ GD_MSG_VOL_DELETE_FAIL, GD_MSG_SNAPSHOT_PENDING,
+ GD_MSG_BRICK_PATH_UNMOUNTED, GD_MSG_BRICK_ADD_FAIL,
+ GD_MSG_BRICK_SET_INFO_FAIL, GD_MSG_LVCREATE_FAIL, GD_MSG_VG_GET_FAIL,
+ GD_MSG_TPOOL_GET_FAIL, GD_MSG_LVM_REMOVE_FAILED,
+ GD_MSG_MISSEDSNAP_INFO_SET_FAIL, GD_MSG_BRK_MOUNTOPTS_FAIL,
+ GD_MSG_MISSED_SNAP_LIST_STORE_FAIL, GD_MSG_INVALID_MISSED_SNAP_ENTRY,
+ GD_MSG_MISSED_SNAP_GET_FAIL, GD_MSG_MISSED_SNAP_CREATE_FAIL,
+ GD_MSG_DUP_ENTRY, GD_MSG_MISSED_SNAP_STATUS_DONE, GD_MSG_NO_EXEC_PERMS,
+ GD_MSG_GLOBAL_OP_VERSION_SET_FAIL, GD_MSG_HARD_LIMIT_SET_FAIL,
+ GD_MSG_OP_SUCCESS, GD_MSG_STORE_FAIL, GD_MSG_GLOBAL_OP_VERSION_GET_FAIL,
+ GD_MSG_GEOREP_GET_FAILED, GD_MSG_GLUSTERD_UMOUNT_FAIL,
+ GD_MSG_QUORUM_CHECK_FAIL, GD_MSG_QUORUM_COUNT_IGNORED,
+ GD_MSG_SNAP_MOUNT_FAIL, GD_MSG_RSP_DICT_USE_FAIL, GD_MSG_SNAP_IMPORT_FAIL,
+ GD_MSG_SNAP_CONFLICT, GD_MSG_MISSED_SNAP_DELETE,
+ GD_MSG_QUOTA_CONFIG_IMPORT_FAIL, GD_MSG_SNAPDIR_CREATE_FAIL,
+ GD_MSG_MISSED_SNAP_PRESENT, GD_MSG_UUID_NULL, GD_MSG_TSTAMP_SET_FAIL,
+ GD_MSG_RESP_AGGR_FAIL, GD_MSG_DICT_EMPTY, GD_MSG_DICT_CREATE_FAIL,
+ GD_MSG_SNAPD_STOP_FAIL, GD_MSG_SOFT_LIMIT_REACHED, GD_MSG_SNAPD_START_FAIL,
+ GD_MSG_SNAPD_CREATE_FAIL, GD_MSG_SNAPD_INIT_FAIL, GD_MSG_MGMTV3_OP_FAIL,
+ GD_MSG_MGMTV3_PAYLOAD_BUILD_FAIL, GD_MSG_MGMTV3_UNLOCK_FAIL,
+ GD_MSG_MGMTV3_LOCK_GET_FAIL, GD_MSG_MGMTV3_LOCKDOWN_FAIL,
+ GD_MSG_POST_VALIDATION_FAIL, GD_MSG_PRE_VALIDATION_FAIL,
+ GD_MSG_COMMIT_OP_FAIL, GD_MSG_PEER_LIST_CREATE_FAIL, GD_MSG_BRICK_OP_FAIL,
+ GD_MSG_OPINFO_SET_FAIL, GD_MSG_OP_EVENT_UNLOCK_FAIL,
+ GD_MSG_MGMTV3_OP_RESP_FAIL, GD_MSG_PEER_NOT_FOUND, GD_MSG_REQ_DECODE_FAIL,
+ GD_MSG_DICT_SERL_LENGTH_GET_FAIL, GD_MSG_ALREADY_STOPPED,
+ GD_MSG_PRE_VALD_RESP_FAIL, GD_MSG_SVC_GET_FAIL, GD_MSG_VOLFILE_NOT_FOUND,
+ GD_MSG_OP_EVENT_LOCK_FAIL, GD_MSG_NON_STRIPE_VOL, GD_MSG_SNAPD_OBJ_GET_FAIL,
+ GD_MSG_QUOTA_DISABLED, GD_MSG_CACHE_MINMAX_SIZE_INVALID,
+ GD_MSG_QUOTA_GET_STAT_FAIL, GD_MSG_SUBVOLUMES_EXCEED, GD_MSG_BRICK_ADD,
+ GD_MSG_BRICK_REMOVE, GD_MSG_CREATE_KEY_FAIL,
+ GD_MSG_MULTIPLE_LOCK_ACQUIRE_FAIL, GD_MSG_MULTIPLE_LOCK_RELEASE_FAIL,
+ GD_MSG_RESP_FROM_UNKNOWN_PEER, GD_MSG_BRICK_MOUNDIRS_AGGR_FAIL,
+ GD_MSG_GFID_VALIDATE_SET_FAIL, GD_MSG_PEER_LOCK_FAIL,
+ GD_MSG_PEER_UNLOCK_FAIL, GD_MSG_MGMT_OP_FAIL,
+ GD_MSG_TRANS_OPINFO_CLEAR_FAIL, GD_MSG_GLUSTERD_LOCK_FAIL,
+ GD_MSG_TRANS_OPINFO_SET_FAIL, GD_MSG_TRANS_IDGEN_FAIL, GD_MSG_RPC_FAILURE,
+ GD_MSG_OP_VERS_ADJUST_FAIL, GD_MSG_SNAP_DEVICE_NAME_GET_FAIL,
+ GD_MSG_SNAP_STATUS_NOT_PENDING, GD_MSG_MGMT_PGM_SET_FAIL,
+ GD_MSG_EVENT_INJECT_FAIL, GD_MSG_VERS_INFO, GD_MSG_VOL_INFO_REQ_RECVD,
+ GD_MSG_VERS_GET_FAIL, GD_MSG_EVENT_NEW_GET_FAIL, GD_MSG_RPC_LAYER_ERROR,
+ GD_MSG_NO_HANDSHAKE_ACK, GD_MSG_OP_VERSION_MISMATCH,
+ GD_MSG_HANDSHAKE_REQ_REJECTED, GD_MSG_UNKNOWN_MODE,
+ GD_MSG_DEFRAG_STATUS_UPDATED, GD_MSG_NO_FLAG_SET,
+ GD_MSG_VERSION_UNSUPPORTED, GD_MSG_UUID_SET_FAIL, GD_MSG_MOUNT_REQ_FAIL,
+ GD_MSG_GLUSTERD_GLOBAL_INFO_STORE_FAIL, GD_MSG_OP_VERS_STORE_FAIL,
+ GD_MSG_SNAP_AUTOMIC_UPDATE_FAIL, GD_MSG_SNAPINFO_WRITE_FAIL,
+ GD_MSG_SNAPINFO_CREATE_FAIL, GD_MSG_SNAPD_INFO_STORE_FAIL,
+ GD_MSG_BRK_MNTPATH_MOUNT_FAIL, GD_MSG_BRK_MNTPATH_GET_FAIL,
+ GD_MSG_SNAP_BRK_MNT_RECREATE_FAIL, GD_MSG_SNAP_RESOLVE_BRICK_FAIL,
+ GD_MSG_RESOLVE_BRICK_FAIL, GD_MSG_BRK_MNT_RECREATE_FAIL,
+ GD_MSG_TMP_FILE_UNLINK_FAIL, GD_MSG_VOL_VALS_WRITE_FAIL,
+ GD_MSG_STORE_HANDLE_GET_FAIL, GD_MSG_STORE_HANDLE_WRITE_FAIL,
+ GD_MSG_MISSED_SNAP_LIST_STORE_HANDLE_GET_FAIL,
+ GD_MSG_MISSED_SNAP_LIST_EMPTY, GD_MSG_SNAP_VOL_RETRIEVE_FAIL,
+ GD_MSG_SNAPSHOT_UPDATE_FAIL, GD_MSG_SNAPD_PORT_STORE_FAIL,
+ GD_MSG_CKSUM_STORE_FAIL, GD_MSG_STORE_HANDLE_CREATE_FAIL,
+ GD_MSG_HANDLE_NULL, GD_MSG_VOL_RESTORE_FAIL, GD_MSG_NAME_TOO_LONG,
+ GD_MSG_UUID_PARSE_FAIL, GD_MSG_UNKNOWN_KEY, GD_MSG_STORE_ITER_DESTROY_FAIL,
+ GD_MSG_STORE_ITER_GET_FAIL, GD_MSG_VOLINFO_UPDATE_FAIL,
+ GD_MSG_PARSE_BRICKINFO_FAIL, GD_MSG_VERS_STORE_FAIL, GD_MSG_HEADER_ADD_FAIL,
+ GD_MSG_QUOTA_CONF_WRITE_FAIL, GD_MSG_QUOTA_CONF_CORRUPT, GD_MSG_FORK_FAIL,
+ GD_MSG_CKSUM_COMPUTE_FAIL, GD_MSG_VERS_CKSUM_STORE_FAIL,
+ GD_MSG_GETXATTR_FAIL, GD_MSG_CONVERSION_FAILED, GD_MSG_VOL_NOT_DISTRIBUTE,
+ GD_MSG_VOL_STOPPED, GD_MSG_OPCTX_GET_FAIL, GD_MSG_TASKID_GEN_FAIL,
+ GD_MSG_REBALANCE_ID_MISSING, GD_MSG_NO_REBALANCE_PFX_IN_VOLNAME,
+ GD_MSG_DEFRAG_STATUS_UPDATE_FAIL, GD_MSG_UUID_GEN_STORE_FAIL,
+ GD_MSG_UUID_STORE_FAIL, GD_MSG_NO_INIT, GD_MSG_MODULE_NOT_INSTALLED,
+ GD_MSG_MODULE_NOT_WORKING, GD_MSG_WRITE_ACCESS_GRANT_FAIL,
+ GD_MSG_DIRPATH_TOO_LONG, GD_MSG_LOGGROUP_INVALID, GD_MSG_DIR_PERM_LIBERAL,
+ GD_MSG_DIR_PERM_STRICT, GD_MSG_MOUNT_SPEC_INSTALL_FAIL,
+ GD_MSG_GLUSTERD_SOCK_LISTENER_START_FAIL, GD_MSG_DIR_NOT_FOUND,
+ GD_MSG_FAILED_INIT_SHDSVC, GD_MSG_FAILED_INIT_NFSSVC,
+ GD_MSG_FAILED_INIT_QUOTASVC, GD_MSG_RPC_INIT_FAIL,
+ GD_MSG_RPCSVC_REG_NOTIFY_RETURNED, GD_MSG_RPC_TRANSPORT_COUNT_GET_FAIL,
+ GD_MSG_RPC_LISTENER_CREATE_FAIL, GD_MSG_OP_VERS_RESTORE_FAIL,
+ GD_MSG_SELF_HEALD_DISABLED, GD_MSG_PRIV_NULL, GD_MSG_GSYNC_VALIDATION_FAIL,
+ GD_MSG_SLAVE_CONFPATH_DETAILS_FETCH_FAIL, GD_MSG_OP_NOT_PERMITTED_AC_REQD,
+ GD_MSG_OP_NOT_PERMITTED, GD_MSG_REBALANCE_START_FAIL,
+ GD_MSG_NFS_RECONF_FAIL, GD_MSG_REMOVE_BRICK_ID_SET_FAIL,
+ GD_MSG_BRICK_MOUNTDIR_GET_FAIL, GD_MSG_BRICK_NOT_FOUND,
+ GD_MSG_BRKPATH_TOO_LONG, GD_MSG_CLRLOCKS_CLNT_UMOUNT_FAIL,
+ GD_MSG_CLRLOCKS_CLNT_MOUNT_FAIL, GD_MSG_CLRLOCKS_MOUNTDIR_CREATE_FAIL,
+ GD_MSG_BRK_PORT_NUM_GET_FAIL, GD_MSG_BRK_STATEDUMP_FAIL,
+ GD_MSG_VOL_GRAPH_CHANGE_NOTIFY_FAIL, GD_MSG_INVALID_VG,
+ GD_MSG_GLUSTERD_OP_FAILED, GD_MSG_HOSTNAME_ADD_TO_PEERLIST_FAIL,
+ GD_MSG_STALE_PEERINFO_REMOVE_FAIL, GD_MSG_TRANS_ID_GET_FAIL,
+ GD_MSG_RES_DECODE_FAIL, GD_MSG_VOL_ALREADY_EXIST, GD_MSG_BAD_BRKORDER,
+ GD_MSG_BAD_BRKORDER_CHECK_FAIL, GD_MSG_BRICK_SELECT_FAIL,
+ GD_MSG_NO_LOCK_RESP_FROM_PEER, GD_MSG_MGMTV3_LOCK_FROM_UUID_REJCT,
+ GD_MSG_STAGE_FROM_UUID_REJCT, GD_MSG_UNLOCK_FROM_UUID_REJCT,
+ GD_MSG_MGMTV3_UNLOCK_FROM_UUID_REJCT, GD_MSG_COMMIT_FROM_UUID_REJCT,
+ GD_MSG_VOL_NOT_STARTED, GD_MSG_VOL_NOT_REPLICA, GD_MSG_VOL_NOT_DISPERSE,
+ GD_MSG_OLD_REMOVE_BRICK_EXISTS, GD_MSG_USE_THE_FORCE, GD_MSG_OIP,
+ GD_MSG_OIP_RETRY_LATER, GD_MSG_GSYNC_RESTART_FAIL,
+ GD_MSG_LOCK_FROM_UUID_REJCT, GD_MSG_BRICK_OP_PAYLOAD_BUILD_FAIL,
+ GD_MSG_HOSTNAME_RESOLVE_FAIL, GD_MSG_COUNT_VALIDATE_FAILED,
+ GD_MSG_SPAWNING_CHILD_FAILED, GD_MSG_READ_CHILD_DATA_FAILED,
+ GD_MSG_DEFAULT_TEMP_CONFIG, GD_MSG_PIDFILE_CREATE_FAILED,
+ GD_MSG_GSYNCD_SPAWN_FAILED, GD_MSG_SUBOP_NOT_FOUND, GD_MSG_RESERVED_OPTION,
+ GD_MSG_GLUSTERD_PRIV_NOT_FOUND, GD_MSG_SLAVEINFO_FETCH_ERROR,
+ GD_MSG_VALIDATE_FAILED, GD_MSG_INVOKE_ERROR, GD_MSG_SESSION_CREATE_ERROR,
+ GD_MSG_STOP_FORCE, GD_MSG_GET_CONFIG_INFO_FAILED,
+ GD_MSG_STAT_FILE_READ_FAILED, GD_MSG_CONF_PATH_ASSIGN_FAILED,
+ GD_MSG_SESSION_INACTIVE, GD_MSG_PIDFILE_NOT_FOUND, GD_MSG_PEER_CMD_ERROR,
+ GD_MSG_SRC_FILE_ERROR, GD_MSG_GET_STATEFILE_NAME_FAILED, GD_MSG_STATUS_NULL,
+ GD_MSG_STATUSFILE_CREATE_FAILED, GD_MSG_SLAVE_URL_INVALID,
+ GD_MSG_INVALID_SLAVE, GD_MSG_READ_ERROR, GD_MSG_ARG_FETCH_ERROR,
+ GD_MSG_REG_FILE_MISSING, GD_MSG_STATEFILE_NAME_NOT_FOUND,
+ GD_MSG_GEO_REP_START_FAILED, GD_MSG_GSYNCD_ERROR,
+ GD_MSG_UPDATE_STATEFILE_FAILED, GD_MSG_STATUS_UPDATE_FAILED,
+ GD_MSG_GSYNCD_OP_SET_FAILED, GD_MSG_BUFFER_EMPTY, GD_MSG_CONFIG_INFO,
+ GD_MSG_FETCH_CONFIG_VAL_FAILED, GD_MSG_GSYNCD_PARSE_ERROR,
+ GD_MSG_SESSION_ALREADY_EXIST, GD_MSG_FORCE_CREATE_SESSION,
+ GD_MSG_GET_KEY_FAILED, GD_MSG_SESSION_DEL_FAILED, GD_MSG_CMD_EXEC_FAIL,
+ GD_MSG_STRDUP_FAILED, GD_MSG_UNABLE_TO_END, GD_MSG_PAUSE_FAILED,
+ GD_MSG_NORMALIZE_URL_FAIL, GD_MSG_MODULE_ERROR,
+ GD_MSG_SLAVEINFO_STORE_ERROR, GD_MSG_MARKER_START_FAIL,
+ GD_MSG_RESUME_FAILED, GD_MSG_GLUSTERFS_START_FAIL,
+ GD_MSG_GLUSTERFS_STOP_FAIL, GD_MSG_RBOP_STATE_STORE_FAIL,
+ GD_MSG_PUMP_XLATOR_DISABLED, GD_MSG_ABORT_OP_FAIL, GD_MSG_PAUSE_OP_FAIL,
+ GD_MSG_GLUSTER_SERVICE_START_FAIL, GD_MSG_HANDSHAKE_FAILED,
+ GD_MSG_CLI_REQ_EMPTY, GD_MSG_PEER_ADD_FAIL,
+ GD_MSG_SYNC_FROM_LOCALHOST_UNALLOWED, GD_MSG_UUIDS_SAME_RETRY,
+ GD_MSG_TSP_ALREADY_FORMED, GD_MSG_VOLS_ALREADY_PRESENT,
+ GD_MSG_REQ_CTX_CREATE_FAIL, GD_MSG_PEER_INFO_UPDATE_FAIL,
+ GD_MSG_PEERINFO_CREATE_FAIL, GD_MSG_REQ_FROM_UNKNOWN_PEER,
+ GD_MSG_STATUS_REPLY_STRING_CREATE_FAIL, GD_MSG_TOKENIZE_FAIL,
+ GD_MSG_LAZY_UMOUNT_FAIL, GD_MSG_NFS_SERVER_START_FAIL,
+ GD_MSG_GLUSTER_SERVICES_STOP_FAIL, GD_MSG_BRK_CLEANUP_FAIL,
+ GD_MSG_RB_ALREADY_STARTED, GD_MSG_RB_BRICKINFO_GET_FAIL, GD_MSG_BAD_FORMAT,
+ GD_MSG_RB_CMD_FAIL, GD_MSG_RB_NOT_STARTED_OR_PAUSED, GD_MSG_RB_NOT_STARTED,
+ GD_MSG_RB_PAUSED_ALREADY, GD_MSG_NO_FREE_PORTS,
+ GD_MSG_EVENT_STATE_TRANSITION_FAIL, GD_MSG_HANDLER_RETURNED,
+ GD_MSG_SNAP_COMPARE_CONFLICT, GD_MSG_PEER_DETACH_CLEANUP_FAIL,
+ GD_MSG_STALE_VOL_REMOVE_FAIL, GD_MSG_AC_ERROR, GD_MSG_LOCK_FAIL,
+ GD_MSG_MGMTV3_LOCK_REQ_SEND_FAIL, GD_MSG_GLUSTERD_UNLOCK_FAIL,
+ GD_MSG_RBOP_START_FAIL, GD_MSG_UNKNOWN_RESPONSE,
+ GD_MSG_COMMIT_REQ_SEND_FAIL, GD_MSG_OPCTX_UPDATE_FAIL, GD_MSG_OPCTX_NULL,
+ GD_MSG_DICT_COPY_FAIL, GD_MSG_SHD_STATUS_SET_FAIL,
+ GD_MSG_REPLICA_INDEX_GET_FAIL, GD_MSG_NFS_SERVER_NOT_RUNNING,
+ GD_MSG_STAGE_REQ_SEND_FAIL, GD_MSG_LOCK_REQ_SEND_FAIL,
+ GD_MSG_VOLNAMES_GET_FAIL, GD_MSG_NO_TASK_ID, GD_MSG_ADD_REMOVE_BRICK_FAIL,
+ GD_MSG_SVC_RESTART_FAIL, GD_MSG_VOL_SET_FAIL, GD_MSG_QUOTAD_NOT_RUNNING,
+ GD_MSG_XLATOR_COUNT_GET_FAIL, GD_MSG_TRANS_OPINFO_GET_FAIL,
+ GD_MSG_TRANS_ID_INVALID, GD_MSG_NO_OPTIONS_GIVEN, GD_MSG_SNAPD_NOT_RUNNING,
+ GD_MSG_ADD_ADDRESS_TO_PEER_FAIL, GD_MSG_PEER_ADDRESS_GET_FAIL,
+ GD_MSG_GETADDRINFO_FAIL, GD_MSG_PEERINFO_DELETE_FAIL, GD_MSG_KEY_NULL,
+ GD_MSG_SPAWN_SVCS_FAIL, GD_MSG_DICT_ITER_FAIL,
+ GD_MSG_TASK_STATUS_UPDATE_FAIL, GD_MSG_VOL_ID_MISMATCH,
+ GD_MSG_STR_TO_BOOL_FAIL, GD_MSG_RB_MNT_BRICKS_MISMATCH,
+ GD_MSG_RB_SRC_BRICKS_MISMATCH, GD_MSG_MNTENTRY_GET_FAIL,
+ GD_MSG_INODE_SIZE_GET_FAIL, GD_MSG_NO_STATEFILE_ENTRY,
+ GD_MSG_PMAP_UNSET_FAIL, GD_MSG_GLOBAL_OPT_IMPORT_FAIL,
+ GD_MSD_BRICK_DISCONNECT_FAIL, GD_MSG_SNAP_DETAILS_IMPORT_FAIL,
+ GD_MSG_BRICKINFO_CREATE_FAIL, GD_MSG_QUOTA_CKSUM_VER_STORE_FAIL,
+ GD_MSG_CKSUM_GET_FAIL, GD_MSG_BRICKPATH_ROOT_GET_FAIL,
+ GD_MSG_HOSTNAME_TO_UUID_FAIL, GD_MSG_REPLY_SUBMIT_FAIL,
+ GD_MSG_SERIALIZE_MSG_FAIL, GD_MSG_ENCODE_FAIL,
+ GD_MSG_RB_DST_BRICKS_MISMATCH, GD_MSG_XLATOR_VOLOPT_DYNLOAD_ERROR,
+ GD_MSG_VOLNAME_NOTFOUND_IN_DICT, GD_MSG_FLAGS_NOTFOUND_IN_DICT,
+ GD_MSG_HOSTNAME_NOTFOUND_IN_DICT, GD_MSG_PORT_NOTFOUND_IN_DICT,
+ GD_MSG_CMDSTR_NOTFOUND_IN_DICT, GD_MSG_SNAP_OBJ_NEW_FAIL,
+ GD_MSG_SNAP_BACKEND_MAKE_FAIL, GD_MSG_SNAP_CLONE_FAILED,
+ GD_MSG_SNAP_CLONE_PREVAL_FAILED, GD_MSG_SNAP_CLONE_POSTVAL_FAILED,
+ GD_MSG_VOLINFO_STORE_FAIL, GD_MSG_NEW_FRIEND_SM_EVENT_GET_FAIL,
+ GD_MSG_VOL_TYPE_CHANGING_INFO, GD_MSG_BRKPATH_MNTPNT_MISMATCH,
+ GD_MSG_TASKS_COUNT_MISMATCH, GD_MSG_WRONG_OPTS_SETTING,
+ GD_MSG_PATH_ALREADY_PART_OF_VOL, GD_MSG_BRICK_VALIDATE_FAIL,
+ GD_MSG_READIN_FILE_FAILED, GD_MSG_IMPORT_PRDICT_DICT,
+ GD_MSG_VOL_OPTS_IMPORT_FAIL, GD_MSG_BRICK_IMPORT_FAIL,
+ GD_MSG_VOLINFO_IMPORT_FAIL, GD_MSG_BRICK_ID_GEN_FAILED,
+ GD_MSG_GET_STATUS_DATA_FAIL, GD_MSG_BITROT_NOT_RUNNING,
+ GD_MSG_SCRUBBER_NOT_RUNNING, GD_MSG_SRC_BRICK_PORT_UNAVAIL,
+ GD_MSG_BITD_INIT_FAIL, GD_MSG_SCRUB_INIT_FAIL, GD_MSG_VAR_RUN_DIR_INIT_FAIL,
+ GD_MSG_VAR_RUN_DIR_FIND_FAIL, GD_MSG_SCRUBSVC_RECONF_FAIL,
+ GD_MSG_BITDSVC_RECONF_FAIL, GD_MSG_NFS_GNS_START_FAIL,
+ GD_MSG_NFS_GNS_SETUP_FAIL, GD_MSG_UNRECOGNIZED_SVC_MNGR,
+ GD_MSG_NFS_GNS_OP_HANDLE_FAIL, GD_MSG_EXPORT_FILE_CREATE_FAIL,
+ GD_MSG_NFS_GNS_HOST_FOUND, GD_MSG_REBALANCE_CMD_IN_TIER_VOL,
+ GD_MSG_INCOMPATIBLE_VALUE, GD_MSG_GENERATED_UUID,
+ GD_MSG_FILE_DESC_LIMIT_SET, GD_MSG_CURR_WORK_DIR_INFO,
+ GD_MSG_STRIPE_COUNT_CHANGE_INFO, GD_MSG_REPLICA_COUNT_CHANGE_INFO,
+ GD_MSG_ADD_BRICK_REQ_RECVD, GD_MSG_VOL_ALREADY_TIER,
+ GD_MSG_REM_BRICK_REQ_RECVD, GD_MSG_VOL_NOT_TIER,
+ GD_MSG_LOG_ROTATE_REQ_RECVD, GD_MSG_CLI_REQ_RECVD, GD_MSG_GET_VOL_REQ_RCVD,
+ GD_MSG_VOL_SYNC_REQ_RCVD, GD_MSG_PROBE_RCVD, GD_MSG_UNFRIEND_REQ_RCVD,
+ GD_MSG_FRIEND_UPDATE_RCVD, GD_MSG_RESPONSE_INFO,
+ GD_MSG_VOL_PROFILE_REQ_RCVD, GD_MSG_GETWD_REQ_RCVD, GD_MSG_MOUNT_REQ_RCVD,
+ GD_MSG_UMOUNT_REQ_RCVD, GD_MSG_CONNECT_RETURNED, GD_MSG_STATUS_VOL_REQ_RCVD,
+ GD_MSG_CLRCLK_VOL_REQ_RCVD, GD_MSG_BARRIER_VOL_REQ_RCVD,
+ GD_MSG_UUID_RECEIVED, GD_MSG_REPLACE_BRK_COMMIT_FORCE_REQ_RCVD,
+ GD_MSG_BRK_PORT_NO_ADD_INDO, GD_MSG_REPLACE_BRK_REQ_RCVD,
+ GD_MSG_ADD_OP_ARGS_FAIL, GD_MSG_POST_HOOK_STUB_INIT_FAIL,
+ GD_MSG_HOOK_STUB_NULL, GD_MSG_SPAWN_THREADS_FAIL,
+ GD_MSG_STALE_VOL_DELETE_INFO, GD_MSG_PROBE_REQ_RESP_RCVD,
+ GD_MSG_HOST_PRESENT_ALREADY, GD_MSG_OP_VERS_INFO, GD_MSG_OP_VERS_SET_INFO,
+ GD_MSG_NEW_NODE_STATE_CREATION, GD_MSG_ALREADY_MOUNTED,
+ GD_MSG_SHARED_STRG_VOL_OPT_VALIDATE_FAIL, GD_MSG_NFS_GNS_STOP_FAIL,
+ GD_MSG_NFS_GNS_RESET_FAIL, GD_MSG_SHARED_STRG_SET_FAIL,
+ GD_MSG_VOL_TRANSPORT_TYPE_CHANGE, GD_MSG_PEER_COUNT_GET_FAIL,
+ GD_MSG_INSUFFICIENT_UP_NODES, GD_MSG_OP_STAGE_STATS_VOL_FAIL,
+ GD_MSG_VOL_ID_SET_FAIL, GD_MSG_OP_STAGE_RESET_VOL_FAIL,
+ GD_MSG_OP_STAGE_BITROT_FAIL, GD_MSG_OP_STAGE_QUOTA_FAIL,
+ GD_MSG_OP_STAGE_DELETE_VOL_FAIL, GD_MSG_HANDLE_HEAL_CMD_FAIL,
+ GD_MSG_CLRCLK_SND_CMD_FAIL, GD_MSG_DISPERSE_CLUSTER_FOUND,
+ GD_MSG_HEAL_VOL_REQ_RCVD, GD_MSG_STATEDUMP_VOL_REQ_RCVD,
+ GD_MSG_THINPOOLS_FOR_THINLVS, GD_MSG_OP_STAGE_CREATE_VOL_FAIL,
+ GD_MSG_OP_STAGE_START_VOL_FAIL, GD_MSG_NFS_GNS_UNEXPRT_VOL_FAIL,
+ GD_MSG_TASK_ID_INFO, GD_MSG_DEREGISTER_SUCCESS, GD_MSG_STATEDUMP_OPTS_RCVD,
+ GD_MSG_STATEDUMP_INFO, GD_MSG_RECOVERING_CORRUPT_CONF,
+ GD_MSG_RETRIEVED_UUID, GD_MSG_XLATOR_CREATE_FAIL,
+ GD_MSG_GRAPH_ENTRY_ADD_FAIL, GD_MSG_ERROR_ENCOUNTERED,
+ GD_MSG_FILTER_RUN_FAILED, GD_MSG_DEFAULT_OPT_INFO,
+ GD_MSG_MARKER_STATUS_GET_FAIL, GD_MSG_MARKER_DISABLE_FAIL,
+ GD_MSG_GRAPH_FEATURE_ADD_FAIL, GD_MSG_XLATOR_SET_OPT_FAIL,
+ GD_MSG_BUILD_GRAPH_FAILED, GD_MSG_XML_TEXT_WRITE_FAIL,
+ GD_MSG_XML_DOC_START_FAIL, GD_MSG_XML_ELE_CREATE_FAIL,
+ GD_MSG_VOLUME_INCONSISTENCY, GD_MSG_XLATOR_LINK_FAIL,
+ GD_MSG_REMOTE_HOST_GET_FAIL, GD_MSG_GRAPH_SET_OPT_FAIL,
+ GD_MSG_ROOT_SQUASH_ENABLED, GD_MSG_ROOT_SQUASH_FAILED,
+ GD_MSG_LOCK_OWNER_MISMATCH, GD_MSG_LOCK_NOT_HELD, GD_MSG_LOCK_ALREADY_HELD,
+ GD_MSG_SVC_START_SUCCESS, GD_MSG_SVC_STOP_SUCCESS, GD_MSG_PARAM_NULL,
+ GD_MSG_SVC_STOP_FAIL, GD_MSG_SHARED_STORAGE_DOES_NOT_EXIST,
+ GD_MSG_SNAP_PAUSE_TIER_FAIL, GD_MSG_SNAP_RESUME_TIER_FAIL,
+ GD_MSG_FILE_NOT_FOUND, GD_MSG_RETRY_WITH_NEW_PORT,
+ GD_MSG_REMOTE_VOL_UUID_FAIL, GD_MSG_SLAVE_VOL_PARSE_FAIL,
+ GD_MSG_DICT_GET_SUCCESS, GD_MSG_PMAP_REGISTRY_REMOVE_FAIL,
+ GD_MSG_MNTBROKER_LABEL_NULL, GD_MSG_MNTBROKER_LABEL_MISS,
+ GD_MSG_MNTBROKER_SPEC_MISMATCH, GD_MSG_SYSCALL_FAIL,
+ GD_MSG_DAEMON_STATE_REQ_RCVD, GD_MSG_BRICK_CLEANUP_SUCCESS,
+ GD_MSG_STATE_STR_GET_FAILED, GD_MSG_RESET_BRICK_COMMIT_FORCE_REQ_RCVD,
+ GD_MSG_RESET_BRICK_CMD_FAIL, GD_MSG_TIERD_STOP_FAIL,
+ GD_MSG_TIERD_CREATE_FAIL, GD_MSG_TIERD_START_FAIL,
+ GD_MSG_TIERD_OBJ_GET_FAIL, GD_MSG_TIERD_NOT_RUNNING, GD_MSG_TIERD_INIT_FAIL,
+ GD_MSG_BRICK_MX_SET_FAIL, GD_MSG_NO_SIG_TO_PID_ZERO,
+ GD_MSG_TIER_WATERMARK_RESET_FAIL, GD_MSG_CLIENTS_GET_STATE_FAILED,
+ GD_MSG_GNFS_XLATOR_NOT_INSTALLED, GD_MSG_PIDFILE_UNLINKING,
+ GD_MSG_VOL_SET_VALIDATION_INFO, GD_MSG_NO_MUX_LIMIT,
+ GD_MSG_BRICKPROC_REM_BRICK_FAILED, GD_MSG_BRICKPROC_ADD_BRICK_FAILED,
+ GD_MSG_BRICKPROC_NEW_FAILED, GD_MSG_STATVFS_FAILED, GD_MSG_GARBAGE_ARGS,
+ GD_MSG_LOCALTIME_LOGGING_VOL_OPT_VALIDATE_FAIL,
+ GD_MSG_LOCALTIME_LOGGING_ENABLE, GD_MSG_LOCALTIME_LOGGING_DISABLE,
+ GD_MSG_PORTS_EXHAUSTED, GD_MSG_CHANGELOG_GET_FAIL,
+ GD_MSG_MANAGER_FUNCTION_FAILED,
+ GD_MSG_DAEMON_LOG_LEVEL_VOL_OPT_VALIDATE_FAIL);
#endif /* !_GLUSTERD_MESSAGES_H_ */
diff --git a/xlators/mgmt/glusterd/src/glusterd-mgmt.h b/xlators/mgmt/glusterd/src/glusterd-mgmt.h
index 2215f178327..9b57f4cb833 100644
--- a/xlators/mgmt/glusterd/src/glusterd-mgmt.h
+++ b/xlators/mgmt/glusterd/src/glusterd-mgmt.h
@@ -10,74 +10,73 @@
#ifndef _GLUSTERD_MGMT_H_
#define _GLUSTERD_MGMT_H_
-void gd_mgmt_v3_collate_errors (struct syncargs *args, int op_ret, int op_errno,
- char *op_errstr, int op_code, uuid_t peerid,
- u_char *uuid);
+void
+gd_mgmt_v3_collate_errors(struct syncargs *args, int op_ret, int op_errno,
+ char *op_errstr, int op_code, uuid_t peerid,
+ u_char *uuid);
int32_t
-gd_mgmt_v3_pre_validate_fn (glusterd_op_t op, dict_t *dict,
- char **op_errstr, dict_t *rsp_dict,
- uint32_t *op_errno);
+gd_mgmt_v3_pre_validate_fn(glusterd_op_t op, dict_t *dict, char **op_errstr,
+ dict_t *rsp_dict, uint32_t *op_errno);
int32_t
-gd_mgmt_v3_brick_op_fn (glusterd_op_t op, dict_t *dict,
- char **op_errstr, dict_t *rsp_dict);
+gd_mgmt_v3_brick_op_fn(glusterd_op_t op, dict_t *dict, char **op_errstr,
+ dict_t *rsp_dict);
int32_t
-gd_mgmt_v3_commit_fn (glusterd_op_t op, dict_t *dict,
- char **op_errstr, uint32_t *op_errno,
- dict_t *rsp_dict);
+gd_mgmt_v3_commit_fn(glusterd_op_t op, dict_t *dict, char **op_errstr,
+ uint32_t *op_errno, dict_t *rsp_dict);
int32_t
-gd_mgmt_v3_post_validate_fn (glusterd_op_t op, int32_t op_ret, dict_t *dict,
+gd_mgmt_v3_post_validate_fn(glusterd_op_t op, int32_t op_ret, dict_t *dict,
char **op_errstr, dict_t *rsp_dict);
int32_t
-glusterd_mgmt_v3_initiate_all_phases (rpcsvc_request_t *req, glusterd_op_t op,
+glusterd_mgmt_v3_initiate_all_phases(rpcsvc_request_t *req, glusterd_op_t op,
dict_t *dict);
int32_t
-glusterd_mgmt_v3_initiate_snap_phases (rpcsvc_request_t *req, glusterd_op_t op,
+glusterd_mgmt_v3_initiate_snap_phases(rpcsvc_request_t *req, glusterd_op_t op,
dict_t *dict);
int
-glusterd_snap_pre_validate_use_rsp_dict (dict_t *dst, dict_t *src);
+glusterd_snap_pre_validate_use_rsp_dict(dict_t *dst, dict_t *src);
int32_t
-glusterd_set_barrier_value (dict_t *dict, char *option);
+glusterd_set_barrier_value(dict_t *dict, char *option);
int
-glusterd_mgmt_v3_initiate_lockdown (glusterd_op_t op, dict_t *dict,
- char **op_errstr, uint32_t *op_errno,
- gf_boolean_t *is_acquired,
- uint32_t txn_generation);
+glusterd_mgmt_v3_initiate_lockdown(glusterd_op_t op, dict_t *dict,
+ char **op_errstr, uint32_t *op_errno,
+ gf_boolean_t *is_acquired,
+ uint32_t txn_generation);
int
-glusterd_mgmt_v3_build_payload (dict_t **req, char **op_errstr, dict_t *dict,
- glusterd_op_t op);
+glusterd_mgmt_v3_build_payload(dict_t **req, char **op_errstr, dict_t *dict,
+ glusterd_op_t op);
int
-glusterd_mgmt_v3_pre_validate (glusterd_op_t op, dict_t *req_dict,
- char **op_errstr, uint32_t *op_errno,
- uint32_t txn_generation);
+glusterd_mgmt_v3_pre_validate(glusterd_op_t op, dict_t *req_dict,
+ char **op_errstr, uint32_t *op_errno,
+ uint32_t txn_generation);
int
-glusterd_mgmt_v3_commit (glusterd_op_t op, dict_t *op_ctx, dict_t *req_dict,
- char **op_errstr, uint32_t *op_errno,
- uint32_t txn_generation);
+glusterd_mgmt_v3_commit(glusterd_op_t op, dict_t *op_ctx, dict_t *req_dict,
+ char **op_errstr, uint32_t *op_errno,
+ uint32_t txn_generation);
int
-glusterd_mgmt_v3_release_peer_locks (glusterd_op_t op, dict_t *dict,
- int32_t op_ret, char **op_errstr,
- gf_boolean_t is_acquired,
- uint32_t txn_generation);
+glusterd_mgmt_v3_release_peer_locks(glusterd_op_t op, dict_t *dict,
+ int32_t op_ret, char **op_errstr,
+ gf_boolean_t is_acquired,
+ uint32_t txn_generation);
int32_t
-glusterd_multiple_mgmt_v3_unlock (dict_t *dict, uuid_t uuid);
+glusterd_multiple_mgmt_v3_unlock(dict_t *dict, uuid_t uuid);
int
-glusterd_reset_brick_prevalidate (dict_t *dict, char **op_errstr,
- dict_t *rsp_dict);
+glusterd_reset_brick_prevalidate(dict_t *dict, char **op_errstr,
+ dict_t *rsp_dict);
int
-glusterd_op_reset_brick (dict_t *dict, dict_t *rsp_dict);
+glusterd_op_reset_brick(dict_t *dict, dict_t *rsp_dict);
#endif /* _GLUSTERD_MGMT_H_ */
diff --git a/xlators/mgmt/glusterd/src/glusterd-mountbroker.h b/xlators/mgmt/glusterd/src/glusterd-mountbroker.h
index 83267c203ca..319e05188b4 100644
--- a/xlators/mgmt/glusterd/src/glusterd-mountbroker.h
+++ b/xlators/mgmt/glusterd/src/glusterd-mountbroker.h
@@ -9,34 +9,31 @@
*/
#define MB_HIVE "mb_hive"
-typedef enum {
- SET_SUB = 1,
- SET_SUPER,
- SET_EQUAL,
- SET_INTERSECT
-} gf_setrel_t;
+typedef enum { SET_SUB = 1, SET_SUPER, SET_EQUAL, SET_INTERSECT } gf_setrel_t;
struct gf_mount_pattern {
- char **components;
- gf_setrel_t condition;
- gf_boolean_t negative;
+ char **components;
+ gf_setrel_t condition;
+ gf_boolean_t negative;
};
typedef struct gf_mount_pattern gf_mount_pattern_t;
struct gf_mount_spec {
- struct cds_list_head speclist;
- char *label;
- gf_mount_pattern_t *patterns;
- size_t len;
+ struct cds_list_head speclist;
+ char *label;
+ gf_mount_pattern_t *patterns;
+ size_t len;
};
typedef struct gf_mount_spec gf_mount_spec_t;
+int
+parse_mount_pattern_desc(gf_mount_spec_t *mspec, char *pdesc);
-int parse_mount_pattern_desc (gf_mount_spec_t *mspec, char *pdesc);
+int
+make_georep_mountspec(gf_mount_spec_t *mspec, const char *volname, char *user);
+int
+make_ghadoop_mountspec(gf_mount_spec_t *mspec, const char *volname, char *user,
+ char *server);
-int make_georep_mountspec (gf_mount_spec_t *mspec, const char *volname,
- char *user);
-int make_ghadoop_mountspec (gf_mount_spec_t *mspec, const char *volname,
- char *user, char *server);
-
-int glusterd_do_mount (char *label, dict_t *argdict, char **path, int *op_errno);
+int
+glusterd_do_mount(char *label, dict_t *argdict, char **path, int *op_errno);
diff --git a/xlators/mgmt/glusterd/src/glusterd-nfs-svc.h b/xlators/mgmt/glusterd/src/glusterd-nfs-svc.h
index 6330b71ba7d..47e89830f55 100644
--- a/xlators/mgmt/glusterd/src/glusterd-nfs-svc.h
+++ b/xlators/mgmt/glusterd/src/glusterd-nfs-svc.h
@@ -14,12 +14,12 @@
#include "glusterd-svc-mgmt.h"
void
-glusterd_nfssvc_build (glusterd_svc_t *svc);
+glusterd_nfssvc_build(glusterd_svc_t *svc);
int
-glusterd_nfssvc_init (glusterd_svc_t *svc);
+glusterd_nfssvc_init(glusterd_svc_t *svc);
int
-glusterd_nfssvc_reconfigure ();
+glusterd_nfssvc_reconfigure();
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-op-sm.h b/xlators/mgmt/glusterd/src/glusterd-op-sm.h
index 92a604b680c..4fcaff1c8ba 100644
--- a/xlators/mgmt/glusterd/src/glusterd-op-sm.h
+++ b/xlators/mgmt/glusterd/src/glusterd-op-sm.h
@@ -10,7 +10,6 @@
#ifndef _GLUSTERD_OP_SM_H_
#define _GLUSTERD_OP_SM_H_
-
#include <pthread.h>
#include "compat-uuid.h"
@@ -23,292 +22,293 @@
#include "protocol-common.h"
#include "glusterd-hooks.h"
-#define GD_OP_PROTECTED (0x02)
-#define GD_OP_UNPROTECTED (0x04)
+#define GD_OP_PROTECTED (0x02)
+#define GD_OP_UNPROTECTED (0x04)
typedef enum glusterd_op_sm_state_ {
- GD_OP_STATE_DEFAULT = 0,
- GD_OP_STATE_LOCK_SENT,
- GD_OP_STATE_LOCKED,
- GD_OP_STATE_STAGE_OP_SENT,
- GD_OP_STATE_STAGED,
- GD_OP_STATE_COMMIT_OP_SENT,
- GD_OP_STATE_COMMITED,
- GD_OP_STATE_UNLOCK_SENT,
- GD_OP_STATE_STAGE_OP_FAILED,
- GD_OP_STATE_COMMIT_OP_FAILED,
- GD_OP_STATE_BRICK_OP_SENT,
- GD_OP_STATE_BRICK_OP_FAILED,
- GD_OP_STATE_BRICK_COMMITTED,
- GD_OP_STATE_BRICK_COMMIT_FAILED,
- GD_OP_STATE_ACK_DRAIN,
- GD_OP_STATE_MAX,
+ GD_OP_STATE_DEFAULT = 0,
+ GD_OP_STATE_LOCK_SENT,
+ GD_OP_STATE_LOCKED,
+ GD_OP_STATE_STAGE_OP_SENT,
+ GD_OP_STATE_STAGED,
+ GD_OP_STATE_COMMIT_OP_SENT,
+ GD_OP_STATE_COMMITED,
+ GD_OP_STATE_UNLOCK_SENT,
+ GD_OP_STATE_STAGE_OP_FAILED,
+ GD_OP_STATE_COMMIT_OP_FAILED,
+ GD_OP_STATE_BRICK_OP_SENT,
+ GD_OP_STATE_BRICK_OP_FAILED,
+ GD_OP_STATE_BRICK_COMMITTED,
+ GD_OP_STATE_BRICK_COMMIT_FAILED,
+ GD_OP_STATE_ACK_DRAIN,
+ GD_OP_STATE_MAX,
} glusterd_op_sm_state_t;
typedef enum glusterd_op_sm_event_type_ {
- GD_OP_EVENT_NONE = 0,
- GD_OP_EVENT_START_LOCK,
- GD_OP_EVENT_LOCK,
- GD_OP_EVENT_RCVD_ACC,
- GD_OP_EVENT_ALL_ACC,
- GD_OP_EVENT_STAGE_ACC,
- GD_OP_EVENT_COMMIT_ACC,
- GD_OP_EVENT_RCVD_RJT,
- GD_OP_EVENT_STAGE_OP,
- GD_OP_EVENT_COMMIT_OP,
- GD_OP_EVENT_UNLOCK,
- GD_OP_EVENT_START_UNLOCK,
- GD_OP_EVENT_ALL_ACK,
- GD_OP_EVENT_LOCAL_UNLOCK_NO_RESP,
- GD_OP_EVENT_MAX
+ GD_OP_EVENT_NONE = 0,
+ GD_OP_EVENT_START_LOCK,
+ GD_OP_EVENT_LOCK,
+ GD_OP_EVENT_RCVD_ACC,
+ GD_OP_EVENT_ALL_ACC,
+ GD_OP_EVENT_STAGE_ACC,
+ GD_OP_EVENT_COMMIT_ACC,
+ GD_OP_EVENT_RCVD_RJT,
+ GD_OP_EVENT_STAGE_OP,
+ GD_OP_EVENT_COMMIT_OP,
+ GD_OP_EVENT_UNLOCK,
+ GD_OP_EVENT_START_UNLOCK,
+ GD_OP_EVENT_ALL_ACK,
+ GD_OP_EVENT_LOCAL_UNLOCK_NO_RESP,
+ GD_OP_EVENT_MAX
} glusterd_op_sm_event_type_t;
-
struct glusterd_op_sm_event_ {
- struct cds_list_head list;
- void *ctx;
- glusterd_op_sm_event_type_t event;
- uuid_t txn_id;
+ struct cds_list_head list;
+ void *ctx;
+ glusterd_op_sm_event_type_t event;
+ uuid_t txn_id;
};
typedef struct glusterd_op_sm_event_ glusterd_op_sm_event_t;
-typedef int (*glusterd_op_sm_ac_fn) (glusterd_op_sm_event_t *, void *);
+typedef int (*glusterd_op_sm_ac_fn)(glusterd_op_sm_event_t *, void *);
typedef struct glusterd_op_sm_ {
- glusterd_op_sm_state_t next_state;
- glusterd_op_sm_ac_fn handler;
+ glusterd_op_sm_state_t next_state;
+ glusterd_op_sm_ac_fn handler;
} glusterd_op_sm_t;
typedef struct glusterd_op_sm_state_info_ {
- glusterd_op_sm_state_t state;
- struct timeval time;
+ glusterd_op_sm_state_t state;
+ struct timeval time;
} glusterd_op_sm_state_info_t;
struct glusterd_op_info_ {
- glusterd_op_sm_state_info_t state;
- int32_t pending_count;
- int32_t brick_pending_count;
- int32_t op_count;
- /* op is an enum, glusterd_op_t or glusterd_op_sm_state_info_t */
- int op;
- struct cds_list_head op_peers;
- void *op_ctx;
- rpcsvc_request_t *req;
- int32_t op_ret;
- int32_t op_errno;
- char *op_errstr;
- struct cds_list_head pending_bricks;
- uint32_t txn_generation;
- gf_boolean_t skip_locking;
+ glusterd_op_sm_state_info_t state;
+ int32_t pending_count;
+ int32_t brick_pending_count;
+ int32_t op_count;
+ /* op is an enum, glusterd_op_t or glusterd_op_sm_state_info_t */
+ int op;
+ struct cds_list_head op_peers;
+ void *op_ctx;
+ rpcsvc_request_t *req;
+ int32_t op_ret;
+ int32_t op_errno;
+ char *op_errstr;
+ struct cds_list_head pending_bricks;
+ uint32_t txn_generation;
+ gf_boolean_t skip_locking;
};
typedef struct glusterd_op_info_ glusterd_op_info_t;
struct glusterd_op_log_filename_ctx_ {
- char volume_name[GD_VOLUME_NAME_MAX];
- char brick[GD_VOLUME_NAME_MAX];
- char path[PATH_MAX];
+ char volume_name[GD_VOLUME_NAME_MAX];
+ char brick[GD_VOLUME_NAME_MAX];
+ char path[PATH_MAX];
};
typedef struct glusterd_op_log_filename_ctx_ glusterd_op_log_filename_ctx_t;
struct glusterd_op_lock_ctx_ {
- uuid_t uuid;
- dict_t *dict;
- rpcsvc_request_t *req;
+ uuid_t uuid;
+ dict_t *dict;
+ rpcsvc_request_t *req;
};
typedef struct glusterd_op_lock_ctx_ glusterd_op_lock_ctx_t;
struct glusterd_req_ctx_ {
- rpcsvc_request_t *req;
- u_char uuid[16];
- int op;
- dict_t *dict;
+ rpcsvc_request_t *req;
+ u_char uuid[16];
+ int op;
+ dict_t *dict;
};
typedef struct glusterd_req_ctx_ glusterd_req_ctx_t;
typedef struct glusterd_op_brick_rsp_ctx_ {
- int op_ret;
- char *op_errstr;
- dict_t *rsp_dict;
- glusterd_req_ctx_t *commit_ctx;
- glusterd_pending_node_t *pending_node;
+ int op_ret;
+ char *op_errstr;
+ dict_t *rsp_dict;
+ glusterd_req_ctx_t *commit_ctx;
+ glusterd_pending_node_t *pending_node;
} glusterd_op_brick_rsp_ctx_t;
typedef struct glusterd_pr_brick_rsp_conv_t {
- int count;
- dict_t *dict;
+ int count;
+ dict_t *dict;
} glusterd_pr_brick_rsp_conv_t;
typedef struct glusterd_heal_rsp_conv_ {
- dict_t *dict;
- glusterd_volinfo_t *volinfo;
- xlator_t *this;
+ dict_t *dict;
+ glusterd_volinfo_t *volinfo;
+ xlator_t *this;
} glusterd_heal_rsp_conv_t;
typedef struct glusterd_status_rsp_conv_ {
- int count;
- int brick_index_max;
- int other_count;
- dict_t *dict;
+ int count;
+ int brick_index_max;
+ int other_count;
+ dict_t *dict;
} glusterd_status_rsp_conv_t;
-
typedef struct glusterd_txn_opinfo_object_ {
- glusterd_op_info_t opinfo;
+ glusterd_op_info_t opinfo;
} glusterd_txn_opinfo_obj;
typedef enum cli_cmd_type_ {
- PER_HEAL_XL,
- ALL_HEAL_XL,
- } cli_cmd_type;
+ PER_HEAL_XL,
+ ALL_HEAL_XL,
+} cli_cmd_type;
typedef struct glusterd_all_volume_options {
- char *option;
- char *dflt_val;
+ char *option;
+ char *dflt_val;
} glusterd_all_vol_opts;
int
-glusterd_op_commit_hook (glusterd_op_t op, dict_t *op_ctx,
- glusterd_commit_hook_type_t type);
+glusterd_op_commit_hook(glusterd_op_t op, dict_t *op_ctx,
+ glusterd_commit_hook_type_t type);
int
-glusterd_op_sm_new_event (glusterd_op_sm_event_type_t event_type,
- glusterd_op_sm_event_t **new_event);
+glusterd_op_sm_new_event(glusterd_op_sm_event_type_t event_type,
+ glusterd_op_sm_event_t **new_event);
int
-glusterd_op_sm_inject_event (glusterd_op_sm_event_type_t event_type,
- uuid_t *txn_id, void *ctx);
+glusterd_op_sm_inject_event(glusterd_op_sm_event_type_t event_type,
+ uuid_t *txn_id, void *ctx);
int
-glusterd_op_sm_init ();
+glusterd_op_sm_init();
int
-glusterd_op_sm ();
+glusterd_op_sm();
int32_t
-glusterd_op_set_ctx (void *ctx);
+glusterd_op_set_ctx(void *ctx);
int32_t
-glusterd_op_set_op (glusterd_op_t op);
+glusterd_op_set_op(glusterd_op_t op);
int
-glusterd_op_build_payload (dict_t **req, char **op_errstr, dict_t *op_ctx);
+glusterd_op_build_payload(dict_t **req, char **op_errstr, dict_t *op_ctx);
int32_t
-glusterd_op_stage_validate (glusterd_op_t op, dict_t *req, char **op_errstr,
- dict_t *rsp_dict);
+glusterd_op_stage_validate(glusterd_op_t op, dict_t *req, char **op_errstr,
+ dict_t *rsp_dict);
int32_t
-glusterd_op_commit_perform (glusterd_op_t op, dict_t *req, char **op_errstr,
- dict_t* dict);
+glusterd_op_commit_perform(glusterd_op_t op, dict_t *req, char **op_errstr,
+ dict_t *dict);
int32_t
-glusterd_op_txn_begin (rpcsvc_request_t *req, glusterd_op_t op, void *ctx,
- char *err_str, size_t err_len);
+glusterd_op_txn_begin(rpcsvc_request_t *req, glusterd_op_t op, void *ctx,
+ char *err_str, size_t err_len);
int32_t
-glusterd_op_txn_complete ();
+glusterd_op_txn_complete();
void *
-glusterd_op_get_ctx ();
+glusterd_op_get_ctx();
int32_t
-glusterd_op_set_req (rpcsvc_request_t *req);
+glusterd_op_set_req(rpcsvc_request_t *req);
int32_t
-glusterd_op_send_cli_response (glusterd_op_t op, int32_t op_ret,
- int32_t op_errno, rpcsvc_request_t *req,
- void *ctx, char *op_errstr);
+glusterd_op_send_cli_response(glusterd_op_t op, int32_t op_ret,
+ int32_t op_errno, rpcsvc_request_t *req,
+ void *ctx, char *op_errstr);
int32_t
-glusterd_op_get_op ();
+glusterd_op_get_op();
int32_t
-glusterd_op_clear_op ();
+glusterd_op_clear_op();
int32_t
-glusterd_op_free_ctx (glusterd_op_t op, void *ctx);
+glusterd_op_free_ctx(glusterd_op_t op, void *ctx);
int
glusterd_check_option_exists(char *optstring, char **completion);
int
-set_xlator_option (dict_t *dict, char *key, char *value);
+set_xlator_option(dict_t *dict, char *key, char *value);
-char*
-glusterd_op_sm_state_name_get (int state);
+char *
+glusterd_op_sm_state_name_get(int state);
-char*
-glusterd_op_sm_event_name_get (int event);
+char *
+glusterd_op_sm_event_name_get(int event);
int32_t
-glusterd_op_bricks_select (glusterd_op_t op, dict_t *dict, char **op_errstr,
- struct cds_list_head *selected, dict_t *rsp_dict);
+glusterd_op_bricks_select(glusterd_op_t op, dict_t *dict, char **op_errstr,
+ struct cds_list_head *selected, dict_t *rsp_dict);
int
-glusterd_brick_op_build_payload (glusterd_op_t op, glusterd_brickinfo_t *brickinfo,
- gd1_mgmt_brick_op_req **req, dict_t *dict);
+glusterd_brick_op_build_payload(glusterd_op_t op,
+ glusterd_brickinfo_t *brickinfo,
+ gd1_mgmt_brick_op_req **req, dict_t *dict);
int
-glusterd_node_op_build_payload (glusterd_op_t op, gd1_mgmt_brick_op_req **req,
+glusterd_node_op_build_payload(glusterd_op_t op, gd1_mgmt_brick_op_req **req,
dict_t *dict);
int32_t
-glusterd_handle_brick_rsp (void *pending_entry, glusterd_op_t op,
- dict_t *rsp_dict, dict_t *ctx_dict, char **op_errstr,
- gd_node_type type);
+glusterd_handle_brick_rsp(void *pending_entry, glusterd_op_t op,
+ dict_t *rsp_dict, dict_t *ctx_dict, char **op_errstr,
+ gd_node_type type);
-dict_t*
-glusterd_op_init_commit_rsp_dict (glusterd_op_t op);
+dict_t *
+glusterd_op_init_commit_rsp_dict(glusterd_op_t op);
void
-glusterd_op_modify_op_ctx (glusterd_op_t op, void *op_ctx);
+glusterd_op_modify_op_ctx(glusterd_op_t op, void *op_ctx);
void
-glusterd_op_perform_detach_tier (glusterd_volinfo_t *volinfo);
+glusterd_op_perform_detach_tier(glusterd_volinfo_t *volinfo);
int
-glusterd_set_detach_bricks (dict_t *dict, glusterd_volinfo_t *volinfo);
+glusterd_set_detach_bricks(dict_t *dict, glusterd_volinfo_t *volinfo);
int32_t
-glusterd_volume_stats_read_perf (char *brick_path, int32_t blk_size,
- int32_t blk_count, double *throughput, double *time);
+glusterd_volume_stats_read_perf(char *brick_path, int32_t blk_size,
+ int32_t blk_count, double *throughput,
+ double *time);
int32_t
-glusterd_volume_stats_write_perf (char *brick_path, int32_t blk_size,
- int32_t blk_count, double *throughput, double *time);
+glusterd_volume_stats_write_perf(char *brick_path, int32_t blk_size,
+ int32_t blk_count, double *throughput,
+ double *time);
gf_boolean_t
-glusterd_is_volume_started (glusterd_volinfo_t *volinfo);
+glusterd_is_volume_started(glusterd_volinfo_t *volinfo);
int
-glusterd_start_bricks (glusterd_volinfo_t *volinfo);
+glusterd_start_bricks(glusterd_volinfo_t *volinfo);
gf_boolean_t
-glusterd_are_all_volumes_stopped ();
+glusterd_are_all_volumes_stopped();
int
-glusterd_stop_bricks (glusterd_volinfo_t *volinfo);
+glusterd_stop_bricks(glusterd_volinfo_t *volinfo);
int
-glusterd_defrag_volume_node_rsp (dict_t *req_dict, dict_t *rsp_dict,
- dict_t *op_ctx);
+glusterd_defrag_volume_node_rsp(dict_t *req_dict, dict_t *rsp_dict,
+ dict_t *op_ctx);
#ifdef HAVE_BD_XLATOR
int
-glusterd_is_valid_vg (glusterd_brickinfo_t *brick, int check_tag, char *msg);
+glusterd_is_valid_vg(glusterd_brickinfo_t *brick, int check_tag, char *msg);
#endif
int32_t
-glusterd_get_txn_opinfo (uuid_t *txn_id, glusterd_op_info_t *opinfo);
+glusterd_get_txn_opinfo(uuid_t *txn_id, glusterd_op_info_t *opinfo);
int32_t
-glusterd_set_txn_opinfo (uuid_t *txn_id, glusterd_op_info_t *opinfo);
+glusterd_set_txn_opinfo(uuid_t *txn_id, glusterd_op_info_t *opinfo);
int32_t
-glusterd_clear_txn_opinfo (uuid_t *txn_id);
+glusterd_clear_txn_opinfo(uuid_t *txn_id);
int32_t
-glusterd_generate_txn_id (dict_t *dict, uuid_t **txn_id);
+glusterd_generate_txn_id(dict_t *dict, uuid_t **txn_id);
void
-glusterd_set_opinfo (char *errstr, int32_t op_errno, int32_t op_ret);
+glusterd_set_opinfo(char *errstr, int32_t op_errno, int32_t op_ret);
int
-glusterd_dict_set_volid (dict_t *dict, char *volname, char **op_errstr);
+glusterd_dict_set_volid(dict_t *dict, char *volname, char **op_errstr);
int32_t
-glusterd_tier_op (xlator_t *this, void *data);
+glusterd_tier_op(xlator_t *this, void *data);
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-peer-utils.h b/xlators/mgmt/glusterd/src/glusterd-peer-utils.h
index b03b136d3ca..47cbf6ee13d 100644
--- a/xlators/mgmt/glusterd/src/glusterd-peer-utils.h
+++ b/xlators/mgmt/glusterd/src/glusterd-peer-utils.h
@@ -8,86 +8,84 @@
cases as published by the Free Software Foundation.
*/
-
#ifndef _GLUSTERD_PEER_UTILS_H
#define _GLUSTERD_PEER_UTILS_H
#include "glusterd.h"
int32_t
-glusterd_peerinfo_cleanup (glusterd_peerinfo_t *peerinfo);
+glusterd_peerinfo_cleanup(glusterd_peerinfo_t *peerinfo);
glusterd_peerinfo_t *
-glusterd_peerinfo_find_by_hostname (const char *hoststr);
+glusterd_peerinfo_find_by_hostname(const char *hoststr);
int
-glusterd_hostname_to_uuid (char *hostname, uuid_t uuid);
+glusterd_hostname_to_uuid(char *hostname, uuid_t uuid);
glusterd_peerinfo_t *
-glusterd_peerinfo_find_by_uuid (uuid_t uuid);
+glusterd_peerinfo_find_by_uuid(uuid_t uuid);
glusterd_peerinfo_t *
-glusterd_peerinfo_find (uuid_t uuid, const char *hostname);
+glusterd_peerinfo_find(uuid_t uuid, const char *hostname);
glusterd_peerinfo_t *
-glusterd_peerinfo_new (glusterd_friend_sm_state_t state, uuid_t *uuid,
- const char *hostname, int port);
+glusterd_peerinfo_new(glusterd_friend_sm_state_t state, uuid_t *uuid,
+ const char *hostname, int port);
gf_boolean_t
-glusterd_chk_peers_connected_befriended (uuid_t skip_uuid);
+glusterd_chk_peers_connected_befriended(uuid_t skip_uuid);
char *
-glusterd_uuid_to_hostname (uuid_t uuid);
+glusterd_uuid_to_hostname(uuid_t uuid);
-char*
-gd_peer_uuid_str (glusterd_peerinfo_t *peerinfo);
+char *
+gd_peer_uuid_str(glusterd_peerinfo_t *peerinfo);
gf_boolean_t
-glusterd_are_all_peers_up ();
+glusterd_are_all_peers_up();
gf_boolean_t
-glusterd_are_vol_all_peers_up (glusterd_volinfo_t *volinfo,
- struct cds_list_head *peers,
- char **down_peerstr);
+glusterd_are_vol_all_peers_up(glusterd_volinfo_t *volinfo,
+ struct cds_list_head *peers, char **down_peerstr);
int32_t
-glusterd_peer_hostname_new (const char *hostname,
- glusterd_peer_hostname_t **name);
+glusterd_peer_hostname_new(const char *hostname,
+ glusterd_peer_hostname_t **name);
void
-glusterd_peer_hostname_free (glusterd_peer_hostname_t *name);
+glusterd_peer_hostname_free(glusterd_peer_hostname_t *name);
gf_boolean_t
-gd_peer_has_address (glusterd_peerinfo_t *peerinfo, const char *address);
+gd_peer_has_address(glusterd_peerinfo_t *peerinfo, const char *address);
int
-gd_add_address_to_peer (glusterd_peerinfo_t *peerinfo, const char *address);
+gd_add_address_to_peer(glusterd_peerinfo_t *peerinfo, const char *address);
int
-gd_add_friend_to_dict (glusterd_peerinfo_t *friend, dict_t *dict,
- const char *prefix);
+gd_add_friend_to_dict(glusterd_peerinfo_t *friend, dict_t *dict,
+ const char *prefix);
glusterd_peerinfo_t *
-gd_peerinfo_find_from_hostname (const char *hoststr);
+gd_peerinfo_find_from_hostname(const char *hoststr);
glusterd_peerinfo_t *
-gd_peerinfo_find_from_addrinfo (const struct addrinfo *addr);
+gd_peerinfo_find_from_addrinfo(const struct addrinfo *addr);
int
-gd_update_peerinfo_from_dict (glusterd_peerinfo_t *peerinfo, dict_t *dict,
- const char *prefix);
+gd_update_peerinfo_from_dict(glusterd_peerinfo_t *peerinfo, dict_t *dict,
+ const char *prefix);
glusterd_peerinfo_t *
-gd_peerinfo_from_dict (dict_t *dict, const char *prefix);
+gd_peerinfo_from_dict(dict_t *dict, const char *prefix);
int
-gd_add_peer_hostnames_to_dict (glusterd_peerinfo_t *peerinfo, dict_t *dict,
- const char *prefix);
+gd_add_peer_hostnames_to_dict(glusterd_peerinfo_t *peerinfo, dict_t *dict,
+ const char *prefix);
int
-gd_add_peer_detail_to_dict (glusterd_peerinfo_t *peerinfo, dict_t *friends,
- int count);
+gd_add_peer_detail_to_dict(glusterd_peerinfo_t *peerinfo, dict_t *friends,
+ int count);
glusterd_peerinfo_t *
-glusterd_peerinfo_find_by_generation (uint32_t generation);
+glusterd_peerinfo_find_by_generation(uint32_t generation);
int
-glusterd_get_peers_count ();
+glusterd_get_peers_count();
#endif /* _GLUSTERD_PEER_UTILS_H */
diff --git a/xlators/mgmt/glusterd/src/glusterd-pmap.h b/xlators/mgmt/glusterd/src/glusterd-pmap.h
index 04004c2b2af..8a3ebac48a0 100644
--- a/xlators/mgmt/glusterd/src/glusterd-pmap.h
+++ b/xlators/mgmt/glusterd/src/glusterd-pmap.h
@@ -20,31 +20,38 @@
#include "byte-order.h"
#include "rpcsvc.h"
-
struct pmap_port_status {
- gf_pmap_port_type_t type;
- char *brickname;
- void *xprt;
+ gf_pmap_port_type_t type;
+ char *brickname;
+ void *xprt;
};
struct pmap_registry {
- int base_port;
- int max_port;
- int last_alloc;
- struct pmap_port_status ports[GF_PORT_MAX + 1];
+ int base_port;
+ int max_port;
+ int last_alloc;
+ struct pmap_port_status ports[GF_PORT_MAX + 1];
};
-int pmap_assign_port (xlator_t *this, int port, const char *path);
-int pmap_mark_port_leased (xlator_t *this, int port);
-int pmap_registry_alloc (xlator_t *this);
-int pmap_registry_bind (xlator_t *this, int port, const char *brickname,
- gf_pmap_port_type_t type, void *xprt);
-int pmap_registry_extend (xlator_t *this, int port, const char *brickname);
-int pmap_registry_remove (xlator_t *this, int port, const char *brickname,
- gf_pmap_port_type_t type, void *xprt,
- gf_boolean_t brick_disconnect);
-int pmap_registry_search (xlator_t *this, const char *brickname,
- gf_pmap_port_type_t type, gf_boolean_t destroy);
-struct pmap_registry *pmap_registry_get (xlator_t *this);
+int
+pmap_assign_port(xlator_t *this, int port, const char *path);
+int
+pmap_mark_port_leased(xlator_t *this, int port);
+int
+pmap_registry_alloc(xlator_t *this);
+int
+pmap_registry_bind(xlator_t *this, int port, const char *brickname,
+ gf_pmap_port_type_t type, void *xprt);
+int
+pmap_registry_extend(xlator_t *this, int port, const char *brickname);
+int
+pmap_registry_remove(xlator_t *this, int port, const char *brickname,
+ gf_pmap_port_type_t type, void *xprt,
+ gf_boolean_t brick_disconnect);
+int
+pmap_registry_search(xlator_t *this, const char *brickname,
+ gf_pmap_port_type_t type, gf_boolean_t destroy);
+struct pmap_registry *
+pmap_registry_get(xlator_t *this);
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-proc-mgmt.h b/xlators/mgmt/glusterd/src/glusterd-proc-mgmt.h
index f5235171816..36ad5ae6731 100644
--- a/xlators/mgmt/glusterd/src/glusterd-proc-mgmt.h
+++ b/xlators/mgmt/glusterd/src/glusterd-proc-mgmt.h
@@ -14,31 +14,31 @@
typedef struct glusterd_proc_ glusterd_proc_t;
enum proc_flags {
- PROC_NONE = 0,
- PROC_START,
- PROC_START_NO_WAIT,
- PROC_STOP,
- PROC_STOP_FORCE
+ PROC_NONE = 0,
+ PROC_START,
+ PROC_START_NO_WAIT,
+ PROC_STOP,
+ PROC_STOP_FORCE
};
struct glusterd_proc_ {
- char name[PATH_MAX];
- char pidfile[PATH_MAX];
- char logdir[PATH_MAX];
- char logfile[PATH_MAX];
- char volfile[PATH_MAX];
- char volfileserver[PATH_MAX];
- char volfileid[256];
+ char name[PATH_MAX];
+ char pidfile[PATH_MAX];
+ char logdir[PATH_MAX];
+ char logfile[PATH_MAX];
+ char volfile[PATH_MAX];
+ char volfileserver[PATH_MAX];
+ char volfileid[256];
};
int
-glusterd_proc_init (glusterd_proc_t *proc, char *name, char *pidfile,
- char *logdir, char *logfile, char *volfile, char *volfileid,
- char *volfileserver);
+glusterd_proc_init(glusterd_proc_t *proc, char *name, char *pidfile,
+ char *logdir, char *logfile, char *volfile, char *volfileid,
+ char *volfileserver);
int
-glusterd_proc_stop (glusterd_proc_t *proc, int sig, int flags);
+glusterd_proc_stop(glusterd_proc_t *proc, int sig, int flags);
int
-glusterd_proc_is_running (glusterd_proc_t *proc);
+glusterd_proc_is_running(glusterd_proc_t *proc);
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-quota.h b/xlators/mgmt/glusterd/src/glusterd-quota.h
index 9efff41b436..ab2092a9c6a 100644
--- a/xlators/mgmt/glusterd/src/glusterd-quota.h
+++ b/xlators/mgmt/glusterd/src/glusterd-quota.h
@@ -11,7 +11,7 @@
#define _GLUSTERD_QUOTA_
int
-glusterd_store_quota_config (glusterd_volinfo_t *volinfo, char *path,
- char *gfid_str, int opcode, char **op_errstr);
+glusterd_store_quota_config(glusterd_volinfo_t *volinfo, char *path,
+ char *gfid_str, int opcode, char **op_errstr);
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-quotad-svc.h b/xlators/mgmt/glusterd/src/glusterd-quotad-svc.h
index 91da50dc36d..e8d9bbee964 100644
--- a/xlators/mgmt/glusterd/src/glusterd-quotad-svc.h
+++ b/xlators/mgmt/glusterd/src/glusterd-quotad-svc.h
@@ -14,18 +14,18 @@
#include "glusterd-svc-mgmt.h"
void
-glusterd_quotadsvc_build (glusterd_svc_t *svc);
+glusterd_quotadsvc_build(glusterd_svc_t *svc);
int
-glusterd_quotadsvc_init (glusterd_svc_t *svc);
+glusterd_quotadsvc_init(glusterd_svc_t *svc);
int
-glusterd_quotadsvc_start (glusterd_svc_t *svc, int flags);
+glusterd_quotadsvc_start(glusterd_svc_t *svc, int flags);
int
-glusterd_quotadsvc_manager (glusterd_svc_t *svc, void *data, int flags);
+glusterd_quotadsvc_manager(glusterd_svc_t *svc, void *data, int flags);
int
-glusterd_quotadsvc_reconfigure ();
+glusterd_quotadsvc_reconfigure();
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-rcu.h b/xlators/mgmt/glusterd/src/glusterd-rcu.h
index 15beac5a745..32ac3bbfd4e 100644
--- a/xlators/mgmt/glusterd/src/glusterd-rcu.h
+++ b/xlators/mgmt/glusterd/src/glusterd-rcu.h
@@ -29,8 +29,8 @@
* Use this in place of struct rcu_head when embedding into another struct
*/
typedef struct glusterd_rcu_head_ {
- struct rcu_head head;
- xlator_t *this;
+ struct rcu_head head;
+ xlator_t *this;
} gd_rcu_head;
#endif /* _GLUSTERD_RCU_H */
diff --git a/xlators/mgmt/glusterd/src/glusterd-scrub-svc.h b/xlators/mgmt/glusterd/src/glusterd-scrub-svc.h
index dbdcf43529c..514b1de96a0 100644
--- a/xlators/mgmt/glusterd/src/glusterd-scrub-svc.h
+++ b/xlators/mgmt/glusterd/src/glusterd-scrub-svc.h
@@ -15,31 +15,31 @@
typedef struct glusterd_scrubsvc_ glusterd_scrubsvc_t;
-struct glusterd_scrubsvc_{
- glusterd_svc_t svc;
- gf_store_handle_t *handle;
+struct glusterd_scrubsvc_ {
+ glusterd_svc_t svc;
+ gf_store_handle_t *handle;
};
void
-glusterd_scrubsvc_build (glusterd_svc_t *svc);
+glusterd_scrubsvc_build(glusterd_svc_t *svc);
int
-glusterd_scrubsvc_init (glusterd_svc_t *svc);
+glusterd_scrubsvc_init(glusterd_svc_t *svc);
int
-glusterd_scrubsvc_manager (glusterd_svc_t *svc, void *data, int flags);
+glusterd_scrubsvc_manager(glusterd_svc_t *svc, void *data, int flags);
int
-glusterd_scrubsvc_start (glusterd_svc_t *svc, int flags);
+glusterd_scrubsvc_start(glusterd_svc_t *svc, int flags);
int
-glusterd_scrubsvc_stop (glusterd_svc_t *svc, int sig);
+glusterd_scrubsvc_stop(glusterd_svc_t *svc, int sig);
int
-glusterd_scrubsvc_reconfigure ();
+glusterd_scrubsvc_reconfigure();
void
-glusterd_scrubsvc_build_volfile_path (char *server, char *workdir,
- char *volfile, size_t len);
+glusterd_scrubsvc_build_volfile_path(char *server, char *workdir, char *volfile,
+ size_t len);
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-server-quorum.h b/xlators/mgmt/glusterd/src/glusterd-server-quorum.h
index ea6a8bd6158..e11bf1a9206 100644
--- a/xlators/mgmt/glusterd/src/glusterd-server-quorum.h
+++ b/xlators/mgmt/glusterd/src/glusterd-server-quorum.h
@@ -11,36 +11,36 @@
#define _GLUSTERD_SERVER_QUORUM_H
int
-glusterd_validate_quorum (xlator_t *this, glusterd_op_t op, dict_t *dict,
- char **op_errstr);
+glusterd_validate_quorum(xlator_t *this, glusterd_op_t op, dict_t *dict,
+ char **op_errstr);
gf_boolean_t
-glusterd_is_quorum_changed (dict_t *options, char *option, char *value);
+glusterd_is_quorum_changed(dict_t *options, char *option, char *value);
int
-glusterd_do_quorum_action ();
+glusterd_do_quorum_action();
int
-glusterd_get_quorum_cluster_counts (xlator_t *this, int *active_count,
- int *quorum_count);
+glusterd_get_quorum_cluster_counts(xlator_t *this, int *active_count,
+ int *quorum_count);
gf_boolean_t
-glusterd_is_quorum_option (char *option);
+glusterd_is_quorum_option(char *option);
gf_boolean_t
-glusterd_is_volume_in_server_quorum (glusterd_volinfo_t *volinfo);
+glusterd_is_volume_in_server_quorum(glusterd_volinfo_t *volinfo);
gf_boolean_t
-glusterd_is_any_volume_in_server_quorum (xlator_t *this);
+glusterd_is_any_volume_in_server_quorum(xlator_t *this);
gf_boolean_t
-does_gd_meet_server_quorum (xlator_t *this);
+does_gd_meet_server_quorum(xlator_t *this);
int
-check_quorum_for_brick_start (glusterd_volinfo_t *volinfo,
- gf_boolean_t node_quorum);
+check_quorum_for_brick_start(glusterd_volinfo_t *volinfo,
+ gf_boolean_t node_quorum);
gf_boolean_t
-does_quorum_meet (int active_count, int quorum_count);
+does_quorum_meet(int active_count, int quorum_count);
#endif /* _GLUSTERD_SERVER_QUORUM_H */
diff --git a/xlators/mgmt/glusterd/src/glusterd-shd-svc.h b/xlators/mgmt/glusterd/src/glusterd-shd-svc.h
index 38a3fd1afd1..775a9d44a2c 100644
--- a/xlators/mgmt/glusterd/src/glusterd-shd-svc.h
+++ b/xlators/mgmt/glusterd/src/glusterd-shd-svc.h
@@ -14,17 +14,17 @@
#include "glusterd-svc-mgmt.h"
void
-glusterd_shdsvc_build (glusterd_svc_t *svc);
+glusterd_shdsvc_build(glusterd_svc_t *svc);
int
-glusterd_shdsvc_init (glusterd_svc_t *svc);
+glusterd_shdsvc_init(glusterd_svc_t *svc);
int
-glusterd_shdsvc_manager (glusterd_svc_t *svc, void *data, int flags);
+glusterd_shdsvc_manager(glusterd_svc_t *svc, void *data, int flags);
int
-glusterd_shdsvc_start (glusterd_svc_t *svc, int flags);
+glusterd_shdsvc_start(glusterd_svc_t *svc, int flags);
int
-glusterd_shdsvc_reconfigure ();
+glusterd_shdsvc_reconfigure();
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-sm.h b/xlators/mgmt/glusterd/src/glusterd-sm.h
index 640468830d5..051e83c675d 100644
--- a/xlators/mgmt/glusterd/src/glusterd-sm.h
+++ b/xlators/mgmt/glusterd/src/glusterd-sm.h
@@ -26,196 +26,194 @@
#include "glusterd-rcu.h"
typedef enum gd_quorum_contribution_ {
- QUORUM_NONE,
- QUORUM_WAITING,
- QUORUM_DOWN,
- QUORUM_UP
+ QUORUM_NONE,
+ QUORUM_WAITING,
+ QUORUM_DOWN,
+ QUORUM_UP
} gd_quorum_contrib_t;
typedef enum glusterd_friend_sm_state_ {
- GD_FRIEND_STATE_DEFAULT = 0,
- GD_FRIEND_STATE_REQ_SENT,
- GD_FRIEND_STATE_REQ_RCVD,
- GD_FRIEND_STATE_BEFRIENDED,
- GD_FRIEND_STATE_REQ_ACCEPTED,
- GD_FRIEND_STATE_REQ_SENT_RCVD,
- GD_FRIEND_STATE_REJECTED,
- GD_FRIEND_STATE_UNFRIEND_SENT,
- GD_FRIEND_STATE_PROBE_RCVD,
- GD_FRIEND_STATE_CONNECTED_RCVD,
- GD_FRIEND_STATE_CONNECTED_ACCEPTED,
- GD_FRIEND_STATE_MAX
+ GD_FRIEND_STATE_DEFAULT = 0,
+ GD_FRIEND_STATE_REQ_SENT,
+ GD_FRIEND_STATE_REQ_RCVD,
+ GD_FRIEND_STATE_BEFRIENDED,
+ GD_FRIEND_STATE_REQ_ACCEPTED,
+ GD_FRIEND_STATE_REQ_SENT_RCVD,
+ GD_FRIEND_STATE_REJECTED,
+ GD_FRIEND_STATE_UNFRIEND_SENT,
+ GD_FRIEND_STATE_PROBE_RCVD,
+ GD_FRIEND_STATE_CONNECTED_RCVD,
+ GD_FRIEND_STATE_CONNECTED_ACCEPTED,
+ GD_FRIEND_STATE_MAX
} glusterd_friend_sm_state_t;
typedef struct glusterd_peer_state_info_ {
- glusterd_friend_sm_state_t state;
- struct timeval transition_time;
-}glusterd_peer_state_info_t;
+ glusterd_friend_sm_state_t state;
+ struct timeval transition_time;
+} glusterd_peer_state_info_t;
typedef struct glusterd_peer_hostname_ {
- char *hostname;
- struct cds_list_head hostname_list;
+ char *hostname;
+ struct cds_list_head hostname_list;
} glusterd_peer_hostname_t;
typedef struct glusterd_sm_transition_ {
- int old_state;
- int event;
- int new_state;
- time_t time;
+ int old_state;
+ int event;
+ int new_state;
+ time_t time;
} glusterd_sm_transition_t;
typedef struct glusterd_sm_tr_log_ {
- glusterd_sm_transition_t *transitions;
- size_t current;
- size_t size;
- size_t count;
- char* (*state_name_get) (int);
- char* (*event_name_get) (int);
+ glusterd_sm_transition_t *transitions;
+ size_t current;
+ size_t size;
+ size_t count;
+ char *(*state_name_get)(int);
+ char *(*event_name_get)(int);
} glusterd_sm_tr_log_t;
struct glusterd_peerinfo_ {
- uuid_t uuid;
- char uuid_str[50]; /* Retrieve this using
- * gd_peer_uuid_str ()
- */
- glusterd_peer_state_info_t state;
- char *hostname;
- struct cds_list_head hostnames;
- int port;
- struct cds_list_head uuid_list;
- struct cds_list_head op_peers_list;
- struct rpc_clnt *rpc;
- rpc_clnt_prog_t *mgmt;
- rpc_clnt_prog_t *peer;
- rpc_clnt_prog_t *mgmt_v3;
- int connected;
- gf_store_handle_t *shandle;
- glusterd_sm_tr_log_t sm_log;
- gf_boolean_t quorum_action;
- gd_quorum_contrib_t quorum_contrib;
- gf_boolean_t locked;
- gf_boolean_t detaching;
- /* Members required for proper cleanup using RCU */
- gd_rcu_head rcu_head;
- pthread_mutex_t delete_lock;
- uint32_t generation;
+ uuid_t uuid;
+ char uuid_str[50]; /* Retrieve this using
+ * gd_peer_uuid_str ()
+ */
+ glusterd_peer_state_info_t state;
+ char *hostname;
+ struct cds_list_head hostnames;
+ int port;
+ struct cds_list_head uuid_list;
+ struct cds_list_head op_peers_list;
+ struct rpc_clnt *rpc;
+ rpc_clnt_prog_t *mgmt;
+ rpc_clnt_prog_t *peer;
+ rpc_clnt_prog_t *mgmt_v3;
+ int connected;
+ gf_store_handle_t *shandle;
+ glusterd_sm_tr_log_t sm_log;
+ gf_boolean_t quorum_action;
+ gd_quorum_contrib_t quorum_contrib;
+ gf_boolean_t locked;
+ gf_boolean_t detaching;
+ /* Members required for proper cleanup using RCU */
+ gd_rcu_head rcu_head;
+ pthread_mutex_t delete_lock;
+ uint32_t generation;
};
typedef struct glusterd_peerinfo_ glusterd_peerinfo_t;
typedef struct glusterd_local_peers_ {
- glusterd_peerinfo_t *peerinfo;
- struct cds_list_head op_peers_list;
+ glusterd_peerinfo_t *peerinfo;
+ struct cds_list_head op_peers_list;
} glusterd_local_peers_t;
typedef enum glusterd_ev_gen_mode_ {
- GD_MODE_OFF,
- GD_MODE_ON,
- GD_MODE_SWITCH_ON
+ GD_MODE_OFF,
+ GD_MODE_ON,
+ GD_MODE_SWITCH_ON
} glusterd_ev_gen_mode_t;
typedef struct glusterd_peer_ctx_args_ {
- rpcsvc_request_t *req;
- glusterd_ev_gen_mode_t mode;
- dict_t *dict;
+ rpcsvc_request_t *req;
+ glusterd_ev_gen_mode_t mode;
+ dict_t *dict;
} glusterd_peerctx_args_t;
typedef struct glusterd_peer_ctx_ {
- glusterd_peerctx_args_t args;
- uuid_t peerid;
- char *peername;
- uint32_t peerinfo_gen;
- char *errstr;
+ glusterd_peerctx_args_t args;
+ uuid_t peerid;
+ char *peername;
+ uint32_t peerinfo_gen;
+ char *errstr;
} glusterd_peerctx_t;
typedef enum glusterd_friend_sm_event_type_ {
- GD_FRIEND_EVENT_NONE = 0,
- GD_FRIEND_EVENT_PROBE,
- GD_FRIEND_EVENT_INIT_FRIEND_REQ,
- GD_FRIEND_EVENT_RCVD_ACC,
- GD_FRIEND_EVENT_LOCAL_ACC,
- GD_FRIEND_EVENT_RCVD_RJT,
- GD_FRIEND_EVENT_LOCAL_RJT,
- GD_FRIEND_EVENT_RCVD_FRIEND_REQ,
- GD_FRIEND_EVENT_INIT_REMOVE_FRIEND,
- GD_FRIEND_EVENT_RCVD_REMOVE_FRIEND,
- GD_FRIEND_EVENT_REMOVE_FRIEND,
- GD_FRIEND_EVENT_CONNECTED,
- GD_FRIEND_EVENT_NEW_NAME,
- GD_FRIEND_EVENT_MAX
+ GD_FRIEND_EVENT_NONE = 0,
+ GD_FRIEND_EVENT_PROBE,
+ GD_FRIEND_EVENT_INIT_FRIEND_REQ,
+ GD_FRIEND_EVENT_RCVD_ACC,
+ GD_FRIEND_EVENT_LOCAL_ACC,
+ GD_FRIEND_EVENT_RCVD_RJT,
+ GD_FRIEND_EVENT_LOCAL_RJT,
+ GD_FRIEND_EVENT_RCVD_FRIEND_REQ,
+ GD_FRIEND_EVENT_INIT_REMOVE_FRIEND,
+ GD_FRIEND_EVENT_RCVD_REMOVE_FRIEND,
+ GD_FRIEND_EVENT_REMOVE_FRIEND,
+ GD_FRIEND_EVENT_CONNECTED,
+ GD_FRIEND_EVENT_NEW_NAME,
+ GD_FRIEND_EVENT_MAX
} glusterd_friend_sm_event_type_t;
-
typedef enum glusterd_friend_update_op_ {
- GD_FRIEND_UPDATE_NONE = 0,
- GD_FRIEND_UPDATE_ADD,
- GD_FRIEND_UPDATE_DEL,
+ GD_FRIEND_UPDATE_NONE = 0,
+ GD_FRIEND_UPDATE_ADD,
+ GD_FRIEND_UPDATE_DEL,
} glusterd_friend_update_op_t;
-
struct glusterd_friend_sm_event_ {
- struct cds_list_head list;
- uuid_t peerid;
- char *peername;
- void *ctx;
- glusterd_friend_sm_event_type_t event;
+ struct cds_list_head list;
+ uuid_t peerid;
+ char *peername;
+ void *ctx;
+ glusterd_friend_sm_event_type_t event;
};
typedef struct glusterd_friend_sm_event_ glusterd_friend_sm_event_t;
-typedef int (*glusterd_friend_sm_ac_fn) (glusterd_friend_sm_event_t *, void *);
+typedef int (*glusterd_friend_sm_ac_fn)(glusterd_friend_sm_event_t *, void *);
typedef struct glusterd_sm_ {
- glusterd_friend_sm_state_t next_state;
- glusterd_friend_sm_ac_fn handler;
+ glusterd_friend_sm_state_t next_state;
+ glusterd_friend_sm_ac_fn handler;
} glusterd_sm_t;
typedef struct glusterd_friend_req_ctx_ {
- uuid_t uuid;
- char *hostname;
- rpcsvc_request_t *req;
- int port;
- dict_t *vols;
+ uuid_t uuid;
+ char *hostname;
+ rpcsvc_request_t *req;
+ int port;
+ dict_t *vols;
} glusterd_friend_req_ctx_t;
typedef struct glusterd_friend_update_ctx_ {
- uuid_t uuid;
- char *hostname;
- int op;
+ uuid_t uuid;
+ char *hostname;
+ int op;
} glusterd_friend_update_ctx_t;
typedef struct glusterd_probe_ctx_ {
- char *hostname;
- rpcsvc_request_t *req;
- int port;
- dict_t *dict;
+ char *hostname;
+ rpcsvc_request_t *req;
+ int port;
+ dict_t *dict;
} glusterd_probe_ctx_t;
int
-glusterd_friend_sm_new_event (glusterd_friend_sm_event_type_t event_type,
- glusterd_friend_sm_event_t **new_event);
+glusterd_friend_sm_new_event(glusterd_friend_sm_event_type_t event_type,
+ glusterd_friend_sm_event_t **new_event);
int
-glusterd_friend_sm_inject_event (glusterd_friend_sm_event_t *event);
+glusterd_friend_sm_inject_event(glusterd_friend_sm_event_t *event);
int
-glusterd_friend_sm_init ();
+glusterd_friend_sm_init();
int
-glusterd_friend_sm ();
+glusterd_friend_sm();
void
-glusterd_destroy_probe_ctx (glusterd_probe_ctx_t *ctx);
+glusterd_destroy_probe_ctx(glusterd_probe_ctx_t *ctx);
void
-glusterd_destroy_friend_req_ctx (glusterd_friend_req_ctx_t *ctx);
+glusterd_destroy_friend_req_ctx(glusterd_friend_req_ctx_t *ctx);
-char*
-glusterd_friend_sm_state_name_get (int state);
+char *
+glusterd_friend_sm_state_name_get(int state);
-char*
-glusterd_friend_sm_event_name_get (int event);
+char *
+glusterd_friend_sm_event_name_get(int event);
int
-glusterd_broadcast_friend_delete (char *hostname, uuid_t uuid);
+glusterd_broadcast_friend_delete(char *hostname, uuid_t uuid);
void
-glusterd_destroy_friend_update_ctx (glusterd_friend_update_ctx_t *ctx);
+glusterd_destroy_friend_update_ctx(glusterd_friend_update_ctx_t *ctx);
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-snapd-svc-helper.h b/xlators/mgmt/glusterd/src/glusterd-snapd-svc-helper.h
index 4c452b91658..3e23c2ce942 100644
--- a/xlators/mgmt/glusterd/src/glusterd-snapd-svc-helper.h
+++ b/xlators/mgmt/glusterd/src/glusterd-snapd-svc-helper.h
@@ -14,19 +14,19 @@
#include "glusterd.h"
void
-glusterd_svc_build_snapd_rundir (glusterd_volinfo_t *volinfo,
- char *path, int path_len);
+glusterd_svc_build_snapd_rundir(glusterd_volinfo_t *volinfo, char *path,
+ int path_len);
void
-glusterd_svc_build_snapd_socket_filepath (glusterd_volinfo_t *volinfo,
- char *path, int path_len);
+glusterd_svc_build_snapd_socket_filepath(glusterd_volinfo_t *volinfo,
+ char *path, int path_len);
void
-glusterd_svc_build_snapd_pidfile (glusterd_volinfo_t *volinfo,
- char *path, int path_len);
+glusterd_svc_build_snapd_pidfile(glusterd_volinfo_t *volinfo, char *path,
+ int path_len);
void
-glusterd_svc_build_snapd_volfile (glusterd_volinfo_t *volinfo,
- char *path, int path_len);
+glusterd_svc_build_snapd_volfile(glusterd_volinfo_t *volinfo, char *path,
+ int path_len);
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-snapd-svc.h b/xlators/mgmt/glusterd/src/glusterd-snapd-svc.h
index 40dae848f58..c95e4cc7661 100644
--- a/xlators/mgmt/glusterd/src/glusterd-snapd-svc.h
+++ b/xlators/mgmt/glusterd/src/glusterd-snapd-svc.h
@@ -15,28 +15,28 @@
typedef struct glusterd_snapdsvc_ glusterd_snapdsvc_t;
-struct glusterd_snapdsvc_{
- glusterd_svc_t svc;
- int port;
- gf_store_handle_t *handle;
+struct glusterd_snapdsvc_ {
+ glusterd_svc_t svc;
+ int port;
+ gf_store_handle_t *handle;
};
void
-glusterd_snapdsvc_build (glusterd_svc_t *svc);
+glusterd_snapdsvc_build(glusterd_svc_t *svc);
int
-glusterd_snapdsvc_init (void *data);
+glusterd_snapdsvc_init(void *data);
int
-glusterd_snapdsvc_manager (glusterd_svc_t *svc, void *data, int flags);
+glusterd_snapdsvc_manager(glusterd_svc_t *svc, void *data, int flags);
int
-glusterd_snapdsvc_start (glusterd_svc_t *svc, int flags);
+glusterd_snapdsvc_start(glusterd_svc_t *svc, int flags);
int
-glusterd_snapdsvc_restart ();
+glusterd_snapdsvc_restart();
int
-glusterd_snapdsvc_rpc_notify (glusterd_conn_t *conn, rpc_clnt_event_t event);
+glusterd_snapdsvc_rpc_notify(glusterd_conn_t *conn, rpc_clnt_event_t event);
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-snapshot-utils.h b/xlators/mgmt/glusterd/src/glusterd-snapshot-utils.h
index d619f1d3106..19fedecee8d 100644
--- a/xlators/mgmt/glusterd/src/glusterd-snapshot-utils.h
+++ b/xlators/mgmt/glusterd/src/glusterd-snapshot-utils.h
@@ -11,154 +11,149 @@
#define _GLUSTERD_SNAP_UTILS_H
int32_t
-glusterd_snap_volinfo_find (char *volname, glusterd_snap_t *snap,
- glusterd_volinfo_t **volinfo);
+glusterd_snap_volinfo_find(char *volname, glusterd_snap_t *snap,
+ glusterd_volinfo_t **volinfo);
int32_t
-glusterd_snap_volinfo_find_from_parent_volname (char *origin_volname,
- glusterd_snap_t *snap,
- glusterd_volinfo_t **volinfo);
+glusterd_snap_volinfo_find_from_parent_volname(char *origin_volname,
+ glusterd_snap_t *snap,
+ glusterd_volinfo_t **volinfo);
int
-glusterd_snap_volinfo_find_by_volume_id (uuid_t volume_id,
- glusterd_volinfo_t **volinfo);
+glusterd_snap_volinfo_find_by_volume_id(uuid_t volume_id,
+ glusterd_volinfo_t **volinfo);
int32_t
-glusterd_add_snapd_to_dict (glusterd_volinfo_t *volinfo,
- dict_t *dict, int32_t count);
+glusterd_add_snapd_to_dict(glusterd_volinfo_t *volinfo, dict_t *dict,
+ int32_t count);
int
-glusterd_compare_snap_time (struct cds_list_head *, struct cds_list_head *);
+glusterd_compare_snap_time(struct cds_list_head *, struct cds_list_head *);
int
-glusterd_compare_snap_vol_time (struct cds_list_head *, struct cds_list_head *);
+glusterd_compare_snap_vol_time(struct cds_list_head *, struct cds_list_head *);
int32_t
-glusterd_snap_volinfo_restore (dict_t *dict, dict_t *rsp_dict,
- glusterd_volinfo_t *new_volinfo,
- glusterd_volinfo_t *snap_volinfo,
- int32_t volcount);
+glusterd_snap_volinfo_restore(dict_t *dict, dict_t *rsp_dict,
+ glusterd_volinfo_t *new_volinfo,
+ glusterd_volinfo_t *snap_volinfo,
+ int32_t volcount);
int32_t
-glusterd_snapobject_delete (glusterd_snap_t *snap);
+glusterd_snapobject_delete(glusterd_snap_t *snap);
int32_t
-glusterd_cleanup_snaps_for_volume (glusterd_volinfo_t *volinfo);
+glusterd_cleanup_snaps_for_volume(glusterd_volinfo_t *volinfo);
int32_t
-glusterd_missed_snapinfo_new (glusterd_missed_snap_info **missed_snapinfo);
+glusterd_missed_snapinfo_new(glusterd_missed_snap_info **missed_snapinfo);
int32_t
-glusterd_missed_snap_op_new (glusterd_snap_op_t **snap_op);
+glusterd_missed_snap_op_new(glusterd_snap_op_t **snap_op);
int32_t
-glusterd_add_missed_snaps_to_dict (dict_t *rsp_dict,
- glusterd_volinfo_t *snap_vol,
- glusterd_brickinfo_t *brickinfo,
- int32_t brick_number, int32_t op);
+glusterd_add_missed_snaps_to_dict(dict_t *rsp_dict,
+ glusterd_volinfo_t *snap_vol,
+ glusterd_brickinfo_t *brickinfo,
+ int32_t brick_number, int32_t op);
int32_t
-glusterd_add_missed_snaps_to_export_dict (dict_t *peer_data);
+glusterd_add_missed_snaps_to_export_dict(dict_t *peer_data);
int32_t
-glusterd_import_friend_missed_snap_list (dict_t *peer_data);
+glusterd_import_friend_missed_snap_list(dict_t *peer_data);
int
-gd_restore_snap_volume (dict_t *dict, dict_t *rsp_dict,
- glusterd_volinfo_t *orig_vol,
- glusterd_volinfo_t *snap_vol,
- int32_t volcount);
+gd_restore_snap_volume(dict_t *dict, dict_t *rsp_dict,
+ glusterd_volinfo_t *orig_vol,
+ glusterd_volinfo_t *snap_vol, int32_t volcount);
int32_t
-glusterd_mount_lvm_snapshot (glusterd_brickinfo_t *brickinfo,
- char *brick_mount_path);
+glusterd_mount_lvm_snapshot(glusterd_brickinfo_t *brickinfo,
+ char *brick_mount_path);
int32_t
-glusterd_umount (const char *path);
+glusterd_umount(const char *path);
int32_t
-glusterd_snap_unmount (xlator_t *this, glusterd_volinfo_t *volinfo);
+glusterd_snap_unmount(xlator_t *this, glusterd_volinfo_t *volinfo);
int32_t
-glusterd_add_snapshots_to_export_dict (dict_t *peer_data);
+glusterd_add_snapshots_to_export_dict(dict_t *peer_data);
int32_t
-glusterd_compare_friend_snapshots (dict_t *peer_data, char *peername,
- uuid_t peerid);
+glusterd_compare_friend_snapshots(dict_t *peer_data, char *peername,
+ uuid_t peerid);
int32_t
-glusterd_store_create_snap_dir (glusterd_snap_t *snap);
+glusterd_store_create_snap_dir(glusterd_snap_t *snap);
int32_t
-glusterd_copy_file (const char *source, const char *destination);
+glusterd_copy_file(const char *source, const char *destination);
int32_t
-glusterd_copy_folder (const char *source, const char *destination);
+glusterd_copy_folder(const char *source, const char *destination);
int32_t
-glusterd_get_geo_rep_session (char *slave_key, char *origin_volname,
- dict_t *gsync_slaves_dict, char *session,
- char *slave);
+glusterd_get_geo_rep_session(char *slave_key, char *origin_volname,
+ dict_t *gsync_slaves_dict, char *session,
+ char *slave);
int32_t
-glusterd_restore_geo_rep_files (glusterd_volinfo_t *snap_vol);
+glusterd_restore_geo_rep_files(glusterd_volinfo_t *snap_vol);
int32_t
-glusterd_copy_quota_files (glusterd_volinfo_t *src_vol,
- glusterd_volinfo_t *dest_vol,
- gf_boolean_t *conf_present);
+glusterd_copy_quota_files(glusterd_volinfo_t *src_vol,
+ glusterd_volinfo_t *dest_vol,
+ gf_boolean_t *conf_present);
int
-glusterd_snap_use_rsp_dict (dict_t *aggr, dict_t *rsp_dict);
+glusterd_snap_use_rsp_dict(dict_t *aggr, dict_t *rsp_dict);
int
-gd_add_vol_snap_details_to_dict (dict_t *dict, char *prefix,
- glusterd_volinfo_t *volinfo);
+gd_add_vol_snap_details_to_dict(dict_t *dict, char *prefix,
+ glusterd_volinfo_t *volinfo);
int
-gd_add_brick_snap_details_to_dict (dict_t *dict, char *prefix,
- glusterd_brickinfo_t *brickinfo);
+gd_add_brick_snap_details_to_dict(dict_t *dict, char *prefix,
+ glusterd_brickinfo_t *brickinfo);
int
-gd_import_new_brick_snap_details (dict_t *dict, char *prefix,
- glusterd_brickinfo_t *brickinfo);
+gd_import_new_brick_snap_details(dict_t *dict, char *prefix,
+ glusterd_brickinfo_t *brickinfo);
int
-gd_import_volume_snap_details (dict_t *dict, glusterd_volinfo_t *volinfo,
- char *prefix, char *volname);
+gd_import_volume_snap_details(dict_t *dict, glusterd_volinfo_t *volinfo,
+ char *prefix, char *volname);
int32_t
-glusterd_snap_quorum_check (dict_t *dict, gf_boolean_t snap_volume,
- char **op_errstr, uint32_t *op_errno);
+glusterd_snap_quorum_check(dict_t *dict, gf_boolean_t snap_volume,
+ char **op_errstr, uint32_t *op_errno);
int32_t
-glusterd_snap_brick_create (glusterd_volinfo_t *snap_volinfo,
- glusterd_brickinfo_t *brickinfo,
- int32_t brick_count, int32_t clone);
+glusterd_snap_brick_create(glusterd_volinfo_t *snap_volinfo,
+ glusterd_brickinfo_t *brickinfo, int32_t brick_count,
+ int32_t clone);
int
-glusterd_snapshot_restore_cleanup (dict_t *rsp_dict,
- char *volname,
- glusterd_snap_t *snap);
+glusterd_snapshot_restore_cleanup(dict_t *rsp_dict, char *volname,
+ glusterd_snap_t *snap);
void
-glusterd_get_snapd_dir (glusterd_volinfo_t *volinfo,
- char *path, int path_len);
+glusterd_get_snapd_dir(glusterd_volinfo_t *volinfo, char *path, int path_len);
int
-glusterd_is_snapd_enabled (glusterd_volinfo_t *volinfo);
+glusterd_is_snapd_enabled(glusterd_volinfo_t *volinfo);
int32_t
-glusterd_check_and_set_config_limit (glusterd_conf_t *priv);
+glusterd_check_and_set_config_limit(glusterd_conf_t *priv);
int32_t
-glusterd_is_snap_soft_limit_reached (glusterd_volinfo_t *volinfo,
- dict_t *dict);
+glusterd_is_snap_soft_limit_reached(glusterd_volinfo_t *volinfo, dict_t *dict);
void
-gd_get_snap_conf_values_if_present (dict_t *opts, uint64_t *sys_hard_limit,
- uint64_t *sys_soft_limit);
+gd_get_snap_conf_values_if_present(dict_t *opts, uint64_t *sys_hard_limit,
+ uint64_t *sys_soft_limit);
int
-glusterd_get_snap_status_str (glusterd_snap_t *snapinfo, char *snap_status_str);
+glusterd_get_snap_status_str(glusterd_snap_t *snapinfo, char *snap_status_str);
#endif
-
diff --git a/xlators/mgmt/glusterd/src/glusterd-statedump.h b/xlators/mgmt/glusterd/src/glusterd-statedump.h
index 3ac8659f293..7d7fc1a7fa3 100644
--- a/xlators/mgmt/glusterd/src/glusterd-statedump.h
+++ b/xlators/mgmt/glusterd/src/glusterd-statedump.h
@@ -14,5 +14,5 @@
#include "xlator.h"
int
-glusterd_dump_priv (xlator_t *this);
+glusterd_dump_priv(xlator_t *this);
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-store.h b/xlators/mgmt/glusterd/src/glusterd-store.h
index d809f2c7963..5db77703482 100644
--- a/xlators/mgmt/glusterd/src/glusterd-store.h
+++ b/xlators/mgmt/glusterd/src/glusterd-store.h
@@ -22,187 +22,185 @@
#include "glusterd.h"
#include "rpcsvc.h"
-typedef enum glusterd_store_ver_ac_{
- GLUSTERD_VOLINFO_VER_AC_NONE = 0,
- GLUSTERD_VOLINFO_VER_AC_INCREMENT = 1,
- GLUSTERD_VOLINFO_VER_AC_DECREMENT = 2,
+typedef enum glusterd_store_ver_ac_ {
+ GLUSTERD_VOLINFO_VER_AC_NONE = 0,
+ GLUSTERD_VOLINFO_VER_AC_INCREMENT = 1,
+ GLUSTERD_VOLINFO_VER_AC_DECREMENT = 2,
} glusterd_volinfo_ver_ac_t;
-
-#define GLUSTERD_STORE_UUID_KEY "UUID"
-
-#define GLUSTERD_STORE_KEY_VOL_TYPE "type"
-#define GLUSTERD_STORE_KEY_VOL_COUNT "count"
-#define GLUSTERD_STORE_KEY_VOL_STATUS "status"
-#define GLUSTERD_STORE_KEY_VOL_PORT "port"
-#define GLUSTERD_STORE_KEY_VOL_SUB_COUNT "sub_count"
-#define GLUSTERD_STORE_KEY_VOL_STRIPE_CNT "stripe_count"
-#define GLUSTERD_STORE_KEY_VOL_REPLICA_CNT "replica_count"
-#define GLUSTERD_STORE_KEY_VOL_DISPERSE_CNT "disperse_count"
-#define GLUSTERD_STORE_KEY_VOL_REDUNDANCY_CNT "redundancy_count"
-#define GLUSTERD_STORE_KEY_VOL_ARBITER_CNT "arbiter_count"
-#define GLUSTERD_STORE_KEY_VOL_BRICK "brick"
-#define GLUSTERD_STORE_KEY_VOL_VERSION "version"
-#define GLUSTERD_STORE_KEY_VOL_TRANSPORT "transport-type"
-#define GLUSTERD_STORE_KEY_VOL_ID "volume-id"
-#define GLUSTERD_STORE_KEY_VOL_RESTORED_SNAP "restored_from_snap"
-#define GLUSTERD_STORE_KEY_RB_STATUS "rb_status"
-#define GLUSTERD_STORE_KEY_RB_SRC_BRICK "rb_src"
-#define GLUSTERD_STORE_KEY_RB_DST_BRICK "rb_dst"
-#define GLUSTERD_STORE_KEY_RB_DST_PORT "rb_port"
-#define GLUSTERD_STORE_KEY_VOL_DEFRAG "rebalance_status"
-#define GLUSTERD_STORE_KEY_VOL_DEFRAG_STATUS "status"
-#define GLUSTERD_STORE_KEY_DEFRAG_OP "rebalance_op"
-#define GLUSTERD_STORE_KEY_USERNAME "username"
-#define GLUSTERD_STORE_KEY_PASSWORD "password"
-#define GLUSTERD_STORE_KEY_PARENT_VOLNAME "parent_volname"
-#define GLUSTERD_STORE_KEY_VOL_OP_VERSION "op-version"
+#define GLUSTERD_STORE_UUID_KEY "UUID"
+
+#define GLUSTERD_STORE_KEY_VOL_TYPE "type"
+#define GLUSTERD_STORE_KEY_VOL_COUNT "count"
+#define GLUSTERD_STORE_KEY_VOL_STATUS "status"
+#define GLUSTERD_STORE_KEY_VOL_PORT "port"
+#define GLUSTERD_STORE_KEY_VOL_SUB_COUNT "sub_count"
+#define GLUSTERD_STORE_KEY_VOL_STRIPE_CNT "stripe_count"
+#define GLUSTERD_STORE_KEY_VOL_REPLICA_CNT "replica_count"
+#define GLUSTERD_STORE_KEY_VOL_DISPERSE_CNT "disperse_count"
+#define GLUSTERD_STORE_KEY_VOL_REDUNDANCY_CNT "redundancy_count"
+#define GLUSTERD_STORE_KEY_VOL_ARBITER_CNT "arbiter_count"
+#define GLUSTERD_STORE_KEY_VOL_BRICK "brick"
+#define GLUSTERD_STORE_KEY_VOL_VERSION "version"
+#define GLUSTERD_STORE_KEY_VOL_TRANSPORT "transport-type"
+#define GLUSTERD_STORE_KEY_VOL_ID "volume-id"
+#define GLUSTERD_STORE_KEY_VOL_RESTORED_SNAP "restored_from_snap"
+#define GLUSTERD_STORE_KEY_RB_STATUS "rb_status"
+#define GLUSTERD_STORE_KEY_RB_SRC_BRICK "rb_src"
+#define GLUSTERD_STORE_KEY_RB_DST_BRICK "rb_dst"
+#define GLUSTERD_STORE_KEY_RB_DST_PORT "rb_port"
+#define GLUSTERD_STORE_KEY_VOL_DEFRAG "rebalance_status"
+#define GLUSTERD_STORE_KEY_VOL_DEFRAG_STATUS "status"
+#define GLUSTERD_STORE_KEY_DEFRAG_OP "rebalance_op"
+#define GLUSTERD_STORE_KEY_USERNAME "username"
+#define GLUSTERD_STORE_KEY_PASSWORD "password"
+#define GLUSTERD_STORE_KEY_PARENT_VOLNAME "parent_volname"
+#define GLUSTERD_STORE_KEY_VOL_OP_VERSION "op-version"
#define GLUSTERD_STORE_KEY_VOL_CLIENT_OP_VERSION "client-op-version"
-#define GLUSTERD_STORE_KEY_VOL_QUOTA_VERSION "quota-version"
-
-#define GLUSTERD_STORE_KEY_VOL_TIER_STATUS "tier_status"
-#define GLUSTERD_STORE_KEY_TIER_DETACH_OP "tier_op"
-#define GLUSTERD_STORE_KEY_COLD_TYPE "cold_type"
-#define GLUSTERD_STORE_KEY_COLD_COUNT "cold_count"
-#define GLUSTERD_STORE_KEY_COLD_REPLICA_COUNT "cold_replica_count"
-#define GLUSTERD_STORE_KEY_COLD_DISPERSE_COUNT "cold_disperse_count"
-#define GLUSTERD_STORE_KEY_COLD_REDUNDANCY_COUNT "cold_redundancy_count"
-#define GLUSTERD_STORE_KEY_HOT_TYPE "hot_type"
-#define GLUSTERD_STORE_KEY_HOT_COUNT "hot_count"
-#define GLUSTERD_STORE_KEY_HOT_REPLICA_COUNT "hot_replica_count"
-
-#define GLUSTERD_STORE_KEY_SNAP_NAME "name"
-#define GLUSTERD_STORE_KEY_SNAP_ID "snap-id"
-#define GLUSTERD_STORE_KEY_SNAP_DESC "desc"
-#define GLUSTERD_STORE_KEY_SNAP_TIMESTAMP "time-stamp"
-#define GLUSTERD_STORE_KEY_SNAP_STATUS "status"
-#define GLUSTERD_STORE_KEY_SNAP_RESTORED "snap-restored"
-#define GLUSTERD_STORE_KEY_SNAP_MAX_HARD_LIMIT "snap-max-hard-limit"
-#define GLUSTERD_STORE_KEY_SNAP_AUTO_DELETE "auto-delete"
-#define GLUSTERD_STORE_KEY_SNAP_MAX_SOFT_LIMIT "snap-max-soft-limit"
-#define GLUSTERD_STORE_KEY_SNAPD_PORT "snapd-port"
-#define GLUSTERD_STORE_KEY_SNAP_ACTIVATE "snap-activate-on-create"
-
-#define GLUSTERD_STORE_KEY_BRICK_HOSTNAME "hostname"
-#define GLUSTERD_STORE_KEY_BRICK_PATH "path"
-#define GLUSTERD_STORE_KEY_BRICK_REAL_PATH "real_path"
-#define GLUSTERD_STORE_KEY_BRICK_PORT "listen-port"
-#define GLUSTERD_STORE_KEY_BRICK_RDMA_PORT "rdma.listen-port"
+#define GLUSTERD_STORE_KEY_VOL_QUOTA_VERSION "quota-version"
+
+#define GLUSTERD_STORE_KEY_VOL_TIER_STATUS "tier_status"
+#define GLUSTERD_STORE_KEY_TIER_DETACH_OP "tier_op"
+#define GLUSTERD_STORE_KEY_COLD_TYPE "cold_type"
+#define GLUSTERD_STORE_KEY_COLD_COUNT "cold_count"
+#define GLUSTERD_STORE_KEY_COLD_REPLICA_COUNT "cold_replica_count"
+#define GLUSTERD_STORE_KEY_COLD_DISPERSE_COUNT "cold_disperse_count"
+#define GLUSTERD_STORE_KEY_COLD_REDUNDANCY_COUNT "cold_redundancy_count"
+#define GLUSTERD_STORE_KEY_HOT_TYPE "hot_type"
+#define GLUSTERD_STORE_KEY_HOT_COUNT "hot_count"
+#define GLUSTERD_STORE_KEY_HOT_REPLICA_COUNT "hot_replica_count"
+
+#define GLUSTERD_STORE_KEY_SNAP_NAME "name"
+#define GLUSTERD_STORE_KEY_SNAP_ID "snap-id"
+#define GLUSTERD_STORE_KEY_SNAP_DESC "desc"
+#define GLUSTERD_STORE_KEY_SNAP_TIMESTAMP "time-stamp"
+#define GLUSTERD_STORE_KEY_SNAP_STATUS "status"
+#define GLUSTERD_STORE_KEY_SNAP_RESTORED "snap-restored"
+#define GLUSTERD_STORE_KEY_SNAP_MAX_HARD_LIMIT "snap-max-hard-limit"
+#define GLUSTERD_STORE_KEY_SNAP_AUTO_DELETE "auto-delete"
+#define GLUSTERD_STORE_KEY_SNAP_MAX_SOFT_LIMIT "snap-max-soft-limit"
+#define GLUSTERD_STORE_KEY_SNAPD_PORT "snapd-port"
+#define GLUSTERD_STORE_KEY_SNAP_ACTIVATE "snap-activate-on-create"
+
+#define GLUSTERD_STORE_KEY_BRICK_HOSTNAME "hostname"
+#define GLUSTERD_STORE_KEY_BRICK_PATH "path"
+#define GLUSTERD_STORE_KEY_BRICK_REAL_PATH "real_path"
+#define GLUSTERD_STORE_KEY_BRICK_PORT "listen-port"
+#define GLUSTERD_STORE_KEY_BRICK_RDMA_PORT "rdma.listen-port"
#define GLUSTERD_STORE_KEY_BRICK_DECOMMISSIONED "decommissioned"
-#define GLUSTERD_STORE_KEY_BRICK_VGNAME "vg"
-#define GLUSTERD_STORE_KEY_BRICK_DEVICE_PATH "device_path"
-#define GLUSTERD_STORE_KEY_BRICK_MOUNT_DIR "mount_dir"
-#define GLUSTERD_STORE_KEY_BRICK_SNAP_STATUS "snap-status"
-#define GLUSTERD_STORE_KEY_BRICK_FSTYPE "fs-type"
-#define GLUSTERD_STORE_KEY_BRICK_MNTOPTS "mnt-opts"
-#define GLUSTERD_STORE_KEY_BRICK_ID "brick-id"
-#define GLUSTERD_STORE_KEY_BRICK_FSID "brick-fsid"
-#define GLUSTERD_STORE_KEY_BRICK_UUID "uuid"
-
-#define GLUSTERD_STORE_KEY_PEER_UUID "uuid"
-#define GLUSTERD_STORE_KEY_PEER_HOSTNAME "hostname"
-#define GLUSTERD_STORE_KEY_PEER_STATE "state"
-
-#define GLUSTERD_STORE_KEY_VOL_CAPS "caps"
+#define GLUSTERD_STORE_KEY_BRICK_VGNAME "vg"
+#define GLUSTERD_STORE_KEY_BRICK_DEVICE_PATH "device_path"
+#define GLUSTERD_STORE_KEY_BRICK_MOUNT_DIR "mount_dir"
+#define GLUSTERD_STORE_KEY_BRICK_SNAP_STATUS "snap-status"
+#define GLUSTERD_STORE_KEY_BRICK_FSTYPE "fs-type"
+#define GLUSTERD_STORE_KEY_BRICK_MNTOPTS "mnt-opts"
+#define GLUSTERD_STORE_KEY_BRICK_ID "brick-id"
+#define GLUSTERD_STORE_KEY_BRICK_FSID "brick-fsid"
+#define GLUSTERD_STORE_KEY_BRICK_UUID "uuid"
+
+#define GLUSTERD_STORE_KEY_PEER_UUID "uuid"
+#define GLUSTERD_STORE_KEY_PEER_HOSTNAME "hostname"
+#define GLUSTERD_STORE_KEY_PEER_STATE "state"
+
+#define GLUSTERD_STORE_KEY_VOL_CAPS "caps"
#define GLUSTERD_STORE_KEY_VOL_DEFRAG_REB_FILES "rebalanced-files"
-#define GLUSTERD_STORE_KEY_VOL_DEFRAG_SIZE "size"
-#define GLUSTERD_STORE_KEY_VOL_DEFRAG_SCANNED "scanned"
-#define GLUSTERD_STORE_KEY_VOL_DEFRAG_FAILURES "failures"
-#define GLUSTERD_STORE_KEY_VOL_DEFRAG_SKIPPED "skipped"
-#define GLUSTERD_STORE_KEY_VOL_DEFRAG_RUN_TIME "run-time"
+#define GLUSTERD_STORE_KEY_VOL_DEFRAG_SIZE "size"
+#define GLUSTERD_STORE_KEY_VOL_DEFRAG_SCANNED "scanned"
+#define GLUSTERD_STORE_KEY_VOL_DEFRAG_FAILURES "failures"
+#define GLUSTERD_STORE_KEY_VOL_DEFRAG_SKIPPED "skipped"
+#define GLUSTERD_STORE_KEY_VOL_DEFRAG_RUN_TIME "run-time"
-#define GLUSTERD_STORE_KEY_VOL_MIGRATED_FILES "migrated-files"
-#define GLUSTERD_STORE_KEY_VOL_MIGRATED_SIZE "migration-size"
-#define GLUSTERD_STORE_KEY_VOL_MIGRATIONS_SCANNED "migration-scanned"
-#define GLUSTERD_STORE_KEY_VOL_MIGRATIONS_FAILURES "migration-failures"
-#define GLUSTERD_STORE_KEY_VOL_MIGRATIONS_SKIPPED "migration-skipped"
-#define GLUSTERD_STORE_KEY_VOL_MIGRATION_RUN_TIME "migration-run-time"
+#define GLUSTERD_STORE_KEY_VOL_MIGRATED_FILES "migrated-files"
+#define GLUSTERD_STORE_KEY_VOL_MIGRATED_SIZE "migration-size"
+#define GLUSTERD_STORE_KEY_VOL_MIGRATIONS_SCANNED "migration-scanned"
+#define GLUSTERD_STORE_KEY_VOL_MIGRATIONS_FAILURES "migration-failures"
+#define GLUSTERD_STORE_KEY_VOL_MIGRATIONS_SKIPPED "migration-skipped"
+#define GLUSTERD_STORE_KEY_VOL_MIGRATION_RUN_TIME "migration-run-time"
int32_t
-glusterd_store_volinfo (glusterd_volinfo_t *volinfo, glusterd_volinfo_ver_ac_t ac);
+glusterd_store_volinfo(glusterd_volinfo_t *volinfo,
+ glusterd_volinfo_ver_ac_t ac);
int32_t
-glusterd_store_delete_volume (glusterd_volinfo_t *volinfo);
+glusterd_store_delete_volume(glusterd_volinfo_t *volinfo);
int32_t
-glusterd_store_delete_snap (glusterd_snap_t *snap);
+glusterd_store_delete_snap(glusterd_snap_t *snap);
int32_t
-glusterd_retrieve_uuid ();
+glusterd_retrieve_uuid();
int32_t
-glusterd_store_peerinfo (glusterd_peerinfo_t *peerinfo);
+glusterd_store_peerinfo(glusterd_peerinfo_t *peerinfo);
int32_t
-glusterd_store_delete_peerinfo (glusterd_peerinfo_t *peerinfo);
+glusterd_store_delete_peerinfo(glusterd_peerinfo_t *peerinfo);
int32_t
-glusterd_store_delete_brick (glusterd_brickinfo_t *brickinfo,
- char *delete_path);
+glusterd_store_delete_brick(glusterd_brickinfo_t *brickinfo, char *delete_path);
int32_t
-glusterd_restore ();
+glusterd_restore();
void
-glusterd_perform_volinfo_version_action (glusterd_volinfo_t *volinfo,
- glusterd_volinfo_ver_ac_t ac);
+glusterd_perform_volinfo_version_action(glusterd_volinfo_t *volinfo,
+ glusterd_volinfo_ver_ac_t ac);
gf_boolean_t
-glusterd_store_is_valid_brickpath (char *volname, char *brick);
+glusterd_store_is_valid_brickpath(char *volname, char *brick);
int32_t
-glusterd_store_perform_node_state_store (glusterd_volinfo_t *volinfo);
+glusterd_store_perform_node_state_store(glusterd_volinfo_t *volinfo);
int
-glusterd_retrieve_op_version (xlator_t *this, int *op_version);
+glusterd_retrieve_op_version(xlator_t *this, int *op_version);
int
-glusterd_store_global_info (xlator_t *this);
+glusterd_store_global_info(xlator_t *this);
int32_t
-glusterd_store_retrieve_options (xlator_t *this);
+glusterd_store_retrieve_options(xlator_t *this);
int32_t
-glusterd_store_retrieve_bricks (glusterd_volinfo_t *volinfo);
+glusterd_store_retrieve_bricks(glusterd_volinfo_t *volinfo);
int32_t
-glusterd_store_options (xlator_t *this, dict_t *opts);
+glusterd_store_options(xlator_t *this, dict_t *opts);
void
-glusterd_replace_slash_with_hyphen (char *str);
+glusterd_replace_slash_with_hyphen(char *str);
int32_t
-glusterd_store_perform_volume_store (glusterd_volinfo_t *volinfo);
+glusterd_store_perform_volume_store(glusterd_volinfo_t *volinfo);
int32_t
-glusterd_store_create_quota_conf_sh_on_absence (glusterd_volinfo_t *volinfo);
+glusterd_store_create_quota_conf_sh_on_absence(glusterd_volinfo_t *volinfo);
int
-glusterd_store_retrieve_quota_version (glusterd_volinfo_t *volinfo);
+glusterd_store_retrieve_quota_version(glusterd_volinfo_t *volinfo);
int
-glusterd_store_save_quota_version_and_cksum (glusterd_volinfo_t *volinfo);
+glusterd_store_save_quota_version_and_cksum(glusterd_volinfo_t *volinfo);
int32_t
-glusterd_store_snap (glusterd_snap_t *snap);
+glusterd_store_snap(glusterd_snap_t *snap);
int32_t
-glusterd_store_update_missed_snaps ();
+glusterd_store_update_missed_snaps();
-glusterd_volinfo_t*
-glusterd_store_retrieve_volume (char *volname, glusterd_snap_t *snap);
+glusterd_volinfo_t *
+glusterd_store_retrieve_volume(char *volname, glusterd_snap_t *snap);
int
-glusterd_restore_op_version (xlator_t *this);
+glusterd_restore_op_version(xlator_t *this);
int32_t
-glusterd_quota_conf_write_header (int fd);
+glusterd_quota_conf_write_header(int fd);
int32_t
-glusterd_quota_conf_write_gfid (int fd, void *buf, char type);
+glusterd_quota_conf_write_gfid(int fd, void *buf, char type);
int32_t
-glusterd_recreate_vol_brick_mounts (xlator_t *this,
- glusterd_volinfo_t *volinfo);
+glusterd_recreate_vol_brick_mounts(xlator_t *this, glusterd_volinfo_t *volinfo);
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-svc-helper.h b/xlators/mgmt/glusterd/src/glusterd-svc-helper.h
index bbba5ce9ee4..cc98e788bbe 100644
--- a/xlators/mgmt/glusterd/src/glusterd-svc-helper.h
+++ b/xlators/mgmt/glusterd/src/glusterd-svc-helper.h
@@ -16,30 +16,30 @@
#include "glusterd-volgen.h"
int
-glusterd_svcs_reconfigure ();
+glusterd_svcs_reconfigure();
int
-glusterd_svcs_stop ();
+glusterd_svcs_stop();
int
-glusterd_svcs_manager (glusterd_volinfo_t *volinfo);
+glusterd_svcs_manager(glusterd_volinfo_t *volinfo);
int
-glusterd_svc_check_volfile_identical (char *svc_name,
+glusterd_svc_check_volfile_identical(char *svc_name,
+ glusterd_graph_builder_t builder,
+ gf_boolean_t *identical);
+int
+glusterd_svc_check_topology_identical(char *svc_name,
glusterd_graph_builder_t builder,
gf_boolean_t *identical);
-int
-glusterd_svc_check_topology_identical (char *svc_name,
- glusterd_graph_builder_t builder,
- gf_boolean_t *identical);
int
-glusterd_svc_check_tier_volfile_identical (char *svc_name,
+glusterd_svc_check_tier_volfile_identical(char *svc_name,
+ glusterd_volinfo_t *volinfo,
+ gf_boolean_t *identical);
+int
+glusterd_svc_check_tier_topology_identical(char *svc_name,
glusterd_volinfo_t *volinfo,
gf_boolean_t *identical);
-int
-glusterd_svc_check_tier_topology_identical (char *svc_name,
- glusterd_volinfo_t *volinfo,
- gf_boolean_t *identical);
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-svc-mgmt.h b/xlators/mgmt/glusterd/src/glusterd-svc-mgmt.h
index 8b70a62a4e3..3bf142b58d3 100644
--- a/xlators/mgmt/glusterd/src/glusterd-svc-mgmt.h
+++ b/xlators/mgmt/glusterd/src/glusterd-svc-mgmt.h
@@ -17,59 +17,56 @@
struct glusterd_svc_;
typedef struct glusterd_svc_ glusterd_svc_t;
-typedef void (*glusterd_svc_build_t) (glusterd_svc_t *svc);
+typedef void (*glusterd_svc_build_t)(glusterd_svc_t *svc);
-typedef int (*glusterd_svc_manager_t) (glusterd_svc_t *svc,
- void *data, int flags);
-typedef int (*glusterd_svc_start_t) (glusterd_svc_t *svc, int flags);
-typedef int (*glusterd_svc_stop_t) (glusterd_svc_t *svc, int sig);
-typedef int (*glusterd_svc_reconfigure_t) (void *data);
+typedef int (*glusterd_svc_manager_t)(glusterd_svc_t *svc, void *data,
+ int flags);
+typedef int (*glusterd_svc_start_t)(glusterd_svc_t *svc, int flags);
+typedef int (*glusterd_svc_stop_t)(glusterd_svc_t *svc, int sig);
+typedef int (*glusterd_svc_reconfigure_t)(void *data);
struct glusterd_svc_ {
- char name[PATH_MAX];
- glusterd_conn_t conn;
- glusterd_proc_t proc;
- glusterd_svc_manager_t manager;
- glusterd_svc_start_t start;
- glusterd_svc_stop_t stop;
- gf_boolean_t online;
- gf_boolean_t inited;
- glusterd_svc_reconfigure_t reconfigure;
+ char name[PATH_MAX];
+ glusterd_conn_t conn;
+ glusterd_proc_t proc;
+ glusterd_svc_manager_t manager;
+ glusterd_svc_start_t start;
+ glusterd_svc_stop_t stop;
+ gf_boolean_t online;
+ gf_boolean_t inited;
+ glusterd_svc_reconfigure_t reconfigure;
};
int
-glusterd_svc_create_rundir (char *rundir);
+glusterd_svc_create_rundir(char *rundir);
int
-glusterd_svc_init (glusterd_svc_t *svc, char *svc_name);
+glusterd_svc_init(glusterd_svc_t *svc, char *svc_name);
int
-glusterd_svc_start (glusterd_svc_t *svc, int flags, dict_t *cmdline);
+glusterd_svc_start(glusterd_svc_t *svc, int flags, dict_t *cmdline);
int
-glusterd_svc_stop (glusterd_svc_t *svc, int sig);
+glusterd_svc_stop(glusterd_svc_t *svc, int sig);
void
-glusterd_svc_build_pidfile_path (char *server, char *workdir,
- char *path, size_t len);
+glusterd_svc_build_pidfile_path(char *server, char *workdir, char *path,
+ size_t len);
void
-glusterd_svc_build_volfile_path (char *server, char *workdir,
- char *volfile, size_t len);
+glusterd_svc_build_volfile_path(char *server, char *workdir, char *volfile,
+ size_t len);
void
-glusterd_svc_build_svcdir (char *server, char *workdir,
- char *path, size_t len);
+glusterd_svc_build_svcdir(char *server, char *workdir, char *path, size_t len);
void
-glusterd_svc_build_rundir (char *server, char *workdir,
- char *path, size_t len);
+glusterd_svc_build_rundir(char *server, char *workdir, char *path, size_t len);
int
-glusterd_svc_reconfigure (int (*create_volfile) ());
+glusterd_svc_reconfigure(int (*create_volfile)());
int
-glusterd_svc_common_rpc_notify (glusterd_conn_t *conn,
- rpc_clnt_event_t event);
+glusterd_svc_common_rpc_notify(glusterd_conn_t *conn, rpc_clnt_event_t event);
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-syncop.h b/xlators/mgmt/glusterd/src/glusterd-syncop.h
index e5f3aa6304c..37195ef0112 100644
--- a/xlators/mgmt/glusterd/src/glusterd-syncop.h
+++ b/xlators/mgmt/glusterd/src/glusterd-syncop.h
@@ -17,71 +17,77 @@
#define GD_SYNC_OPCODE_KEY "sync-mgmt-operation"
/* gd_syncop_* */
-#define GD_SYNCOP(rpc, stb, cookie, cbk, req, prog, procnum, xdrproc) do { \
- int ret = 0; \
- struct synctask *task = NULL; \
- glusterd_conf_t *conf= THIS->private; \
+#define GD_SYNCOP(rpc, stb, cookie, cbk, req, prog, procnum, xdrproc) \
+ do { \
+ int ret = 0; \
+ struct synctask *task = NULL; \
+ glusterd_conf_t *conf = THIS->private; \
\
- task = synctask_get (); \
- stb->task = task; \
+ task = synctask_get(); \
+ stb->task = task; \
\
- /*This is to ensure that the brick_op_cbk is able to \
- * take the big lock*/ \
- synclock_unlock (&conf->big_lock); \
- ret = gd_syncop_submit_request (rpc, req, stb, cookie, \
- prog, procnum, cbk, \
- (xdrproc_t)xdrproc); \
- if (!ret) \
- synctask_yield (stb->task); \
- else \
- gf_asprintf (&stb->errstr, "%s failed. Check log file" \
- " for more details", (prog)->progname); \
- synclock_lock (&conf->big_lock); \
- } while (0)
+ /*This is to ensure that the brick_op_cbk is able to \
+ * take the big lock*/ \
+ synclock_unlock(&conf->big_lock); \
+ ret = gd_syncop_submit_request(rpc, req, stb, cookie, prog, procnum, \
+ cbk, (xdrproc_t)xdrproc); \
+ if (!ret) \
+ synctask_yield(stb->task); \
+ else \
+ gf_asprintf(&stb->errstr, \
+ "%s failed. Check log file" \
+ " for more details", \
+ (prog)->progname); \
+ synclock_lock(&conf->big_lock); \
+ } while (0)
-#define GD_ALLOC_COPY_UUID(dst_ptr, uuid, ret) do { \
- dst_ptr = GF_MALLOC (sizeof (*dst_ptr), gf_common_mt_uuid_t); \
+#define GD_ALLOC_COPY_UUID(dst_ptr, uuid, ret) \
+ do { \
+ dst_ptr = GF_MALLOC(sizeof(*dst_ptr), gf_common_mt_uuid_t); \
if (dst_ptr) { \
- gf_uuid_copy (*dst_ptr, uuid); \
- ret = 0; \
+ gf_uuid_copy(*dst_ptr, uuid); \
+ ret = 0; \
} else { \
- ret = -1; \
+ ret = -1; \
} \
-} while (0)
+ } while (0)
int32_t
-gd_syncop_brick_op_cbk (struct rpc_req *req, struct iovec *iov,
- int count, void *myframe);
+gd_syncop_brick_op_cbk(struct rpc_req *req, struct iovec *iov, int count,
+ void *myframe);
-int gd_syncop_submit_request (struct rpc_clnt *rpc, void *req, void *local,
- void *cookie, rpc_clnt_prog_t *prog, int procnum,
- fop_cbk_fn_t cbkfn, xdrproc_t xdrproc);
-int gd_syncop_mgmt_lock (glusterd_peerinfo_t *peerinfo, struct syncargs *arg,
- uuid_t my_uuid, uuid_t recv_uuid);
+int
+gd_syncop_submit_request(struct rpc_clnt *rpc, void *req, void *local,
+ void *cookie, rpc_clnt_prog_t *prog, int procnum,
+ fop_cbk_fn_t cbkfn, xdrproc_t xdrproc);
+int
+gd_syncop_mgmt_lock(glusterd_peerinfo_t *peerinfo, struct syncargs *arg,
+ uuid_t my_uuid, uuid_t recv_uuid);
-int gd_syncop_mgmt_unlock (glusterd_peerinfo_t *peerinfo, struct syncargs *arg,
- uuid_t my_uuid, uuid_t recv_uuid);
+int
+gd_syncop_mgmt_unlock(glusterd_peerinfo_t *peerinfo, struct syncargs *arg,
+ uuid_t my_uuid, uuid_t recv_uuid);
-int gd_syncop_mgmt_stage_op (glusterd_peerinfo_t *peerinfo,
- struct syncargs *arg, uuid_t my_uuid,
- uuid_t recv_uuid, int op, dict_t *dict_out,
- dict_t *op_ctx);
+int
+gd_syncop_mgmt_stage_op(glusterd_peerinfo_t *peerinfo, struct syncargs *arg,
+ uuid_t my_uuid, uuid_t recv_uuid, int op,
+ dict_t *dict_out, dict_t *op_ctx);
-int gd_syncop_mgmt_commit_op (glusterd_peerinfo_t *peerinfo,
- struct syncargs *arg, uuid_t my_uuid,
- uuid_t recv_uuid, int op, dict_t *dict_out,
- dict_t *op_ctx);
+int
+gd_syncop_mgmt_commit_op(glusterd_peerinfo_t *peerinfo, struct syncargs *arg,
+ uuid_t my_uuid, uuid_t recv_uuid, int op,
+ dict_t *dict_out, dict_t *op_ctx);
void
-gd_synctask_barrier_wait (struct syncargs *args, int count);
+gd_synctask_barrier_wait(struct syncargs *args, int count);
int
-gd_brick_op_phase (glusterd_op_t op, dict_t *op_ctx, dict_t *req_dict,
- char **op_errstr);
+gd_brick_op_phase(glusterd_op_t op, dict_t *op_ctx, dict_t *req_dict,
+ char **op_errstr);
int
-glusterd_syncop_aggr_rsp_dict (glusterd_op_t op, dict_t *aggr, dict_t *rsp);
+glusterd_syncop_aggr_rsp_dict(glusterd_op_t op, dict_t *aggr, dict_t *rsp);
void
-gd_syncargs_init (struct syncargs *args, dict_t *op_ctx);
+gd_syncargs_init(struct syncargs *args, dict_t *op_ctx);
#endif /* __RPC_SYNCOP_H */
diff --git a/xlators/mgmt/glusterd/src/glusterd-tierd-svc-helper.h b/xlators/mgmt/glusterd/src/glusterd-tierd-svc-helper.h
index 1f0e33b989c..56b794df506 100644
--- a/xlators/mgmt/glusterd/src/glusterd-tierd-svc-helper.h
+++ b/xlators/mgmt/glusterd/src/glusterd-tierd-svc-helper.h
@@ -14,24 +14,24 @@
#include "glusterd.h"
void
-glusterd_svc_build_tierd_rundir (glusterd_volinfo_t *volinfo,
- char *path, int path_len);
+glusterd_svc_build_tierd_rundir(glusterd_volinfo_t *volinfo, char *path,
+ int path_len);
void
-glusterd_svc_build_tierd_socket_filepath (glusterd_volinfo_t *volinfo,
- char *path, int path_len);
+glusterd_svc_build_tierd_socket_filepath(glusterd_volinfo_t *volinfo,
+ char *path, int path_len);
void
-glusterd_svc_build_tierd_pidfile (glusterd_volinfo_t *volinfo,
- char *path, int path_len);
+glusterd_svc_build_tierd_pidfile(glusterd_volinfo_t *volinfo, char *path,
+ int path_len);
void
-glusterd_svc_build_tierd_volfile_path (glusterd_volinfo_t *volinfo,
- char *path, int path_len);
+glusterd_svc_build_tierd_volfile_path(glusterd_volinfo_t *volinfo, char *path,
+ int path_len);
void
-glusterd_svc_build_tierd_logdir (char *logdir, char *volname, size_t len);
+glusterd_svc_build_tierd_logdir(char *logdir, char *volname, size_t len);
void
-glusterd_svc_build_tierd_logfile (char *logfile, char *logdir, size_t len);
+glusterd_svc_build_tierd_logfile(char *logfile, char *logdir, size_t len);
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-tierd-svc.h b/xlators/mgmt/glusterd/src/glusterd-tierd-svc.h
index 2ff840d0f25..78d3d11b6a3 100644
--- a/xlators/mgmt/glusterd/src/glusterd-tierd-svc.h
+++ b/xlators/mgmt/glusterd/src/glusterd-tierd-svc.h
@@ -13,30 +13,29 @@
#include "glusterd-svc-mgmt.h"
-
typedef struct glusterd_tierdsvc_ glusterd_tierdsvc_t;
struct glusterd_tierdsvc_ {
- glusterd_svc_t svc;
- gf_store_handle_t *handle;
+ glusterd_svc_t svc;
+ gf_store_handle_t *handle;
};
void
-glusterd_tierdsvc_build (glusterd_svc_t *svc);
+glusterd_tierdsvc_build(glusterd_svc_t *svc);
int
-glusterd_tierdsvc_init (void *data);
+glusterd_tierdsvc_init(void *data);
int
-glusterd_tierdsvc_manager (glusterd_svc_t *svc, void *data, int flags);
+glusterd_tierdsvc_manager(glusterd_svc_t *svc, void *data, int flags);
int
-glusterd_tierdsvc_start (glusterd_svc_t *svc, int flags);
+glusterd_tierdsvc_start(glusterd_svc_t *svc, int flags);
int
-glusterd_tierdsvc_reconfigure (void *data);
+glusterd_tierdsvc_reconfigure(void *data);
int
-glusterd_tierdsvc_restart ();
+glusterd_tierdsvc_restart();
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-utils.h b/xlators/mgmt/glusterd/src/glusterd-utils.h
index 6f77ca6fbd6..4bdc048dd35 100644
--- a/xlators/mgmt/glusterd/src/glusterd-utils.h
+++ b/xlators/mgmt/glusterd/src/glusterd-utils.h
@@ -26,869 +26,851 @@
#include "glusterd-peer-utils.h"
#define GLUSTERD_SOCK_DIR "/var/run/gluster"
-#define GLUSTERD_ASSIGN_BRICKID_TO_BRICKINFO(brickinfo, volinfo, brickid) do {\
- sprintf (brickinfo->brick_id, "%s-client-%d",\
- volinfo->volname, brickid);\
-} while (0)
+#define GLUSTERD_ASSIGN_BRICKID_TO_BRICKINFO(brickinfo, volinfo, brickid) \
+ do { \
+ sprintf(brickinfo->brick_id, "%s-client-%d", volinfo->volname, \
+ brickid); \
+ } while (0)
#define ALL_VOLUME_OPTION_CHECK(volname, get_opt, key, ret, op_errstr, label) \
- do { \
- gf_boolean_t _all = !strcmp ("all", volname); \
- gf_boolean_t _is_valid_opt = _gf_false; \
- int32_t i = 0; \
+ do { \
+ gf_boolean_t _all = !strcmp("all", volname); \
+ gf_boolean_t _is_valid_opt = _gf_false; \
+ int32_t i = 0; \
\
- if (!get_opt && (!strcmp (key, "all") || \
- !strcmp (key, GLUSTERD_MAX_OP_VERSION_KEY))) {\
- ret = -1; \
- *op_errstr = gf_strdup ("Not a valid option to set"); \
- goto out; \
- } \
+ if (!get_opt && (!strcmp(key, "all") || \
+ !strcmp(key, GLUSTERD_MAX_OP_VERSION_KEY))) { \
+ ret = -1; \
+ *op_errstr = gf_strdup("Not a valid option to set"); \
+ goto out; \
+ } \
\
- for (i = 0; valid_all_vol_opts[i].option; i++) { \
- if (!strcmp (key, "all") || \
- !strcmp (key, valid_all_vol_opts[i].option)) { \
- _is_valid_opt = _gf_true; \
- break; \
- } \
- } \
+ for (i = 0; valid_all_vol_opts[i].option; i++) { \
+ if (!strcmp(key, "all") || \
+ !strcmp(key, valid_all_vol_opts[i].option)) { \
+ _is_valid_opt = _gf_true; \
+ break; \
+ } \
+ } \
\
- if (_all && !_is_valid_opt) { \
- ret = -1; \
- *op_errstr = gf_strdup ("Not a valid option for all " \
- "volumes"); \
- goto label; \
- } else if (!_all && _is_valid_opt) { \
- ret = -1; \
- *op_errstr = gf_strdup ("Not a valid option for " \
- "single volume"); \
- goto label; \
- } \
- } while (0) \
-
+ if (_all && !_is_valid_opt) { \
+ ret = -1; \
+ *op_errstr = gf_strdup( \
+ "Not a valid option for all " \
+ "volumes"); \
+ goto label; \
+ } else if (!_all && _is_valid_opt) { \
+ ret = -1; \
+ *op_errstr = gf_strdup( \
+ "Not a valid option for " \
+ "single volume"); \
+ goto label; \
+ } \
+ } while (0)
struct glusterd_lock_ {
- uuid_t owner;
- time_t timestamp;
+ uuid_t owner;
+ time_t timestamp;
};
typedef struct glusterd_dict_ctx_ {
- dict_t *dict;
- int opt_count;
- char *key_name;
- char *val_name;
- char *prefix;
+ dict_t *dict;
+ int opt_count;
+ char *key_name;
+ char *val_name;
+ char *prefix;
} glusterd_dict_ctx_t;
-gf_boolean_t is_brick_mx_enabled (void);
+gf_boolean_t
+is_brick_mx_enabled(void);
int
-glusterd_compare_lines (const void *a, const void *b);
+glusterd_compare_lines(const void *a, const void *b);
-typedef int (*glusterd_condition_func) (glusterd_volinfo_t *volinfo,
- glusterd_brickinfo_t *brickinfo,
- void *ctx);
+typedef int (*glusterd_condition_func)(glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t *brickinfo,
+ void *ctx);
typedef struct glusterd_lock_ glusterd_lock_t;
int32_t
-glusterd_get_lock_owner (uuid_t *cur_owner);
+glusterd_get_lock_owner(uuid_t *cur_owner);
int32_t
-glusterd_lock (uuid_t new_owner);
+glusterd_lock(uuid_t new_owner);
int32_t
-glusterd_unlock (uuid_t owner);
+glusterd_unlock(uuid_t owner);
int32_t
-glusterd_get_uuid (uuid_t *uuid);
+glusterd_get_uuid(uuid_t *uuid);
-char*
-gd_get_shd_key (int type);
+char *
+gd_get_shd_key(int type);
int
-glusterd_submit_reply (rpcsvc_request_t *req, void *arg,
- struct iovec *payload, int payloadcount,
- struct iobref *iobref, xdrproc_t xdrproc);
+glusterd_submit_reply(rpcsvc_request_t *req, void *arg, struct iovec *payload,
+ int payloadcount, struct iobref *iobref,
+ xdrproc_t xdrproc);
int
-glusterd_to_cli (rpcsvc_request_t *req, gf_cli_rsp *arg, struct iovec *payload,
- int payloadcount, struct iobref *iobref, xdrproc_t xdrproc,
- dict_t *dict);
+glusterd_to_cli(rpcsvc_request_t *req, gf_cli_rsp *arg, struct iovec *payload,
+ int payloadcount, struct iobref *iobref, xdrproc_t xdrproc,
+ dict_t *dict);
int
-glusterd_submit_request (struct rpc_clnt *rpc, void *req,
- call_frame_t *frame, rpc_clnt_prog_t *prog,
- int procnum, struct iobref *iobref,
- xlator_t *this, fop_cbk_fn_t cbkfn, xdrproc_t xdrproc);
+glusterd_submit_request(struct rpc_clnt *rpc, void *req, call_frame_t *frame,
+ rpc_clnt_prog_t *prog, int procnum,
+ struct iobref *iobref, xlator_t *this,
+ fop_cbk_fn_t cbkfn, xdrproc_t xdrproc);
int32_t
-glusterd_volinfo_new (glusterd_volinfo_t **volinfo);
+glusterd_volinfo_new(glusterd_volinfo_t **volinfo);
int32_t
-glusterd_volinfo_dup (glusterd_volinfo_t *volinfo,
- glusterd_volinfo_t **dup_volinfo,
- gf_boolean_t set_userauth);
+glusterd_volinfo_dup(glusterd_volinfo_t *volinfo,
+ glusterd_volinfo_t **dup_volinfo,
+ gf_boolean_t set_userauth);
char *
-glusterd_auth_get_username (glusterd_volinfo_t *volinfo);
+glusterd_auth_get_username(glusterd_volinfo_t *volinfo);
char *
-glusterd_auth_get_password (glusterd_volinfo_t *volinfo);
+glusterd_auth_get_password(glusterd_volinfo_t *volinfo);
int32_t
-glusterd_auth_set_username (glusterd_volinfo_t *volinfo, char *username);
+glusterd_auth_set_username(glusterd_volinfo_t *volinfo, char *username);
int32_t
-glusterd_auth_set_password (glusterd_volinfo_t *volinfo, char *password);
+glusterd_auth_set_password(glusterd_volinfo_t *volinfo, char *password);
void
-glusterd_auth_cleanup (glusterd_volinfo_t *volinfo);
+glusterd_auth_cleanup(glusterd_volinfo_t *volinfo);
gf_boolean_t
-glusterd_check_volume_exists (char *volname);
+glusterd_check_volume_exists(char *volname);
int32_t
-glusterd_brickprocess_new (glusterd_brick_proc_t **brickprocess);
+glusterd_brickprocess_new(glusterd_brick_proc_t **brickprocess);
int32_t
-glusterd_brickinfo_new (glusterd_brickinfo_t **brickinfo);
+glusterd_brickinfo_new(glusterd_brickinfo_t **brickinfo);
int32_t
-glusterd_brickinfo_new_from_brick (char *brick,
- glusterd_brickinfo_t **brickinfo,
- gf_boolean_t construct_real_path,
- char **op_errstr);
+glusterd_brickinfo_new_from_brick(char *brick, glusterd_brickinfo_t **brickinfo,
+ gf_boolean_t construct_real_path,
+ char **op_errstr);
int32_t
-glusterd_volinfo_find (const char *volname, glusterd_volinfo_t **volinfo);
+glusterd_volinfo_find(const char *volname, glusterd_volinfo_t **volinfo);
int
-glusterd_volinfo_find_by_volume_id (uuid_t volume_id, glusterd_volinfo_t **volinfo);
+glusterd_volinfo_find_by_volume_id(uuid_t volume_id,
+ glusterd_volinfo_t **volinfo);
int32_t
glusterd_service_stop(const char *service, char *pidfile, int sig,
gf_boolean_t force_kill);
int32_t
-glusterd_service_stop_nolock (const char *service, char *pidfile, int sig,
- gf_boolean_t force_kill);
+glusterd_service_stop_nolock(const char *service, char *pidfile, int sig,
+ gf_boolean_t force_kill);
int
-glusterd_get_next_available_brickid (glusterd_volinfo_t *volinfo);
+glusterd_get_next_available_brickid(glusterd_volinfo_t *volinfo);
int32_t
-glusterd_resolve_brick (glusterd_brickinfo_t *brickinfo);
+glusterd_resolve_brick(glusterd_brickinfo_t *brickinfo);
int
-glusterd_brick_process_add_brick (glusterd_brickinfo_t *brickinfo);
+glusterd_brick_process_add_brick(glusterd_brickinfo_t *brickinfo);
int
-glusterd_brick_process_remove_brick (glusterd_brickinfo_t *brickinfo,
- int *last_brick);
+glusterd_brick_process_remove_brick(glusterd_brickinfo_t *brickinfo,
+ int *last_brick);
int
-glusterd_brick_proc_for_port (int port, glusterd_brick_proc_t **brickprocess);
+glusterd_brick_proc_for_port(int port, glusterd_brick_proc_t **brickprocess);
int32_t
-glusterd_volume_start_glusterfs (glusterd_volinfo_t *volinfo,
- glusterd_brickinfo_t *brickinfo,
- gf_boolean_t wait);
+glusterd_volume_start_glusterfs(glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t *brickinfo,
+ gf_boolean_t wait);
int32_t
-glusterd_volume_stop_glusterfs (glusterd_volinfo_t *volinfo,
- glusterd_brickinfo_t *brickinfo,
- gf_boolean_t del_brick);
+glusterd_volume_stop_glusterfs(glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t *brickinfo,
+ gf_boolean_t del_brick);
int
-send_attach_req (xlator_t *this, struct rpc_clnt *rpc, char *path,
- glusterd_brickinfo_t *brick,
- glusterd_brickinfo_t *other_brick, int op);
+send_attach_req(xlator_t *this, struct rpc_clnt *rpc, char *path,
+ glusterd_brickinfo_t *brick, glusterd_brickinfo_t *other_brick,
+ int op);
glusterd_volinfo_t *
-glusterd_volinfo_ref (glusterd_volinfo_t *volinfo);
+glusterd_volinfo_ref(glusterd_volinfo_t *volinfo);
glusterd_volinfo_t *
-glusterd_volinfo_unref (glusterd_volinfo_t *volinfo);
+glusterd_volinfo_unref(glusterd_volinfo_t *volinfo);
int32_t
-glusterd_volinfo_delete (glusterd_volinfo_t *volinfo);
+glusterd_volinfo_delete(glusterd_volinfo_t *volinfo);
int32_t
-glusterd_brickinfo_delete (glusterd_brickinfo_t *brickinfo);
+glusterd_brickinfo_delete(glusterd_brickinfo_t *brickinfo);
gf_boolean_t
-glusterd_is_cli_op_req (int32_t op);
+glusterd_is_cli_op_req(int32_t op);
int32_t
-glusterd_volume_brickinfo_get_by_brick (char *brick,
- glusterd_volinfo_t *volinfo,
- glusterd_brickinfo_t **brickinfo,
- gf_boolean_t construct_real_path);
+glusterd_volume_brickinfo_get_by_brick(char *brick, glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t **brickinfo,
+ gf_boolean_t construct_real_path);
int32_t
-glusterd_add_volumes_to_export_dict (dict_t **peer_data);
+glusterd_add_volumes_to_export_dict(dict_t **peer_data);
int32_t
-glusterd_compare_friend_data (dict_t *peer_data, int32_t *status,
- char *hostname);
+glusterd_compare_friend_data(dict_t *peer_data, int32_t *status,
+ char *hostname);
int
-glusterd_compute_cksum (glusterd_volinfo_t *volinfo,
- gf_boolean_t is_quota_conf);
+glusterd_compute_cksum(glusterd_volinfo_t *volinfo, gf_boolean_t is_quota_conf);
void
-glusterd_set_socket_filepath (char *sock_filepath, char *sockpath, size_t len);
+glusterd_set_socket_filepath(char *sock_filepath, char *sockpath, size_t len);
-struct rpc_clnt*
-glusterd_pending_node_get_rpc (glusterd_pending_node_t *pending_node);
+struct rpc_clnt *
+glusterd_pending_node_get_rpc(glusterd_pending_node_t *pending_node);
void
-glusterd_pending_node_put_rpc (glusterd_pending_node_t *pending_node);
+glusterd_pending_node_put_rpc(glusterd_pending_node_t *pending_node);
int
-glusterd_remote_hostname_get (rpcsvc_request_t *req,
- char *remote_host, int len);
+glusterd_remote_hostname_get(rpcsvc_request_t *req, char *remote_host, int len);
int32_t
-glusterd_import_friend_volumes_synctask (void *opaque);
+glusterd_import_friend_volumes_synctask(void *opaque);
int32_t
-glusterd_import_friend_volumes (dict_t *peer_data);
+glusterd_import_friend_volumes(dict_t *peer_data);
void
-glusterd_set_volume_status (glusterd_volinfo_t *volinfo,
- glusterd_volume_status status);
+glusterd_set_volume_status(glusterd_volinfo_t *volinfo,
+ glusterd_volume_status status);
int32_t
-glusterd_volume_count_get (void);
+glusterd_volume_count_get(void);
int32_t
-glusterd_add_volume_to_dict (glusterd_volinfo_t *volinfo,
- dict_t *dict, int32_t count,
- char *prefix);
+glusterd_add_volume_to_dict(glusterd_volinfo_t *volinfo, dict_t *dict,
+ int32_t count, char *prefix);
int
-glusterd_get_brickinfo (xlator_t *this, const char *brickname,
- int port, glusterd_brickinfo_t **brickinfo);
+glusterd_get_brickinfo(xlator_t *this, const char *brickname, int port,
+ glusterd_brickinfo_t **brickinfo);
void
-glusterd_set_brick_status (glusterd_brickinfo_t *brickinfo,
- gf_brick_status_t status);
+glusterd_set_brick_status(glusterd_brickinfo_t *brickinfo,
+ gf_brick_status_t status);
gf_boolean_t
-glusterd_is_brick_started (glusterd_brickinfo_t *brickinfo);
+glusterd_is_brick_started(glusterd_brickinfo_t *brickinfo);
int
-glusterd_friend_brick_belongs (glusterd_volinfo_t *volinfo,
- glusterd_brickinfo_t *brickinfo, void *uuid);
+glusterd_friend_brick_belongs(glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t *brickinfo, void *uuid);
int
-glusterd_all_volume_cond_check (glusterd_condition_func func, int status,
- void *ctx);
+glusterd_all_volume_cond_check(glusterd_condition_func func, int status,
+ void *ctx);
int
-glusterd_brick_start (glusterd_volinfo_t *volinfo,
- glusterd_brickinfo_t *brickinfo,
- gf_boolean_t wait,
- gf_boolean_t only_connect);
+glusterd_brick_start(glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t *brickinfo, gf_boolean_t wait,
+ gf_boolean_t only_connect);
int
-glusterd_brick_stop (glusterd_volinfo_t *volinfo,
- glusterd_brickinfo_t *brickinfo,
- gf_boolean_t del_brick);
+glusterd_brick_stop(glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t *brickinfo, gf_boolean_t del_brick);
gf_boolean_t
-glusterd_is_tier_daemon_running (glusterd_volinfo_t *volinfo);
+glusterd_is_tier_daemon_running(glusterd_volinfo_t *volinfo);
int32_t
-glusterd_add_tierd_to_dict (glusterd_volinfo_t *volinfo,
- dict_t *dict, int32_t count);
+glusterd_add_tierd_to_dict(glusterd_volinfo_t *volinfo, dict_t *dict,
+ int32_t count);
int
-glusterd_op_tier_status (dict_t *dict, char **op_errstr, dict_t *rsp_dict,
- glusterd_op_t op);
+glusterd_op_tier_status(dict_t *dict, char **op_errstr, dict_t *rsp_dict,
+ glusterd_op_t op);
int
-glusterd_is_defrag_on (glusterd_volinfo_t *volinfo);
+glusterd_is_defrag_on(glusterd_volinfo_t *volinfo);
int32_t
-glusterd_volinfo_bricks_delete (glusterd_volinfo_t *volinfo);
+glusterd_volinfo_bricks_delete(glusterd_volinfo_t *volinfo);
int
-glusterd_new_brick_validate (char *brick, glusterd_brickinfo_t *brickinfo,
- char *op_errstr, size_t len, char *op);
+glusterd_new_brick_validate(char *brick, glusterd_brickinfo_t *brickinfo,
+ char *op_errstr, size_t len, char *op);
int32_t
-glusterd_volume_brickinfos_delete (glusterd_volinfo_t *volinfo);
+glusterd_volume_brickinfos_delete(glusterd_volinfo_t *volinfo);
int32_t
-glusterd_volume_brickinfo_get (uuid_t uuid, char *hostname, char *path,
- glusterd_volinfo_t *volinfo,
- glusterd_brickinfo_t **brickinfo);
+glusterd_volume_brickinfo_get(uuid_t uuid, char *hostname, char *path,
+ glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t **brickinfo);
int
-glusterd_brickinfo_get (uuid_t uuid, char *hostname, char *path,
+glusterd_brickinfo_get(uuid_t uuid, char *hostname, char *path,
glusterd_brickinfo_t **brickinfo);
-
int
-glusterd_rb_check_bricks (glusterd_volinfo_t *volinfo,
- glusterd_brickinfo_t *src_brick,
- glusterd_brickinfo_t *dst_brick);
+glusterd_rb_check_bricks(glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t *src_brick,
+ glusterd_brickinfo_t *dst_brick);
int
-glusterd_check_and_set_brick_xattr (char *host, char *path, uuid_t uuid,
- char **op_errstr, gf_boolean_t is_force);
+glusterd_check_and_set_brick_xattr(char *host, char *path, uuid_t uuid,
+ char **op_errstr, gf_boolean_t is_force);
int
-glusterd_validate_and_create_brickpath (glusterd_brickinfo_t *brickinfo,
- uuid_t volume_id, char **op_errstr,
- gf_boolean_t is_force,
- gf_boolean_t ignore_partition);
+glusterd_validate_and_create_brickpath(glusterd_brickinfo_t *brickinfo,
+ uuid_t volume_id, char **op_errstr,
+ gf_boolean_t is_force,
+ gf_boolean_t ignore_partition);
int
-glusterd_sm_tr_log_transition_add (glusterd_sm_tr_log_t *log,
- int old_state, int new_state,
- int event);
+glusterd_sm_tr_log_transition_add(glusterd_sm_tr_log_t *log, int old_state,
+ int new_state, int event);
int
-glusterd_sm_tr_log_init (glusterd_sm_tr_log_t *log,
- char * (*state_name_get) (int),
- char * (*event_name_get) (int),
- size_t size);
+glusterd_sm_tr_log_init(glusterd_sm_tr_log_t *log, char *(*state_name_get)(int),
+ char *(*event_name_get)(int), size_t size);
void
-glusterd_sm_tr_log_delete (glusterd_sm_tr_log_t *log);
+glusterd_sm_tr_log_delete(glusterd_sm_tr_log_t *log);
int
-glusterd_sm_tr_log_add_to_dict (dict_t *dict,
- glusterd_sm_tr_log_t *circular_log);
+glusterd_sm_tr_log_add_to_dict(dict_t *dict,
+ glusterd_sm_tr_log_t *circular_log);
int
-glusterd_remove_pending_entry (struct cds_list_head *list, void *elem);
+glusterd_remove_pending_entry(struct cds_list_head *list, void *elem);
int
-glusterd_clear_pending_nodes (struct cds_list_head *list);
+glusterd_clear_pending_nodes(struct cds_list_head *list);
int32_t
-glusterd_brick_connect (glusterd_volinfo_t *volinfo,
- glusterd_brickinfo_t *brickinfo, char *socketpath);
+glusterd_brick_connect(glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t *brickinfo, char *socketpath);
int32_t
-glusterd_brick_disconnect (glusterd_brickinfo_t *brickinfo);
+glusterd_brick_disconnect(glusterd_brickinfo_t *brickinfo);
int32_t
-glusterd_delete_volume (glusterd_volinfo_t *volinfo);
+glusterd_delete_volume(glusterd_volinfo_t *volinfo);
int32_t
-glusterd_delete_brick (glusterd_volinfo_t* volinfo,
- glusterd_brickinfo_t *brickinfo);
+glusterd_delete_brick(glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t *brickinfo);
int32_t
-glusterd_delete_all_bricks (glusterd_volinfo_t* volinfo);
+glusterd_delete_all_bricks(glusterd_volinfo_t *volinfo);
int
-glusterd_spawn_daemons (void *opaque);
+glusterd_spawn_daemons(void *opaque);
int
-glusterd_restart_gsyncds (glusterd_conf_t *conf);
+glusterd_restart_gsyncds(glusterd_conf_t *conf);
int
-glusterd_start_gsync (glusterd_volinfo_t *master_vol, char *slave,
- char *path_list, char *conf_path,
- char *glusterd_uuid_str,
- char **op_errstr, gf_boolean_t is_pause);
+glusterd_start_gsync(glusterd_volinfo_t *master_vol, char *slave,
+ char *path_list, char *conf_path, char *glusterd_uuid_str,
+ char **op_errstr, gf_boolean_t is_pause);
int
-glusterd_get_local_brickpaths (glusterd_volinfo_t *volinfo,
- char **pathlist);
+glusterd_get_local_brickpaths(glusterd_volinfo_t *volinfo, char **pathlist);
int32_t
-glusterd_recreate_bricks (glusterd_conf_t *conf);
+glusterd_recreate_bricks(glusterd_conf_t *conf);
int32_t
-glusterd_handle_upgrade_downgrade (dict_t *options, glusterd_conf_t *conf,
- gf_boolean_t upgrade,
- gf_boolean_t downgrade);
+glusterd_handle_upgrade_downgrade(dict_t *options, glusterd_conf_t *conf,
+ gf_boolean_t upgrade, gf_boolean_t downgrade);
int
-glusterd_add_brick_detail_to_dict (glusterd_volinfo_t *volinfo,
- glusterd_brickinfo_t *brickinfo,
- dict_t *dict, int32_t count);
+glusterd_add_brick_detail_to_dict(glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t *brickinfo, dict_t *dict,
+ int32_t count);
int32_t
-glusterd_add_brick_to_dict (glusterd_volinfo_t *volinfo,
- glusterd_brickinfo_t *brickinfo,
- dict_t *dict, int32_t count);
+glusterd_add_brick_to_dict(glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t *brickinfo, dict_t *dict,
+ int32_t count);
int32_t
-glusterd_get_all_volnames (dict_t *dict);
+glusterd_get_all_volnames(dict_t *dict);
gf_boolean_t
-glusterd_is_fuse_available ();
+glusterd_is_fuse_available();
int
-glusterd_brick_statedump (glusterd_volinfo_t *volinfo,
- glusterd_brickinfo_t *brickinfo,
- char *options, int option_cnt, char **op_errstr);
+glusterd_brick_statedump(glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t *brickinfo, char *options,
+ int option_cnt, char **op_errstr);
int
-glusterd_brick_terminate (glusterd_volinfo_t *volinfo,
- glusterd_brickinfo_t *brickinfo,
- char *options, int option_cnt, char **op_errstr);
+glusterd_brick_terminate(glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t *brickinfo, char *options,
+ int option_cnt, char **op_errstr);
int
-glusterd_nfs_statedump (char *options, int option_cnt, char **op_errstr);
+glusterd_nfs_statedump(char *options, int option_cnt, char **op_errstr);
int
-glusterd_client_statedump (char *volname, char *options, int option_cnt,
- char **op_errstr);
+glusterd_client_statedump(char *volname, char *options, int option_cnt,
+ char **op_errstr);
int
-glusterd_quotad_statedump (char *options, int option_cnt, char **op_errstr);
+glusterd_quotad_statedump(char *options, int option_cnt, char **op_errstr);
gf_boolean_t
-glusterd_is_volume_replicate (glusterd_volinfo_t *volinfo);
+glusterd_is_volume_replicate(glusterd_volinfo_t *volinfo);
gf_boolean_t
-glusterd_is_brick_decommissioned (glusterd_volinfo_t *volinfo, char *hostname,
- char *path);
+glusterd_is_brick_decommissioned(glusterd_volinfo_t *volinfo, char *hostname,
+ char *path);
int
-glusterd_friend_contains_vol_bricks (glusterd_volinfo_t *volinfo,
- uuid_t friend_uuid);
+glusterd_friend_contains_vol_bricks(glusterd_volinfo_t *volinfo,
+ uuid_t friend_uuid);
int
-glusterd_friend_contains_snap_bricks (glusterd_snap_t *snapinfo,
+glusterd_friend_contains_snap_bricks(glusterd_snap_t *snapinfo,
uuid_t friend_uuid);
int
-glusterd_friend_remove_cleanup_vols (uuid_t uuid);
+glusterd_friend_remove_cleanup_vols(uuid_t uuid);
int
-glusterd_get_client_filepath (char *filepath,
- glusterd_volinfo_t *volinfo,
- gf_transport_type type);
+glusterd_get_client_filepath(char *filepath, glusterd_volinfo_t *volinfo,
+ gf_transport_type type);
int
-glusterd_get_trusted_client_filepath (char *filepath,
- glusterd_volinfo_t *volinfo,
- gf_transport_type type);
+glusterd_get_trusted_client_filepath(char *filepath,
+ glusterd_volinfo_t *volinfo,
+ gf_transport_type type);
int
-glusterd_restart_rebalance (glusterd_conf_t *conf);
+glusterd_restart_rebalance(glusterd_conf_t *conf);
int32_t
-glusterd_create_sub_tier_volinfo (glusterd_volinfo_t *volinfo,
- glusterd_volinfo_t **dup_volinfo,
- gf_boolean_t is_hot_tier,
- const char *new_name);
+glusterd_create_sub_tier_volinfo(glusterd_volinfo_t *volinfo,
+ glusterd_volinfo_t **dup_volinfo,
+ gf_boolean_t is_hot_tier,
+ const char *new_name);
int
-glusterd_restart_rebalance_for_volume (glusterd_volinfo_t *volinfo);
+glusterd_restart_rebalance_for_volume(glusterd_volinfo_t *volinfo);
void
-glusterd_defrag_info_set (glusterd_volinfo_t *volinfo, dict_t *dict, int cmd,
- int status, int op);
+glusterd_defrag_info_set(glusterd_volinfo_t *volinfo, dict_t *dict, int cmd,
+ int status, int op);
int32_t
-glusterd_add_bricks_hname_path_to_dict (dict_t *dict,
- glusterd_volinfo_t *volinfo);
+glusterd_add_bricks_hname_path_to_dict(dict_t *dict,
+ glusterd_volinfo_t *volinfo);
int
-glusterd_add_node_to_dict (char *server, dict_t *dict, int count,
- dict_t *vol_opts);
+glusterd_add_node_to_dict(char *server, dict_t *dict, int count,
+ dict_t *vol_opts);
int
-glusterd_calc_dist_leaf_count (int rcount, int scount);
+glusterd_calc_dist_leaf_count(int rcount, int scount);
int
-glusterd_get_dist_leaf_count (glusterd_volinfo_t *volinfo);
+glusterd_get_dist_leaf_count(glusterd_volinfo_t *volinfo);
-glusterd_brickinfo_t*
-glusterd_get_brickinfo_by_position (glusterd_volinfo_t *volinfo, uint32_t pos);
+glusterd_brickinfo_t *
+glusterd_get_brickinfo_by_position(glusterd_volinfo_t *volinfo, uint32_t pos);
gf_boolean_t
-glusterd_is_local_brick (xlator_t *this, glusterd_volinfo_t *volinfo,
- glusterd_brickinfo_t *brickinfo);
+glusterd_is_local_brick(xlator_t *this, glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t *brickinfo);
int
-glusterd_validate_volume_id (dict_t *op_dict, glusterd_volinfo_t *volinfo);
+glusterd_validate_volume_id(dict_t *op_dict, glusterd_volinfo_t *volinfo);
int
-glusterd_defrag_volume_status_update (glusterd_volinfo_t *volinfo,
- dict_t *rsp_dict, int32_t cmd);
+glusterd_defrag_volume_status_update(glusterd_volinfo_t *volinfo,
+ dict_t *rsp_dict, int32_t cmd);
int
-glusterd_check_files_identical (char *filename1, char *filename2,
- gf_boolean_t *identical);
+glusterd_check_files_identical(char *filename1, char *filename2,
+ gf_boolean_t *identical);
int
-glusterd_check_topology_identical (const char *filename1,
- const char *filename2,
- gf_boolean_t *identical);
+glusterd_check_topology_identical(const char *filename1, const char *filename2,
+ gf_boolean_t *identical);
void
-glusterd_volinfo_reset_defrag_stats (glusterd_volinfo_t *volinfo);
+glusterd_volinfo_reset_defrag_stats(glusterd_volinfo_t *volinfo);
int
-glusterd_volset_help (dict_t *dict, char **op_errstr);
+glusterd_volset_help(dict_t *dict, char **op_errstr);
int32_t
-glusterd_sync_use_rsp_dict (dict_t *aggr, dict_t *rsp_dict);
+glusterd_sync_use_rsp_dict(dict_t *aggr, dict_t *rsp_dict);
int32_t
-glusterd_gsync_use_rsp_dict (dict_t *aggr, dict_t *rsp_dict, char *op_errstr);
+glusterd_gsync_use_rsp_dict(dict_t *aggr, dict_t *rsp_dict, char *op_errstr);
int32_t
-glusterd_rb_use_rsp_dict (dict_t *aggr, dict_t *rsp_dict);
+glusterd_rb_use_rsp_dict(dict_t *aggr, dict_t *rsp_dict);
int
-glusterd_profile_volume_use_rsp_dict (dict_t *aggr, dict_t *rsp_dict);
+glusterd_profile_volume_use_rsp_dict(dict_t *aggr, dict_t *rsp_dict);
int
-glusterd_volume_status_copy_to_op_ctx_dict (dict_t *aggr, dict_t *rsp_dict);
+glusterd_volume_status_copy_to_op_ctx_dict(dict_t *aggr, dict_t *rsp_dict);
int
-glusterd_volume_rebalance_use_rsp_dict (dict_t *aggr, dict_t *rsp_dict);
+glusterd_volume_rebalance_use_rsp_dict(dict_t *aggr, dict_t *rsp_dict);
int
-glusterd_volume_tier_use_rsp_dict (dict_t *aggr, dict_t *rsp_dict);
+glusterd_volume_tier_use_rsp_dict(dict_t *aggr, dict_t *rsp_dict);
int
-glusterd_volume_heal_use_rsp_dict (dict_t *aggr, dict_t *rsp_dict);
+glusterd_volume_heal_use_rsp_dict(dict_t *aggr, dict_t *rsp_dict);
int
-glusterd_use_rsp_dict (dict_t *aggr, dict_t *rsp_dict);
+glusterd_use_rsp_dict(dict_t *aggr, dict_t *rsp_dict);
int
-glusterd_sys_exec_output_rsp_dict (dict_t *aggr, dict_t *rsp_dict);
+glusterd_sys_exec_output_rsp_dict(dict_t *aggr, dict_t *rsp_dict);
int32_t
-glusterd_handle_node_rsp (dict_t *req_ctx, void *pending_entry,
- glusterd_op_t op, dict_t *rsp_dict, dict_t *op_ctx,
- char **op_errstr, gd_node_type type);
+glusterd_handle_node_rsp(dict_t *req_ctx, void *pending_entry, glusterd_op_t op,
+ dict_t *rsp_dict, dict_t *op_ctx, char **op_errstr,
+ gd_node_type type);
int
-glusterd_max_opversion_use_rsp_dict (dict_t *dst, dict_t *src);
+glusterd_max_opversion_use_rsp_dict(dict_t *dst, dict_t *src);
int
-glusterd_volume_bitrot_scrub_use_rsp_dict (dict_t *aggr, dict_t *rsp_dict);
+glusterd_volume_bitrot_scrub_use_rsp_dict(dict_t *aggr, dict_t *rsp_dict);
int
-glusterd_volume_heal_use_rsp_dict (dict_t *aggr, dict_t *rsp_dict);
+glusterd_volume_heal_use_rsp_dict(dict_t *aggr, dict_t *rsp_dict);
int32_t
-glusterd_check_if_quota_trans_enabled (glusterd_volinfo_t *volinfo);
+glusterd_check_if_quota_trans_enabled(glusterd_volinfo_t *volinfo);
int
-glusterd_volume_quota_copy_to_op_ctx_dict (dict_t *aggr, dict_t *rsp);
+glusterd_volume_quota_copy_to_op_ctx_dict(dict_t *aggr, dict_t *rsp);
int
-_profile_volume_add_brick_rsp (dict_t *this, char *key, data_t *value,
- void *data);
+_profile_volume_add_brick_rsp(dict_t *this, char *key, data_t *value,
+ void *data);
int
-glusterd_profile_volume_brick_rsp (void *pending_entry,
- dict_t *rsp_dict, dict_t *op_ctx,
- char **op_errstr, gd_node_type type);
+glusterd_profile_volume_brick_rsp(void *pending_entry, dict_t *rsp_dict,
+ dict_t *op_ctx, char **op_errstr,
+ gd_node_type type);
int32_t
-glusterd_set_originator_uuid (dict_t *dict);
+glusterd_set_originator_uuid(dict_t *dict);
/* Should be used only when an operation is in progress, as that is the only
* time a lock_owner is set
*/
gf_boolean_t
-is_origin_glusterd (dict_t *dict);
+is_origin_glusterd(dict_t *dict);
int
-glusterd_get_next_global_opt_version_str (dict_t *opts, char **version_str);
+glusterd_get_next_global_opt_version_str(dict_t *opts, char **version_str);
int
-glusterd_generate_and_set_task_id (dict_t *dict, char *key, const int keylen);
+glusterd_generate_and_set_task_id(dict_t *dict, char *key, const int keylen);
int
-glusterd_validate_and_set_gfid (dict_t *op_ctx, dict_t *req_dict,
- char **op_errstr);
+glusterd_validate_and_set_gfid(dict_t *op_ctx, dict_t *req_dict,
+ char **op_errstr);
int
-glusterd_copy_uuid_to_dict (uuid_t uuid, dict_t *dict, char *key,
- const int keylen);
+glusterd_copy_uuid_to_dict(uuid_t uuid, dict_t *dict, char *key,
+ const int keylen);
gf_boolean_t
-glusterd_is_same_address (char *name1, char *name2);
+glusterd_is_same_address(char *name1, char *name2);
void
-gd_update_volume_op_versions (glusterd_volinfo_t *volinfo);
+gd_update_volume_op_versions(glusterd_volinfo_t *volinfo);
int
-op_version_check (xlator_t *this, int min_op_version, char *msg, int msglen);
+op_version_check(xlator_t *this, int min_op_version, char *msg, int msglen);
gf_boolean_t
-gd_is_remove_brick_committed (glusterd_volinfo_t *volinfo);
+gd_is_remove_brick_committed(glusterd_volinfo_t *volinfo);
int
-glusterd_remove_brick_validate_bricks (gf1_op_commands cmd, int32_t brick_count,
- dict_t *dict,
- glusterd_volinfo_t *volinfo,
- char **errstr, gf_cli_defrag_type);
+glusterd_remove_brick_validate_bricks(gf1_op_commands cmd, int32_t brick_count,
+ dict_t *dict, glusterd_volinfo_t *volinfo,
+ char **errstr, gf_cli_defrag_type);
int
-glusterd_get_slave_details_confpath (glusterd_volinfo_t *volinfo,
- dict_t *dict, char **slave_url,
- char **slave_host, char **slave_vol,
- char **conf_path, char **op_errstr);
+glusterd_get_slave_details_confpath(glusterd_volinfo_t *volinfo, dict_t *dict,
+ char **slave_url, char **slave_host,
+ char **slave_vol, char **conf_path,
+ char **op_errstr);
int
-glusterd_get_slave_info (char *slave,
- char **slave_url, char **hostname,
- char **slave_vol, char **op_errstr);
+glusterd_get_slave_info(char *slave, char **slave_url, char **hostname,
+ char **slave_vol, char **op_errstr);
int
-glusterd_get_statefile_name (glusterd_volinfo_t *volinfo, char *slave,
- char *conf_path, char **statefile,
- gf_boolean_t *is_template_in_use);
+glusterd_get_statefile_name(glusterd_volinfo_t *volinfo, char *slave,
+ char *conf_path, char **statefile,
+ gf_boolean_t *is_template_in_use);
int
-glusterd_gsync_read_frm_status (char *path, char *buf, size_t blen);
+glusterd_gsync_read_frm_status(char *path, char *buf, size_t blen);
int
-glusterd_create_status_file (char *master, char *slave, char *slave_url,
- char *slave_vol, char *status);
+glusterd_create_status_file(char *master, char *slave, char *slave_url,
+ char *slave_vol, char *status);
int
-glusterd_check_restart_gsync_session (glusterd_volinfo_t *volinfo, char *slave,
- dict_t *resp_dict, char *path_list,
- char *conf_path, gf_boolean_t is_force);
+glusterd_check_restart_gsync_session(glusterd_volinfo_t *volinfo, char *slave,
+ dict_t *resp_dict, char *path_list,
+ char *conf_path, gf_boolean_t is_force);
int
-glusterd_check_gsync_running_local (char *master, char *slave,
- char *conf_path,
- gf_boolean_t *is_run);
+glusterd_check_gsync_running_local(char *master, char *slave, char *conf_path,
+ gf_boolean_t *is_run);
gf_boolean_t
-glusterd_is_status_tasks_op (glusterd_op_t op, dict_t *dict);
+glusterd_is_status_tasks_op(glusterd_op_t op, dict_t *dict);
gf_boolean_t
-gd_should_i_start_rebalance (glusterd_volinfo_t *volinfo);
+gd_should_i_start_rebalance(glusterd_volinfo_t *volinfo);
int
-glusterd_is_tierd_enabled (glusterd_volinfo_t *volinfo);
+glusterd_is_tierd_enabled(glusterd_volinfo_t *volinfo);
int
-glusterd_is_tierd_supposed_to_be_enabled (glusterd_volinfo_t *volinfo);
+glusterd_is_tierd_supposed_to_be_enabled(glusterd_volinfo_t *volinfo);
int
-glusterd_is_volume_quota_enabled (glusterd_volinfo_t *volinfo);
+glusterd_is_volume_quota_enabled(glusterd_volinfo_t *volinfo);
int
-glusterd_is_volume_inode_quota_enabled (glusterd_volinfo_t *volinfo);
+glusterd_is_volume_inode_quota_enabled(glusterd_volinfo_t *volinfo);
int
-glusterd_is_bitrot_enabled (glusterd_volinfo_t *volinfo);
+glusterd_is_bitrot_enabled(glusterd_volinfo_t *volinfo);
gf_boolean_t
-glusterd_all_volumes_with_quota_stopped ();
+glusterd_all_volumes_with_quota_stopped();
void
-glusterd_clean_up_quota_store (glusterd_volinfo_t *volinfo);
+glusterd_clean_up_quota_store(glusterd_volinfo_t *volinfo);
int
-glusterd_remove_auxiliary_mount (char *volname);
+glusterd_remove_auxiliary_mount(char *volname);
gf_boolean_t
-glusterd_status_has_tasks (int cmd);
+glusterd_status_has_tasks(int cmd);
int
-gd_stop_rebalance_process (glusterd_volinfo_t *volinfo);
+gd_stop_rebalance_process(glusterd_volinfo_t *volinfo);
rpc_clnt_t *
-glusterd_rpc_clnt_unref (glusterd_conf_t *conf, rpc_clnt_t *rpc);
+glusterd_rpc_clnt_unref(glusterd_conf_t *conf, rpc_clnt_t *rpc);
int32_t
glusterd_compare_volume_name(struct cds_list_head *, struct cds_list_head *);
-char*
-glusterd_get_brick_mount_device (char *brick_path);
+char *
+glusterd_get_brick_mount_device(char *brick_path);
struct mntent *
-glusterd_get_mnt_entry_info (char *mnt_pt, char *buff, int buflen,
- struct mntent *entry_ptr);
+glusterd_get_mnt_entry_info(char *mnt_pt, char *buff, int buflen,
+ struct mntent *entry_ptr);
int
-glusterd_get_brick_root (char *path, char **mount_point);
+glusterd_get_brick_root(char *path, char **mount_point);
int32_t
-glusterd_lvm_snapshot_remove (dict_t *rsp_dict, glusterd_volinfo_t *snap_vol);
+glusterd_lvm_snapshot_remove(dict_t *rsp_dict, glusterd_volinfo_t *snap_vol);
gf_boolean_t
-gd_vol_is_geo_rep_active (glusterd_volinfo_t *volinfo);
+gd_vol_is_geo_rep_active(glusterd_volinfo_t *volinfo);
int32_t
-glusterd_get_brick_mount_dir (char *brickpath, char *hostname, char *mount_dir);
+glusterd_get_brick_mount_dir(char *brickpath, char *hostname, char *mount_dir);
int32_t
-glusterd_aggr_brick_mount_dirs (dict_t *aggr, dict_t *rsp_dict);
+glusterd_aggr_brick_mount_dirs(dict_t *aggr, dict_t *rsp_dict);
int32_t
-glusterd_take_lvm_snapshot (glusterd_brickinfo_t *brickinfo,
- char *origin_brick_path);
+glusterd_take_lvm_snapshot(glusterd_brickinfo_t *brickinfo,
+ char *origin_brick_path);
void
-glusterd_launch_synctask (synctask_fn_t fn, void *opaque);
+glusterd_launch_synctask(synctask_fn_t fn, void *opaque);
int
-glusterd_enable_default_options (glusterd_volinfo_t *volinfo, char *option);
+glusterd_enable_default_options(glusterd_volinfo_t *volinfo, char *option);
int
-glusterd_unlink_file (char *sock_file_path);
+glusterd_unlink_file(char *sock_file_path);
int32_t
-glusterd_find_brick_mount_path (char *brick_path, char **brick_mount_path);
+glusterd_find_brick_mount_path(char *brick_path, char **brick_mount_path);
/*
* Function to retrieve list of snap volnames and their uuids
*/
-int glusterd_snapshot_get_volnames_uuids (dict_t *dict,
- char *volname, gf_getsnap_name_uuid_rsp *snap_info_rsp);
+int
+glusterd_snapshot_get_volnames_uuids(dict_t *dict, char *volname,
+ gf_getsnap_name_uuid_rsp *snap_info_rsp);
int
-glusterd_update_mntopts (char *brick_path, glusterd_brickinfo_t *brickinfo);
+glusterd_update_mntopts(char *brick_path, glusterd_brickinfo_t *brickinfo);
int
-glusterd_update_fs_label (glusterd_brickinfo_t *brickinfo);
+glusterd_update_fs_label(glusterd_brickinfo_t *brickinfo);
int
-glusterd_get_volopt_content (dict_t *dict, gf_boolean_t xml_out);
+glusterd_get_volopt_content(dict_t *dict, gf_boolean_t xml_out);
int
-glusterd_get_global_max_op_version (rpcsvc_request_t *req, dict_t *ctx,
- int count);
+glusterd_get_global_max_op_version(rpcsvc_request_t *req, dict_t *ctx,
+ int count);
int
-glusterd_get_global_options_for_all_vols (rpcsvc_request_t *req, dict_t *dict,
- char **op_errstr);
+glusterd_get_global_options_for_all_vols(rpcsvc_request_t *req, dict_t *dict,
+ char **op_errstr);
int
-glusterd_get_default_val_for_volopt (dict_t *dict, gf_boolean_t all_opts,
- char *key, char *orig_key,
- glusterd_volinfo_t *volinfo,
- char **err_str);
+glusterd_get_default_val_for_volopt(dict_t *dict, gf_boolean_t all_opts,
+ char *key, char *orig_key,
+ glusterd_volinfo_t *volinfo,
+ char **err_str);
int
-glusterd_check_client_op_version_support (char *volname, uint32_t op_version,
- char **op_errstr);
+glusterd_check_client_op_version_support(char *volname, uint32_t op_version,
+ char **op_errstr);
gf_boolean_t
-glusterd_have_peers ();
+glusterd_have_peers();
gf_boolean_t
-glusterd_have_volumes ();
+glusterd_have_volumes();
void
-glusterd_get_rebalance_volfile (glusterd_volinfo_t *volinfo,
- char *path, int path_len);
+glusterd_get_rebalance_volfile(glusterd_volinfo_t *volinfo, char *path,
+ int path_len);
void
-glusterd_get_gfproxy_client_volfile (glusterd_volinfo_t *volinfo,
- char *path, int path_len);
+glusterd_get_gfproxy_client_volfile(glusterd_volinfo_t *volinfo, char *path,
+ int path_len);
int32_t
-glusterd_brickinfo_dup (glusterd_brickinfo_t *brickinfo,
- glusterd_brickinfo_t *dup_brickinfo);
+glusterd_brickinfo_dup(glusterd_brickinfo_t *brickinfo,
+ glusterd_brickinfo_t *dup_brickinfo);
int
-glusterd_vol_add_quota_conf_to_dict (glusterd_volinfo_t *volinfo, dict_t *load,
- int vol_idx, char *prefix);
+glusterd_vol_add_quota_conf_to_dict(glusterd_volinfo_t *volinfo, dict_t *load,
+ int vol_idx, char *prefix);
int32_t
-glusterd_import_volinfo (dict_t *peer_data, int count,
- glusterd_volinfo_t **volinfo,
- char *prefix);
+glusterd_import_volinfo(dict_t *peer_data, int count,
+ glusterd_volinfo_t **volinfo, char *prefix);
int
-glusterd_import_quota_conf (dict_t *peer_data, int vol_idx,
- glusterd_volinfo_t *new_volinfo,
- char *prefix);
+glusterd_import_quota_conf(dict_t *peer_data, int vol_idx,
+ glusterd_volinfo_t *new_volinfo, char *prefix);
gf_boolean_t
-glusterd_is_shd_compatible_volume (glusterd_volinfo_t *volinfo);
+glusterd_is_shd_compatible_volume(glusterd_volinfo_t *volinfo);
gf_boolean_t
-glusterd_is_shd_compatible_type (int type);
+glusterd_is_shd_compatible_type(int type);
gf_boolean_t
-glusterd_are_all_volumes_stopped ();
+glusterd_are_all_volumes_stopped();
gf_boolean_t
-glusterd_all_shd_compatible_volumes_stopped ();
+glusterd_all_shd_compatible_volumes_stopped();
void
-glusterd_nfs_pmap_deregister ();
+glusterd_nfs_pmap_deregister();
gf_boolean_t
-glusterd_is_volume_started (glusterd_volinfo_t *volinfo);
+glusterd_is_volume_started(glusterd_volinfo_t *volinfo);
int
-glusterd_volume_get_type_str (glusterd_volinfo_t *volinfo, char **vol_type_str);
+glusterd_volume_get_type_str(glusterd_volinfo_t *volinfo, char **vol_type_str);
int
-glusterd_volume_get_status_str (glusterd_volinfo_t *volinfo, char *status_str);
+glusterd_volume_get_status_str(glusterd_volinfo_t *volinfo, char *status_str);
int
-glusterd_volume_get_transport_type_str (glusterd_volinfo_t *volinfo,
- char *transport_type_str);
+glusterd_volume_get_transport_type_str(glusterd_volinfo_t *volinfo,
+ char *transport_type_str);
int
-glusterd_volume_get_quorum_status_str (glusterd_volinfo_t *volinfo,
- char *quorum_status_str);
+glusterd_volume_get_quorum_status_str(glusterd_volinfo_t *volinfo,
+ char *quorum_status_str);
int
-glusterd_volume_get_rebalance_status_str (glusterd_volinfo_t *volinfo,
- char *rebal_status_str);
+glusterd_volume_get_rebalance_status_str(glusterd_volinfo_t *volinfo,
+ char *rebal_status_str);
int
-glusterd_volume_get_hot_tier_type_str (glusterd_volinfo_t *volinfo,
- char **hot_tier_type_str);
+glusterd_volume_get_hot_tier_type_str(glusterd_volinfo_t *volinfo,
+ char **hot_tier_type_str);
int
-glusterd_volume_get_cold_tier_type_str (glusterd_volinfo_t *volinfo,
- char **cold_tier_type_str);
+glusterd_volume_get_cold_tier_type_str(glusterd_volinfo_t *volinfo,
+ char **cold_tier_type_str);
void
-glusterd_list_add_order (struct cds_list_head *new, struct cds_list_head *head,
+glusterd_list_add_order(struct cds_list_head *new, struct cds_list_head *head,
int (*compare)(struct cds_list_head *,
struct cds_list_head *));
int
-glusterd_disallow_op_for_tier (glusterd_volinfo_t *volinfo, glusterd_op_t op,
- int cmd);
+glusterd_disallow_op_for_tier(glusterd_volinfo_t *volinfo, glusterd_op_t op,
+ int cmd);
-struct rpc_clnt*
-glusterd_defrag_rpc_get (glusterd_defrag_info_t *defrag);
+struct rpc_clnt *
+glusterd_defrag_rpc_get(glusterd_defrag_info_t *defrag);
-struct rpc_clnt*
-glusterd_defrag_rpc_put (glusterd_defrag_info_t *defrag);
+struct rpc_clnt *
+glusterd_defrag_rpc_put(glusterd_defrag_info_t *defrag);
int32_t
-glusterd_count_connected_peers (int32_t *count);
+glusterd_count_connected_peers(int32_t *count);
int
-glusterd_volume_brick_for_each (glusterd_volinfo_t *volinfo, void *data,
- int (*fn) (glusterd_volinfo_t *, glusterd_brickinfo_t *,
- dict_t *mod_dict, void *));
+glusterd_volume_brick_for_each(glusterd_volinfo_t *volinfo, void *data,
+ int (*fn)(glusterd_volinfo_t *,
+ glusterd_brickinfo_t *,
+ dict_t *mod_dict, void *));
int
-glusterd_get_dummy_client_filepath (char *filepath,
- glusterd_volinfo_t *volinfo,
- gf_transport_type type);
+glusterd_get_dummy_client_filepath(char *filepath, glusterd_volinfo_t *volinfo,
+ gf_transport_type type);
int
-glusterd_handle_replicate_brick_ops (glusterd_volinfo_t *volinfo,
- glusterd_brickinfo_t *brickinfo,
- glusterd_op_t op);
+glusterd_handle_replicate_brick_ops(glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t *brickinfo,
+ glusterd_op_t op);
void
-assign_brick_groups (glusterd_volinfo_t *volinfo);
+assign_brick_groups(glusterd_volinfo_t *volinfo);
-glusterd_brickinfo_t*
-get_last_brick_of_brick_group (glusterd_volinfo_t *volinfo,
- glusterd_brickinfo_t *brickinfo);
+glusterd_brickinfo_t *
+get_last_brick_of_brick_group(glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t *brickinfo);
int
-glusterd_get_rb_dst_brickinfo (glusterd_volinfo_t *volinfo,
- glusterd_brickinfo_t **brickinfo);
+glusterd_get_rb_dst_brickinfo(glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t **brickinfo);
int
-rb_update_dstbrick_port (glusterd_brickinfo_t *dst_brickinfo, dict_t *rsp_dict,
- dict_t *req_dict);
+rb_update_dstbrick_port(glusterd_brickinfo_t *dst_brickinfo, dict_t *rsp_dict,
+ dict_t *req_dict);
int
-glusterd_op_perform_replace_brick (glusterd_volinfo_t *volinfo,
- char *old_brick, char *new_brick,
- dict_t *dict);
+glusterd_op_perform_replace_brick(glusterd_volinfo_t *volinfo, char *old_brick,
+ char *new_brick, dict_t *dict);
int32_t
-glusterd_brick_unlink_socket_file (glusterd_volinfo_t *volinfo,
- glusterd_brickinfo_t *brickinfo);
+glusterd_brick_unlink_socket_file(glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t *brickinfo);
char *
-gd_rb_op_to_str (char *op);
+gd_rb_op_to_str(char *op);
glusterd_op_t
-gd_cli_to_gd_op (char *cli_op);
+gd_cli_to_gd_op(char *cli_op);
int
-glusterd_get_dst_brick_info (char **dst_brick, char *volname, char **op_errstr,
- glusterd_brickinfo_t **dst_brickinfo, char **host,
- dict_t *dict, char **dup_dstbrick);
+glusterd_get_dst_brick_info(char **dst_brick, char *volname, char **op_errstr,
+ glusterd_brickinfo_t **dst_brickinfo, char **host,
+ dict_t *dict, char **dup_dstbrick);
int
-glusterd_brick_op_prerequisites (dict_t *dict,
- char **op,
- glusterd_op_t *gd_op, char **volname,
- glusterd_volinfo_t **volinfo,
- char **src_brick, glusterd_brickinfo_t
- **src_brickinfo, char *pidfile,
- char **op_errstr, dict_t *rsp_dict);
+glusterd_brick_op_prerequisites(dict_t *dict, char **op, glusterd_op_t *gd_op,
+ char **volname, glusterd_volinfo_t **volinfo,
+ char **src_brick,
+ glusterd_brickinfo_t **src_brickinfo,
+ char *pidfile, char **op_errstr,
+ dict_t *rsp_dict);
int
-glusterd_get_volinfo_from_brick (char *brick, glusterd_volinfo_t **volinfo);
+glusterd_get_volinfo_from_brick(char *brick, glusterd_volinfo_t **volinfo);
gf_boolean_t
-glusterd_is_profile_on (glusterd_volinfo_t *volinfo);
+glusterd_is_profile_on(glusterd_volinfo_t *volinfo);
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd-volgen.h b/xlators/mgmt/glusterd/src/glusterd-volgen.h
index 38a62393fd6..f9fc068931b 100644
--- a/xlators/mgmt/glusterd/src/glusterd-volgen.h
+++ b/xlators/mgmt/glusterd/src/glusterd-volgen.h
@@ -20,24 +20,24 @@
/* volopt map key name definitions */
-#define VKEY_DIAG_CNT_FOP_HITS "diagnostics.count-fop-hits"
+#define VKEY_DIAG_CNT_FOP_HITS "diagnostics.count-fop-hits"
#define VKEY_DIAG_LAT_MEASUREMENT "diagnostics.latency-measurement"
#define VKEY_FEATURES_LIMIT_USAGE "features.limit-usage"
-#define VKEY_FEATURES_SOFT_LIMIT "features.soft-limit"
-#define VKEY_MARKER_XTIME GEOREP".indexing"
-#define VKEY_MARKER_XTIME_FORCE GEOREP".ignore-pid-check"
-#define VKEY_CHANGELOG "changelog.changelog"
-#define VKEY_FEATURES_QUOTA "features.quota"
+#define VKEY_FEATURES_SOFT_LIMIT "features.soft-limit"
+#define VKEY_MARKER_XTIME GEOREP ".indexing"
+#define VKEY_MARKER_XTIME_FORCE GEOREP ".ignore-pid-check"
+#define VKEY_CHANGELOG "changelog.changelog"
+#define VKEY_FEATURES_QUOTA "features.quota"
#define VKEY_FEATURES_INODE_QUOTA "features.inode-quota"
-#define VKEY_FEATURES_TRASH "features.trash"
-#define VKEY_FEATURES_BITROT "features.bitrot"
-#define VKEY_FEATURES_SCRUB "features.scrub"
-#define VKEY_FEATURES_SELINUX "features.selinux"
-#define VKEY_PARALLEL_READDIR "performance.parallel-readdir"
-#define VKEY_READDIR_AHEAD "performance.readdir-ahead"
-#define VKEY_RDA_CACHE_LIMIT "performance.rda-cache-limit"
-#define VKEY_RDA_REQUEST_SIZE "performance.rda-request-size"
-#define VKEY_CONFIG_GFPROXY "config.gfproxyd"
+#define VKEY_FEATURES_TRASH "features.trash"
+#define VKEY_FEATURES_BITROT "features.bitrot"
+#define VKEY_FEATURES_SCRUB "features.scrub"
+#define VKEY_FEATURES_SELINUX "features.selinux"
+#define VKEY_PARALLEL_READDIR "performance.parallel-readdir"
+#define VKEY_READDIR_AHEAD "performance.readdir-ahead"
+#define VKEY_RDA_CACHE_LIMIT "performance.rda-cache-limit"
+#define VKEY_RDA_REQUEST_SIZE "performance.rda-request-size"
+#define VKEY_CONFIG_GFPROXY "config.gfproxyd"
#define AUTH_ALLOW_MAP_KEY "auth.allow"
#define AUTH_REJECT_MAP_KEY "auth.reject"
@@ -46,83 +46,82 @@
#define AUTH_REJECT_OPT_KEY "auth.addr.*.reject"
#define NFS_DISABLE_OPT_KEY "nfs.*.disable"
-#define SSL_OWN_CERT_OPT "ssl.own-cert"
+#define SSL_OWN_CERT_OPT "ssl.own-cert"
#define SSL_PRIVATE_KEY_OPT "ssl.private-key"
-#define SSL_CA_LIST_OPT "ssl.ca-list"
-#define SSL_CRL_PATH_OPT "ssl.crl-path"
-#define SSL_CERT_DEPTH_OPT "ssl.certificate-depth"
+#define SSL_CA_LIST_OPT "ssl.ca-list"
+#define SSL_CRL_PATH_OPT "ssl.crl-path"
+#define SSL_CERT_DEPTH_OPT "ssl.certificate-depth"
#define SSL_CIPHER_LIST_OPT "ssl.cipher-list"
-#define SSL_DH_PARAM_OPT "ssl.dh-param"
-#define SSL_EC_CURVE_OPT "ssl.ec-curve"
-
+#define SSL_DH_PARAM_OPT "ssl.dh-param"
+#define SSL_EC_CURVE_OPT "ssl.ec-curve"
typedef enum {
- GF_CLIENT_TRUSTED,
- GF_CLIENT_OTHER,
- GF_CLIENT_TRUSTED_PROXY,
+ GF_CLIENT_TRUSTED,
+ GF_CLIENT_OTHER,
+ GF_CLIENT_TRUSTED_PROXY,
} glusterd_client_type_t;
/* It indicates the type of volfile that the graph is built for */
typedef enum {
- GF_REBALANCED = 1,
- GF_QUOTAD,
- GF_SNAPD,
+ GF_REBALANCED = 1,
+ GF_QUOTAD,
+ GF_SNAPD,
} glusterd_graph_type_t;
struct volgen_graph {
- char **errstr;
- glusterfs_graph_t graph;
- glusterd_graph_type_t type;
+ char **errstr;
+ glusterfs_graph_t graph;
+ glusterd_graph_type_t type;
};
typedef struct volgen_graph volgen_graph_t;
-typedef int (*glusterd_graph_builder_t) (volgen_graph_t *graph,
- dict_t *mod_dict);
-
-#define COMPLETE_OPTION(key, completion, ret) \
- do { \
- if (!strchr (key, '.')) { \
- ret = option_complete (key, &completion); \
- if (ret) { \
- gf_msg ("", GF_LOG_ERROR, ENOMEM, \
- GD_MSG_NO_MEMORY, "Out of memory"); \
- return _gf_false; \
- } \
- \
- if (!completion) { \
- gf_msg ("", GF_LOG_ERROR, 0, \
- GD_MSG_INVALID_ENTRY, \
- "option %s does not" \
- "exist", key); \
- return _gf_false; \
- } \
- } \
- \
- if (completion) \
- GF_FREE (completion); \
- } while (0);
+typedef int (*glusterd_graph_builder_t)(volgen_graph_t *graph,
+ dict_t *mod_dict);
+
+#define COMPLETE_OPTION(key, completion, ret) \
+ do { \
+ if (!strchr(key, '.')) { \
+ ret = option_complete(key, &completion); \
+ if (ret) { \
+ gf_msg("", GF_LOG_ERROR, ENOMEM, GD_MSG_NO_MEMORY, \
+ "Out of memory"); \
+ return _gf_false; \
+ } \
+ \
+ if (!completion) { \
+ gf_msg("", GF_LOG_ERROR, 0, GD_MSG_INVALID_ENTRY, \
+ "option %s does not" \
+ "exist", \
+ key); \
+ return _gf_false; \
+ } \
+ } \
+ \
+ if (completion) \
+ GF_FREE(completion); \
+ } while (0);
typedef enum gd_volopt_flags_ {
- VOLOPT_FLAG_NONE,
- VOLOPT_FLAG_FORCE = 0x01, /* option needs force to be reset */
- VOLOPT_FLAG_XLATOR_OPT = 0x02, /* option enables/disables xlators */
- VOLOPT_FLAG_CLIENT_OPT = 0x04, /* option affects clients */
- VOLOPT_FLAG_NEVER_RESET = 0x08, /* option which should not be reset */
+ VOLOPT_FLAG_NONE,
+ VOLOPT_FLAG_FORCE = 0x01, /* option needs force to be reset */
+ VOLOPT_FLAG_XLATOR_OPT = 0x02, /* option enables/disables xlators */
+ VOLOPT_FLAG_CLIENT_OPT = 0x04, /* option affects clients */
+ VOLOPT_FLAG_NEVER_RESET = 0x08, /* option which should not be reset */
} gd_volopt_flags_t;
typedef enum {
- GF_XLATOR_POSIX = 0,
- GF_XLATOR_ACL,
- GF_XLATOR_LOCKS,
- GF_XLATOR_LEASES,
- GF_XLATOR_UPCALL,
- GF_XLATOR_IOT,
- GF_XLATOR_INDEX,
- GF_XLATOR_MARKER,
- GF_XLATOR_IO_STATS,
- GF_XLATOR_BD,
- GF_XLATOR_SERVER,
- GF_XLATOR_NONE,
+ GF_XLATOR_POSIX = 0,
+ GF_XLATOR_ACL,
+ GF_XLATOR_LOCKS,
+ GF_XLATOR_LEASES,
+ GF_XLATOR_UPCALL,
+ GF_XLATOR_IOT,
+ GF_XLATOR_INDEX,
+ GF_XLATOR_MARKER,
+ GF_XLATOR_IO_STATS,
+ GF_XLATOR_BD,
+ GF_XLATOR_SERVER,
+ GF_XLATOR_NONE,
} glusterd_server_xlator_t;
/* As of now debug xlators can be loaded only below fuse in the client
@@ -131,189 +130,187 @@ typedef enum {
* available.
*/
typedef enum {
- GF_CLNT_XLATOR_FUSE = 0,
- GF_CLNT_XLATOR_NONE,
+ GF_CLNT_XLATOR_FUSE = 0,
+ GF_CLNT_XLATOR_NONE,
} glusterd_client_xlator_t;
-typedef enum { DOC, NO_DOC, GLOBAL_DOC, GLOBAL_NO_DOC } option_type_t;
+typedef enum { DOC, NO_DOC, GLOBAL_DOC, GLOBAL_NO_DOC } option_type_t;
-typedef int (*vme_option_validation) (glusterd_volinfo_t *volinfo, dict_t *dict,
- char *key, char *value, char **op_errstr);
+typedef int (*vme_option_validation)(glusterd_volinfo_t *volinfo, dict_t *dict,
+ char *key, char *value, char **op_errstr);
struct volopt_map_entry {
- char *key;
- char *voltype;
- char *option;
- char *value;
- option_type_t type;
- uint32_t flags;
- uint32_t op_version;
- char *description;
- vme_option_validation validate_fn;
- /* If client_option is true, the option affects clients.
- * this is used to calculate client-op-version of volumes
- */
- //gf_boolean_t client_option;
+ char *key;
+ char *voltype;
+ char *option;
+ char *value;
+ option_type_t type;
+ uint32_t flags;
+ uint32_t op_version;
+ char *description;
+ vme_option_validation validate_fn;
+ /* If client_option is true, the option affects clients.
+ * this is used to calculate client-op-version of volumes
+ */
+ // gf_boolean_t client_option;
};
-typedef
-int (*brick_xlator_builder) (volgen_graph_t *graph,
- glusterd_volinfo_t *volinfo, dict_t *set_dict,
- glusterd_brickinfo_t *brickinfo);
+typedef int (*brick_xlator_builder)(volgen_graph_t *graph,
+ glusterd_volinfo_t *volinfo,
+ dict_t *set_dict,
+ glusterd_brickinfo_t *brickinfo);
struct volgen_brick_xlator {
- /* function that builds a xlator */
- brick_xlator_builder builder;
- /* debug key for a xlator that
- * gets used for adding debug translators like trace, error-gen,
- * delay-gen before this xlator */
- char *dbg_key;
+ /* function that builds a xlator */
+ brick_xlator_builder builder;
+ /* debug key for a xlator that
+ * gets used for adding debug translators like trace, error-gen,
+ * delay-gen before this xlator */
+ char *dbg_key;
};
typedef struct volgen_brick_xlator volgen_brick_xlator_t;
int
-glusterd_snapdsvc_create_volfile (glusterd_volinfo_t *volinfo);
+glusterd_snapdsvc_create_volfile(glusterd_volinfo_t *volinfo);
int
-glusterd_snapdsvc_generate_volfile (volgen_graph_t *graph,
- glusterd_volinfo_t *volinfo);
+glusterd_snapdsvc_generate_volfile(volgen_graph_t *graph,
+ glusterd_volinfo_t *volinfo);
int
-glusterd_create_global_volfile (glusterd_graph_builder_t builder,
- char *filepath, dict_t *mod_dict);
+glusterd_create_global_volfile(glusterd_graph_builder_t builder, char *filepath,
+ dict_t *mod_dict);
int
-glusterd_create_rb_volfiles (glusterd_volinfo_t *volinfo,
- glusterd_brickinfo_t *brickinfo);
+glusterd_create_rb_volfiles(glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t *brickinfo);
int
-glusterd_create_volfiles (glusterd_volinfo_t *volinfo);
+glusterd_create_volfiles(glusterd_volinfo_t *volinfo);
int
-glusterd_create_volfiles_and_notify_services (glusterd_volinfo_t *volinfo);
+glusterd_create_volfiles_and_notify_services(glusterd_volinfo_t *volinfo);
int
-glusterd_generate_client_per_brick_volfile (glusterd_volinfo_t *volinfo);
+glusterd_generate_client_per_brick_volfile(glusterd_volinfo_t *volinfo);
void
-glusterd_get_nfs_filepath (char *filename);
+glusterd_get_nfs_filepath(char *filename);
void
-glusterd_get_shd_filepath (char *filename);
+glusterd_get_shd_filepath(char *filename);
int
-build_shd_graph (volgen_graph_t *graph, dict_t *mod_dict);
+build_shd_graph(volgen_graph_t *graph, dict_t *mod_dict);
int
-build_nfs_graph (volgen_graph_t *graph, dict_t *mod_dict);
+build_nfs_graph(volgen_graph_t *graph, dict_t *mod_dict);
int
-build_quotad_graph (volgen_graph_t *graph, dict_t *mod_dict);
+build_quotad_graph(volgen_graph_t *graph, dict_t *mod_dict);
int
-build_rebalance_volfile (glusterd_volinfo_t *volinfo, char *filepath,
- dict_t *mod_dict);
+build_rebalance_volfile(glusterd_volinfo_t *volinfo, char *filepath,
+ dict_t *mod_dict);
int
-build_bitd_graph (volgen_graph_t *graph, dict_t *mod_dict);
+build_bitd_graph(volgen_graph_t *graph, dict_t *mod_dict);
int
-build_scrub_graph (volgen_graph_t *graph, dict_t *mod_dict);
+build_scrub_graph(volgen_graph_t *graph, dict_t *mod_dict);
int
-glusterd_delete_volfile (glusterd_volinfo_t *volinfo,
- glusterd_brickinfo_t *brickinfo);
+glusterd_delete_volfile(glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t *brickinfo);
int
-glusterd_delete_snap_volfile (glusterd_volinfo_t *volinfo,
- glusterd_volinfo_t *snap_volinfo,
- glusterd_brickinfo_t *brickinfo);
+glusterd_delete_snap_volfile(glusterd_volinfo_t *volinfo,
+ glusterd_volinfo_t *snap_volinfo,
+ glusterd_brickinfo_t *brickinfo);
int
-glusterd_volinfo_get (glusterd_volinfo_t *volinfo, char *key, char **value);
+glusterd_volinfo_get(glusterd_volinfo_t *volinfo, char *key, char **value);
int
-glusterd_volinfo_get_boolean (glusterd_volinfo_t *volinfo, char *key);
+glusterd_volinfo_get_boolean(glusterd_volinfo_t *volinfo, char *key);
int
-glusterd_validate_globalopts (glusterd_volinfo_t *volinfo, dict_t *val_dict,
- char **op_errstr);
+glusterd_validate_globalopts(glusterd_volinfo_t *volinfo, dict_t *val_dict,
+ char **op_errstr);
int
-glusterd_validate_localopts (dict_t *val_dict, char **op_errstr);
+glusterd_validate_localopts(dict_t *val_dict, char **op_errstr);
gf_boolean_t
-glusterd_check_globaloption (char *key);
+glusterd_check_globaloption(char *key);
gf_boolean_t
-glusterd_check_voloption_flags (char *key, int32_t flags);
+glusterd_check_voloption_flags(char *key, int32_t flags);
gf_boolean_t
-glusterd_is_valid_volfpath (char *volname, char *brick);
+glusterd_is_valid_volfpath(char *volname, char *brick);
int
-generate_brick_volfiles (glusterd_volinfo_t *volinfo);
+generate_brick_volfiles(glusterd_volinfo_t *volinfo);
int
-generate_snap_brick_volfiles (glusterd_volinfo_t *volinfo,
- glusterd_volinfo_t *snap_volinfo);
+generate_snap_brick_volfiles(glusterd_volinfo_t *volinfo,
+ glusterd_volinfo_t *snap_volinfo);
int
-generate_client_volfiles (glusterd_volinfo_t *volinfo,
- glusterd_client_type_t client_type);
+generate_client_volfiles(glusterd_volinfo_t *volinfo,
+ glusterd_client_type_t client_type);
int
-generate_snap_client_volfiles (glusterd_volinfo_t *actual_volinfo,
- glusterd_volinfo_t *snap_volinfo,
- glusterd_client_type_t client_type,
- gf_boolean_t vol_restore);
+generate_snap_client_volfiles(glusterd_volinfo_t *actual_volinfo,
+ glusterd_volinfo_t *snap_volinfo,
+ glusterd_client_type_t client_type,
+ gf_boolean_t vol_restore);
int
-_get_xlator_opt_key_from_vme ( struct volopt_map_entry *vme, char **key);
+_get_xlator_opt_key_from_vme(struct volopt_map_entry *vme, char **key);
void
-_free_xlator_opt_key (char *key);
-
+_free_xlator_opt_key(char *key);
#if (HAVE_LIB_XML)
int
-init_sethelp_xml_doc (xmlTextWriterPtr *writer, xmlBufferPtr *buf);
+init_sethelp_xml_doc(xmlTextWriterPtr *writer, xmlBufferPtr *buf);
int
-xml_add_volset_element (xmlTextWriterPtr writer, const char *name,
- const char *def_val, const char *dscrpt);
+xml_add_volset_element(xmlTextWriterPtr writer, const char *name,
+ const char *def_val, const char *dscrpt);
int
-end_sethelp_xml_doc (xmlTextWriterPtr writer);
+end_sethelp_xml_doc(xmlTextWriterPtr writer);
#endif /* HAVE_LIB_XML */
-char*
-glusterd_get_trans_type_rb (gf_transport_type ttype);
+char *
+glusterd_get_trans_type_rb(gf_transport_type ttype);
uint32_t
-glusterd_get_op_version_for_key (char *key);
+glusterd_get_op_version_for_key(char *key);
gf_boolean_t
-gd_is_client_option (char *key);
+gd_is_client_option(char *key);
gf_boolean_t
-gd_is_xlator_option (char *key);
+gd_is_xlator_option(char *key);
gf_boolean_t
-gd_is_boolean_option (char *key);
-
+gd_is_boolean_option(char *key);
-char*
-volgen_get_shd_key (int type);
+char *
+volgen_get_shd_key(int type);
int
-glusterd_volopt_validate (glusterd_volinfo_t *volinfo, dict_t *dict, char *key,
- char *value, char **op_errstr);
+glusterd_volopt_validate(glusterd_volinfo_t *volinfo, dict_t *dict, char *key,
+ char *value, char **op_errstr);
gf_boolean_t
-gd_is_self_heal_enabled (glusterd_volinfo_t *volinfo, dict_t *dict);
+gd_is_self_heal_enabled(glusterd_volinfo_t *volinfo, dict_t *dict);
int
-generate_dummy_client_volfiles (glusterd_volinfo_t *volinfo);
+generate_dummy_client_volfiles(glusterd_volinfo_t *volinfo);
int
-glusterd_generate_gfproxyd_volfile (glusterd_volinfo_t *volinfo);
+glusterd_generate_gfproxyd_volfile(glusterd_volinfo_t *volinfo);
int
-glusterd_build_gfproxyd_volfile (glusterd_volinfo_t *volinfo, char *filename);
+glusterd_build_gfproxyd_volfile(glusterd_volinfo_t *volinfo, char *filename);
#endif
diff --git a/xlators/mgmt/glusterd/src/glusterd.h b/xlators/mgmt/glusterd/src/glusterd.h
index 71ac45cd241..19cdee392f6 100644
--- a/xlators/mgmt/glusterd/src/glusterd.h
+++ b/xlators/mgmt/glusterd/src/glusterd.h
@@ -39,45 +39,50 @@
#include "events.h"
#include "glusterd-gfproxyd-svc.h"
-#define GLUSTERD_TR_LOG_SIZE 50
-#define GLUSTERD_QUORUM_TYPE_KEY "cluster.server-quorum-type"
-#define GLUSTERD_QUORUM_RATIO_KEY "cluster.server-quorum-ratio"
-#define GLUSTERD_GLOBAL_OPT_VERSION "global-option-version"
-#define GLUSTERD_GLOBAL_OP_VERSION_KEY "cluster.op-version"
-#define GLUSTERD_MAX_OP_VERSION_KEY "cluster.max-op-version"
-#define GLUSTERD_COMMON_PEM_PUB_FILE "/geo-replication/common_secret.pem.pub"
-#define GEO_CONF_MAX_OPT_VALS 6
-#define GLUSTERD_CREATE_HOOK_SCRIPT "/hooks/1/gsync-create/post/" \
- "S56glusterd-geo-rep-create-post.sh"
-#define GLUSTERD_SHRD_STRG_HOOK_SCRIPT "/hooks/1/set/post/" \
- "S32gluster_enable_shared_storage.sh"
-#define GLUSTER_SHARED_STORAGE "gluster_shared_storage"
-#define GLUSTERD_SHARED_STORAGE_KEY "cluster.enable-shared-storage"
-#define GLUSTERD_BRICK_MULTIPLEX_KEY "cluster.brick-multiplex"
-#define GLUSTERD_BRICKMUX_LIMIT_KEY "cluster.max-bricks-per-process"
-#define GLUSTERD_LOCALTIME_LOGGING_KEY "cluster.localtime-logging"
-#define GLUSTERD_DAEMON_LOG_LEVEL_KEY "cluster.daemon-log-level"
+#define GLUSTERD_TR_LOG_SIZE 50
+#define GLUSTERD_QUORUM_TYPE_KEY "cluster.server-quorum-type"
+#define GLUSTERD_QUORUM_RATIO_KEY "cluster.server-quorum-ratio"
+#define GLUSTERD_GLOBAL_OPT_VERSION "global-option-version"
+#define GLUSTERD_GLOBAL_OP_VERSION_KEY "cluster.op-version"
+#define GLUSTERD_MAX_OP_VERSION_KEY "cluster.max-op-version"
+#define GLUSTERD_COMMON_PEM_PUB_FILE "/geo-replication/common_secret.pem.pub"
+#define GEO_CONF_MAX_OPT_VALS 6
+#define GLUSTERD_CREATE_HOOK_SCRIPT \
+ "/hooks/1/gsync-create/post/" \
+ "S56glusterd-geo-rep-create-post.sh"
+#define GLUSTERD_SHRD_STRG_HOOK_SCRIPT \
+ "/hooks/1/set/post/" \
+ "S32gluster_enable_shared_storage.sh"
+#define GLUSTER_SHARED_STORAGE "gluster_shared_storage"
+#define GLUSTERD_SHARED_STORAGE_KEY "cluster.enable-shared-storage"
+#define GLUSTERD_BRICK_MULTIPLEX_KEY "cluster.brick-multiplex"
+#define GLUSTERD_BRICKMUX_LIMIT_KEY "cluster.max-bricks-per-process"
+#define GLUSTERD_LOCALTIME_LOGGING_KEY "cluster.localtime-logging"
+#define GLUSTERD_DAEMON_LOG_LEVEL_KEY "cluster.daemon-log-level"
#define GLUSTERD_SNAPS_MAX_HARD_LIMIT 256
#define GLUSTERD_SNAPS_DEF_SOFT_LIMIT_PERCENT 90
#define GLUSTERD_SNAPS_MAX_SOFT_LIMIT_PERCENT 100
#define GLUSTERD_SERVER_QUORUM "server"
-#define STATUS_STRLEN 128
+#define STATUS_STRLEN 128
#define FMTSTR_CHECK_VOL_EXISTS "Volume %s does not exist"
#define FMTSTR_RESOLVE_BRICK "Could not find peer on which brick %s:%s resides"
-#define LOGSTR_FOUND_BRICK "Found brick %s:%s in volume %s"
+#define LOGSTR_FOUND_BRICK "Found brick %s:%s in volume %s"
#define LOGSTR_BUILD_PAYLOAD "Failed to build payload for operation 'Volume %s'"
#define LOGSTR_STAGE_FAIL "Staging of operation 'Volume %s' failed on %s %s %s"
#define LOGSTR_COMMIT_FAIL "Commit of operation 'Volume %s' failed on %s %s %s"
-#define OPERRSTR_BUILD_PAYLOAD "Failed to build payload. Please check the log "\
- "file for more details."
-#define OPERRSTR_STAGE_FAIL "Staging failed on %s. Please check the log file " \
- "for more details."
-#define OPERRSTR_COMMIT_FAIL "Commit failed on %s. Please check the log file "\
- "for more details."
+#define OPERRSTR_BUILD_PAYLOAD \
+ "Failed to build payload. Please check the log " \
+ "file for more details."
+#define OPERRSTR_STAGE_FAIL \
+ "Staging failed on %s. Please check the log file " \
+ "for more details."
+#define OPERRSTR_COMMIT_FAIL \
+ "Commit failed on %s. Please check the log file " \
+ "for more details."
struct glusterd_volinfo_;
typedef struct glusterd_volinfo_ glusterd_volinfo_t;
@@ -88,57 +93,57 @@ typedef struct glusterd_snap_ glusterd_snap_t;
* at the end of latest enum (just before the GD_OP_MAX enum)
*/
typedef enum glusterd_op_ {
- GD_OP_NONE = 0,
- GD_OP_CREATE_VOLUME,
- GD_OP_START_BRICK,
- GD_OP_STOP_BRICK,
- GD_OP_DELETE_VOLUME,
- GD_OP_START_VOLUME,
- GD_OP_STOP_VOLUME,
- GD_OP_DEFRAG_VOLUME,
- GD_OP_ADD_BRICK,
- GD_OP_REMOVE_BRICK,
- GD_OP_REPLACE_BRICK,
- GD_OP_SET_VOLUME,
- GD_OP_RESET_VOLUME,
- GD_OP_SYNC_VOLUME,
- GD_OP_LOG_ROTATE,
- GD_OP_GSYNC_SET,
- GD_OP_PROFILE_VOLUME,
- GD_OP_QUOTA,
- GD_OP_STATUS_VOLUME,
- GD_OP_REBALANCE,
- GD_OP_HEAL_VOLUME,
- GD_OP_STATEDUMP_VOLUME,
- GD_OP_LIST_VOLUME,
- GD_OP_CLEARLOCKS_VOLUME,
- GD_OP_DEFRAG_BRICK_VOLUME,
- GD_OP_COPY_FILE,
- GD_OP_SYS_EXEC,
- GD_OP_GSYNC_CREATE,
- GD_OP_SNAP,
- GD_OP_BARRIER,
- GD_OP_GANESHA, /* obsolete */
- GD_OP_BITROT,
- GD_OP_DETACH_TIER,
- GD_OP_TIER_MIGRATE,
- GD_OP_SCRUB_STATUS,
- GD_OP_SCRUB_ONDEMAND,
- GD_OP_RESET_BRICK,
- GD_OP_MAX_OPVERSION,
- GD_OP_TIER_START_STOP,
- GD_OP_TIER_STATUS,
- GD_OP_DETACH_TIER_STATUS,
- GD_OP_DETACH_NOT_STARTED,
- GD_OP_REMOVE_TIER_BRICK,
- GD_OP_ADD_TIER_BRICK,
- GD_OP_MAX,
+ GD_OP_NONE = 0,
+ GD_OP_CREATE_VOLUME,
+ GD_OP_START_BRICK,
+ GD_OP_STOP_BRICK,
+ GD_OP_DELETE_VOLUME,
+ GD_OP_START_VOLUME,
+ GD_OP_STOP_VOLUME,
+ GD_OP_DEFRAG_VOLUME,
+ GD_OP_ADD_BRICK,
+ GD_OP_REMOVE_BRICK,
+ GD_OP_REPLACE_BRICK,
+ GD_OP_SET_VOLUME,
+ GD_OP_RESET_VOLUME,
+ GD_OP_SYNC_VOLUME,
+ GD_OP_LOG_ROTATE,
+ GD_OP_GSYNC_SET,
+ GD_OP_PROFILE_VOLUME,
+ GD_OP_QUOTA,
+ GD_OP_STATUS_VOLUME,
+ GD_OP_REBALANCE,
+ GD_OP_HEAL_VOLUME,
+ GD_OP_STATEDUMP_VOLUME,
+ GD_OP_LIST_VOLUME,
+ GD_OP_CLEARLOCKS_VOLUME,
+ GD_OP_DEFRAG_BRICK_VOLUME,
+ GD_OP_COPY_FILE,
+ GD_OP_SYS_EXEC,
+ GD_OP_GSYNC_CREATE,
+ GD_OP_SNAP,
+ GD_OP_BARRIER,
+ GD_OP_GANESHA, /* obsolete */
+ GD_OP_BITROT,
+ GD_OP_DETACH_TIER,
+ GD_OP_TIER_MIGRATE,
+ GD_OP_SCRUB_STATUS,
+ GD_OP_SCRUB_ONDEMAND,
+ GD_OP_RESET_BRICK,
+ GD_OP_MAX_OPVERSION,
+ GD_OP_TIER_START_STOP,
+ GD_OP_TIER_STATUS,
+ GD_OP_DETACH_TIER_STATUS,
+ GD_OP_DETACH_NOT_STARTED,
+ GD_OP_REMOVE_TIER_BRICK,
+ GD_OP_ADD_TIER_BRICK,
+ GD_OP_MAX,
} glusterd_op_t;
-extern const char * gd_op_list[];
+extern const char *gd_op_list[];
struct glusterd_volgen {
- dict_t *dict;
+ dict_t *dict;
};
/* Keeping all the paths required in glusterd would
@@ -152,446 +157,443 @@ struct glusterd_volgen {
#define VALID_GLUSTERD_PATHMAX (PATH_MAX - (256 + 64))
typedef struct {
- struct _volfile_ctx *volfile;
- pthread_mutex_t mutex;
- struct cds_list_head peers;
- gf_boolean_t verify_volfile_checksum;
- gf_boolean_t trace;
- uuid_t uuid;
- char workdir[VALID_GLUSTERD_PATHMAX];
- char rundir[VALID_GLUSTERD_PATHMAX];
- rpcsvc_t *rpc;
- glusterd_svc_t shd_svc;
- glusterd_svc_t nfs_svc;
- glusterd_svc_t bitd_svc;
- glusterd_svc_t scrub_svc;
- glusterd_svc_t quotad_svc;
- struct pmap_registry *pmap;
- struct cds_list_head volumes;
- struct cds_list_head snapshots; /*List of snap volumes */
- struct cds_list_head brick_procs; /* List of brick processes */
- pthread_mutex_t xprt_lock;
- struct list_head xprt_list;
- pthread_mutex_t import_volumes;
- gf_store_handle_t *handle;
- gf_timer_t *timer;
- glusterd_sm_tr_log_t op_sm_log;
- struct rpc_clnt_program *gfs_mgmt;
- dict_t *mgmt_v3_lock; /* Dict for saving
- * mgmt_v3 locks */
- dict_t *glusterd_txn_opinfo; /* Dict for saving
- * transaction opinfos */
- uuid_t global_txn_id; /* To be used in
- * heterogeneous
- * cluster with no
- * transaction ids */
-
- dict_t *mgmt_v3_lock_timer;
- struct cds_list_head mount_specs;
- pthread_t brick_thread;
- void *hooks_priv;
-
- /* need for proper handshake_t */
- int op_version; /* Starts with 1 for 3.3.0 */
- xlator_t *xl; /* Should be set to 'THIS' before creating thread */
- gf_boolean_t pending_quorum_action;
- dict_t *opts;
- synclock_t big_lock;
- gf_boolean_t restart_done;
- rpcsvc_t *uds_rpc; /* RPCSVC for the unix domain socket */
- uint32_t base_port;
- uint32_t max_port;
- char *snap_bricks_directory;
- gf_store_handle_t *missed_snaps_list_shandle;
- struct cds_list_head missed_snaps_list;
- int ping_timeout;
- uint32_t generation;
- int32_t workers;
- uint32_t blockers;
- uint32_t mgmt_v3_lock_timeout;
- gf_boolean_t restart_bricks;
+ struct _volfile_ctx *volfile;
+ pthread_mutex_t mutex;
+ struct cds_list_head peers;
+ gf_boolean_t verify_volfile_checksum;
+ gf_boolean_t trace;
+ uuid_t uuid;
+ char workdir[VALID_GLUSTERD_PATHMAX];
+ char rundir[VALID_GLUSTERD_PATHMAX];
+ rpcsvc_t *rpc;
+ glusterd_svc_t shd_svc;
+ glusterd_svc_t nfs_svc;
+ glusterd_svc_t bitd_svc;
+ glusterd_svc_t scrub_svc;
+ glusterd_svc_t quotad_svc;
+ struct pmap_registry *pmap;
+ struct cds_list_head volumes;
+ struct cds_list_head snapshots; /*List of snap volumes */
+ struct cds_list_head brick_procs; /* List of brick processes */
+ pthread_mutex_t xprt_lock;
+ struct list_head xprt_list;
+ pthread_mutex_t import_volumes;
+ gf_store_handle_t *handle;
+ gf_timer_t *timer;
+ glusterd_sm_tr_log_t op_sm_log;
+ struct rpc_clnt_program *gfs_mgmt;
+ dict_t *mgmt_v3_lock; /* Dict for saving
+ * mgmt_v3 locks */
+ dict_t *glusterd_txn_opinfo; /* Dict for saving
+ * transaction opinfos */
+ uuid_t global_txn_id; /* To be used in
+ * heterogeneous
+ * cluster with no
+ * transaction ids */
+
+ dict_t *mgmt_v3_lock_timer;
+ struct cds_list_head mount_specs;
+ pthread_t brick_thread;
+ void *hooks_priv;
+
+ /* need for proper handshake_t */
+ int op_version; /* Starts with 1 for 3.3.0 */
+ xlator_t *xl; /* Should be set to 'THIS' before creating thread */
+ gf_boolean_t pending_quorum_action;
+ dict_t *opts;
+ synclock_t big_lock;
+ gf_boolean_t restart_done;
+ rpcsvc_t *uds_rpc; /* RPCSVC for the unix domain socket */
+ uint32_t base_port;
+ uint32_t max_port;
+ char *snap_bricks_directory;
+ gf_store_handle_t *missed_snaps_list_shandle;
+ struct cds_list_head missed_snaps_list;
+ int ping_timeout;
+ uint32_t generation;
+ int32_t workers;
+ uint32_t blockers;
+ uint32_t mgmt_v3_lock_timeout;
+ gf_boolean_t restart_bricks;
} glusterd_conf_t;
-
typedef enum gf_brick_status {
- GF_BRICK_STOPPED,
- GF_BRICK_STARTED,
- GF_BRICK_STOPPING,
- GF_BRICK_STARTING
+ GF_BRICK_STOPPED,
+ GF_BRICK_STARTED,
+ GF_BRICK_STOPPING,
+ GF_BRICK_STARTING
} gf_brick_status_t;
struct glusterd_brickinfo {
- char hostname[NAME_MAX];
- char path[VALID_GLUSTERD_PATHMAX];
- char real_path[VALID_GLUSTERD_PATHMAX];
- char device_path[VALID_GLUSTERD_PATHMAX];
- char mount_dir[VALID_GLUSTERD_PATHMAX];
- char brick_id[1024];/*Client xlator name, AFR changelog name*/
- char fstype [NAME_MAX]; /* Brick file-system type */
- char mnt_opts [1024]; /* Brick mount options */
- struct cds_list_head brick_list;
- uuid_t uuid;
- int port;
- int rdma_port;
- char *logfile;
- gf_store_handle_t *shandle;
- gf_brick_status_t status;
- struct rpc_clnt *rpc;
- int decommissioned;
- char vg[PATH_MAX]; /* FIXME: Use max size for length of vg */
- int caps; /* Capability */
- int32_t snap_status;
- /*
- * The group is used to identify which bricks are part of the same
- * replica set during brick-volfile generation, so that JBR volfiles
- * can "cross-connect" the bricks to one another. It is also used by
- * AFR to load the arbiter xlator in the appropriate brick in case of
- * a replica 3 volume with arbiter enabled.
- */
- uint16_t group;
- uuid_t jbr_uuid;
-
- /* Below are used for handling the case of multiple bricks sharing
- the backend filesystem */
- uint64_t statfs_fsid;
- uint32_t fs_share_count;
- gf_boolean_t port_registered;
- gf_boolean_t start_triggered;
- pthread_mutex_t restart_mutex;
+ char hostname[NAME_MAX];
+ char path[VALID_GLUSTERD_PATHMAX];
+ char real_path[VALID_GLUSTERD_PATHMAX];
+ char device_path[VALID_GLUSTERD_PATHMAX];
+ char mount_dir[VALID_GLUSTERD_PATHMAX];
+ char brick_id[1024]; /*Client xlator name, AFR changelog name*/
+ char fstype[NAME_MAX]; /* Brick file-system type */
+ char mnt_opts[1024]; /* Brick mount options */
+ struct cds_list_head brick_list;
+ uuid_t uuid;
+ int port;
+ int rdma_port;
+ char *logfile;
+ gf_store_handle_t *shandle;
+ gf_brick_status_t status;
+ struct rpc_clnt *rpc;
+ int decommissioned;
+ char vg[PATH_MAX]; /* FIXME: Use max size for length of vg */
+ int caps; /* Capability */
+ int32_t snap_status;
+ /*
+ * The group is used to identify which bricks are part of the same
+ * replica set during brick-volfile generation, so that JBR volfiles
+ * can "cross-connect" the bricks to one another. It is also used by
+ * AFR to load the arbiter xlator in the appropriate brick in case of
+ * a replica 3 volume with arbiter enabled.
+ */
+ uint16_t group;
+ uuid_t jbr_uuid;
+
+ /* Below are used for handling the case of multiple bricks sharing
+ the backend filesystem */
+ uint64_t statfs_fsid;
+ uint32_t fs_share_count;
+ gf_boolean_t port_registered;
+ gf_boolean_t start_triggered;
+ pthread_mutex_t restart_mutex;
};
typedef struct glusterd_brickinfo glusterd_brickinfo_t;
struct glusterd_brick_proc {
- int port;
- uint32_t brick_count;
- struct cds_list_head brick_proc_list;
- struct cds_list_head bricks;
+ int port;
+ uint32_t brick_count;
+ struct cds_list_head brick_proc_list;
+ struct cds_list_head bricks;
};
typedef struct glusterd_brick_proc glusterd_brick_proc_t;
struct glusterd_gfproxyd_info {
- short port;
- char *logfile;
+ short port;
+ char *logfile;
};
struct gf_defrag_brickinfo_ {
- char *name;
- int files;
- int size;
+ char *name;
+ int files;
+ int size;
};
-typedef int (*defrag_cbk_fn_t) (glusterd_volinfo_t *volinfo,
- gf_defrag_status_t status);
+typedef int (*defrag_cbk_fn_t)(glusterd_volinfo_t *volinfo,
+ gf_defrag_status_t status);
struct glusterd_defrag_info_ {
- uint64_t total_files;
- uint64_t total_data;
- uint64_t num_files_lookedup;
- uint64_t total_failures;
- gf_lock_t lock;
- int cmd;
- pthread_t th;
- gf_defrag_status_t defrag_status;
- struct rpc_clnt *rpc;
- uint32_t connected;
- char mount[1024];
- struct gf_defrag_brickinfo_ *bricks; /* volinfo->brick_count */
-
- defrag_cbk_fn_t cbk_fn;
+ uint64_t total_files;
+ uint64_t total_data;
+ uint64_t num_files_lookedup;
+ uint64_t total_failures;
+ gf_lock_t lock;
+ int cmd;
+ pthread_t th;
+ gf_defrag_status_t defrag_status;
+ struct rpc_clnt *rpc;
+ uint32_t connected;
+ char mount[1024];
+ struct gf_defrag_brickinfo_ *bricks; /* volinfo->brick_count */
+
+ defrag_cbk_fn_t cbk_fn;
};
-
typedef struct glusterd_defrag_info_ glusterd_defrag_info_t;
typedef enum gf_transport_type_ {
- GF_TRANSPORT_TCP, //DEFAULT
- GF_TRANSPORT_RDMA,
- GF_TRANSPORT_BOTH_TCP_RDMA,
+ GF_TRANSPORT_TCP, // DEFAULT
+ GF_TRANSPORT_RDMA,
+ GF_TRANSPORT_BOTH_TCP_RDMA,
} gf_transport_type;
-
typedef enum gf_rb_status_ {
- GF_RB_STATUS_NONE,
- GF_RB_STATUS_STARTED,
- GF_RB_STATUS_PAUSED,
+ GF_RB_STATUS_NONE,
+ GF_RB_STATUS_STARTED,
+ GF_RB_STATUS_PAUSED,
} gf_rb_status_t;
struct _auth {
- char *username;
- char *password;
+ char *username;
+ char *password;
};
typedef struct _auth auth_t;
/* Capabilities of xlator */
-#define CAPS_BD 0x00000001
-#define CAPS_THIN 0x00000002
-#define CAPS_OFFLOAD_COPY 0x00000004
+#define CAPS_BD 0x00000001
+#define CAPS_THIN 0x00000002
+#define CAPS_OFFLOAD_COPY 0x00000004
#define CAPS_OFFLOAD_SNAPSHOT 0x00000008
-#define CAPS_OFFLOAD_ZERO 0x00000020
+#define CAPS_OFFLOAD_ZERO 0x00000020
struct glusterd_bitrot_scrub_ {
- char *scrub_state;
- char *scrub_impact;
- char *scrub_freq;
- uint64_t scrubbed_files;
- uint64_t unsigned_files;
- uint64_t last_scrub_time;
- uint64_t scrub_duration;
- uint64_t error_count;
+ char *scrub_state;
+ char *scrub_impact;
+ char *scrub_freq;
+ uint64_t scrubbed_files;
+ uint64_t unsigned_files;
+ uint64_t last_scrub_time;
+ uint64_t scrub_duration;
+ uint64_t error_count;
};
typedef struct glusterd_bitrot_scrub_ glusterd_bitrot_scrub_t;
struct glusterd_rebalance_ {
- gf_defrag_status_t defrag_status;
- uint64_t rebalance_files;
- uint64_t rebalance_data;
- uint64_t lookedup_files;
- uint64_t skipped_files;
- glusterd_defrag_info_t *defrag;
- gf_cli_defrag_type defrag_cmd;
- uint64_t rebalance_failures;
- uuid_t rebalance_id;
- double rebalance_time;
- uint64_t time_left;
- glusterd_op_t op;
- dict_t *dict; /* Dict to store misc information
- * like list of bricks being removed */
- uint32_t commit_hash;
+ gf_defrag_status_t defrag_status;
+ uint64_t rebalance_files;
+ uint64_t rebalance_data;
+ uint64_t lookedup_files;
+ uint64_t skipped_files;
+ glusterd_defrag_info_t *defrag;
+ gf_cli_defrag_type defrag_cmd;
+ uint64_t rebalance_failures;
+ uuid_t rebalance_id;
+ double rebalance_time;
+ uint64_t time_left;
+ glusterd_op_t op;
+ dict_t *dict; /* Dict to store misc information
+ * like list of bricks being removed */
+ uint32_t commit_hash;
};
typedef struct glusterd_rebalance_ glusterd_rebalance_t;
struct glusterd_replace_brick_ {
- glusterd_brickinfo_t *src_brick;
- glusterd_brickinfo_t *dst_brick;
+ glusterd_brickinfo_t *src_brick;
+ glusterd_brickinfo_t *dst_brick;
};
typedef struct glusterd_replace_brick_ glusterd_replace_brick_t;
typedef enum gd_quorum_status_ {
- NOT_APPLICABLE_QUORUM, //Does not follow quorum
- MEETS_QUORUM, //Follows quorum and meets.
- DOESNT_MEET_QUORUM, //Follows quorum and does not meet.
+ NOT_APPLICABLE_QUORUM, // Does not follow quorum
+ MEETS_QUORUM, // Follows quorum and meets.
+ DOESNT_MEET_QUORUM, // Follows quorum and does not meet.
} gd_quorum_status_t;
typedef struct tier_info_ {
- int cold_type;
- int cold_brick_count;
- int cold_replica_count;
- int cold_disperse_count;
- int cold_dist_leaf_count;
- int cold_redundancy_count;
- int hot_type;
- int hot_brick_count;
- int hot_replica_count;
- int promoted;
- int demoted;
- uint16_t cur_tier_hot;
+ int cold_type;
+ int cold_brick_count;
+ int cold_replica_count;
+ int cold_disperse_count;
+ int cold_dist_leaf_count;
+ int cold_redundancy_count;
+ int hot_type;
+ int hot_brick_count;
+ int hot_replica_count;
+ int promoted;
+ int demoted;
+ uint16_t cur_tier_hot;
} gd_tier_info_t;
struct glusterd_volinfo_ {
- gf_lock_t lock;
- gf_boolean_t is_snap_volume;
- glusterd_snap_t *snapshot;
- uuid_t restored_from_snap;
- gd_tier_info_t tier_info;
- gf_boolean_t is_tier_enabled;
- char parent_volname[GD_VOLUME_NAME_MAX];
- /* In case of a snap volume
- i.e (is_snap_volume == TRUE) this
- field will contain the name of
- the volume which is snapped. In
- case of a non-snap volume, this
- field will be initialized as N/A */
- char volname[NAME_MAX + 1];
- /* NAME_MAX + 1 will be equal to
- * GD_VOLUME_NAME_MAX + 5.(also to
- * GD_VOLUME_NAME_MAX_TIER). An extra 5
- * bytes are added to GD_VOLUME_NAME_MAX
- * because, as part of the tiering
- * volfile generation code, we are
- * temporarily appending either "-hot"
- * or "-cold" */
- int type;
- int brick_count;
- uint64_t snap_count;
- uint64_t snap_max_hard_limit;
- struct cds_list_head vol_list;
- /* In case of a snap volume
- i.e (is_snap_volume == TRUE) this
- is linked to glusterd_snap_t->volumes.
- In case of a non-snap volume, this is
- linked to glusterd_conf_t->volumes */
- struct cds_list_head snapvol_list;
- /* This is a current pointer for
- glusterd_volinfo_t->snap_volumes */
- struct cds_list_head bricks;
- struct cds_list_head snap_volumes;
- /* TODO : Need to remove this, as this
- * is already part of snapshot object.
- */
- glusterd_volume_status status;
- int sub_count; /* backward compatibility */
- int stripe_count;
- int replica_count;
- int arbiter_count;
- int disperse_count;
- int redundancy_count;
- int subvol_count; /* Number of subvolumes in a
- distribute volume */
- int dist_leaf_count; /* Number of bricks in one
- distribute subvolume */
- int port;
- gf_store_handle_t *shandle;
- gf_store_handle_t *node_state_shandle;
- gf_store_handle_t *quota_conf_shandle;
-
- /* Defrag/rebalance related */
- glusterd_rebalance_t rebal;
-
- /* Replace brick status */
- glusterd_replace_brick_t rep_brick;
-
- /* Bitrot scrub status*/
- glusterd_bitrot_scrub_t bitrot_scrub;
-
- glusterd_rebalance_t tier;
-
- int version;
- uint32_t quota_conf_version;
- uint32_t cksum;
- uint32_t quota_conf_cksum;
- gf_transport_type transport_type;
-
- dict_t *dict;
-
- uuid_t volume_id;
- auth_t auth;
- char *logdir;
-
- dict_t *gsync_slaves;
- dict_t *gsync_active_slaves;
-
- int decommission_in_progress;
- xlator_t *xl;
-
- gf_boolean_t memory_accounting;
- int caps; /* Capability */
-
- int op_version;
- int client_op_version;
- pthread_mutex_t reflock;
- int refcnt;
- gd_quorum_status_t quorum_status;
-
- glusterd_snapdsvc_t snapd;
- glusterd_tierdsvc_t tierd;
- glusterd_gfproxydsvc_t gfproxyd;
- int32_t quota_xattr_version;
- gf_boolean_t stage_deleted; /* volume has passed staging
- * for delete operation
- */
+ gf_lock_t lock;
+ gf_boolean_t is_snap_volume;
+ glusterd_snap_t *snapshot;
+ uuid_t restored_from_snap;
+ gd_tier_info_t tier_info;
+ gf_boolean_t is_tier_enabled;
+ char parent_volname[GD_VOLUME_NAME_MAX];
+ /* In case of a snap volume
+ i.e (is_snap_volume == TRUE) this
+ field will contain the name of
+ the volume which is snapped. In
+ case of a non-snap volume, this
+ field will be initialized as N/A */
+ char volname[NAME_MAX + 1];
+ /* NAME_MAX + 1 will be equal to
+ * GD_VOLUME_NAME_MAX + 5.(also to
+ * GD_VOLUME_NAME_MAX_TIER). An extra 5
+ * bytes are added to GD_VOLUME_NAME_MAX
+ * because, as part of the tiering
+ * volfile generation code, we are
+ * temporarily appending either "-hot"
+ * or "-cold" */
+ int type;
+ int brick_count;
+ uint64_t snap_count;
+ uint64_t snap_max_hard_limit;
+ struct cds_list_head vol_list;
+ /* In case of a snap volume
+ i.e (is_snap_volume == TRUE) this
+ is linked to glusterd_snap_t->volumes.
+ In case of a non-snap volume, this is
+ linked to glusterd_conf_t->volumes */
+ struct cds_list_head snapvol_list;
+ /* This is a current pointer for
+ glusterd_volinfo_t->snap_volumes */
+ struct cds_list_head bricks;
+ struct cds_list_head snap_volumes;
+ /* TODO : Need to remove this, as this
+ * is already part of snapshot object.
+ */
+ glusterd_volume_status status;
+ int sub_count; /* backward compatibility */
+ int stripe_count;
+ int replica_count;
+ int arbiter_count;
+ int disperse_count;
+ int redundancy_count;
+ int subvol_count; /* Number of subvolumes in a
+ distribute volume */
+ int dist_leaf_count; /* Number of bricks in one
+ distribute subvolume */
+ int port;
+ gf_store_handle_t *shandle;
+ gf_store_handle_t *node_state_shandle;
+ gf_store_handle_t *quota_conf_shandle;
+
+ /* Defrag/rebalance related */
+ glusterd_rebalance_t rebal;
+
+ /* Replace brick status */
+ glusterd_replace_brick_t rep_brick;
+
+ /* Bitrot scrub status*/
+ glusterd_bitrot_scrub_t bitrot_scrub;
+
+ glusterd_rebalance_t tier;
+
+ int version;
+ uint32_t quota_conf_version;
+ uint32_t cksum;
+ uint32_t quota_conf_cksum;
+ gf_transport_type transport_type;
+
+ dict_t *dict;
+
+ uuid_t volume_id;
+ auth_t auth;
+ char *logdir;
+
+ dict_t *gsync_slaves;
+ dict_t *gsync_active_slaves;
+
+ int decommission_in_progress;
+ xlator_t *xl;
+
+ gf_boolean_t memory_accounting;
+ int caps; /* Capability */
+
+ int op_version;
+ int client_op_version;
+ pthread_mutex_t reflock;
+ int refcnt;
+ gd_quorum_status_t quorum_status;
+
+ glusterd_snapdsvc_t snapd;
+ glusterd_tierdsvc_t tierd;
+ glusterd_gfproxydsvc_t gfproxyd;
+ int32_t quota_xattr_version;
+ gf_boolean_t stage_deleted; /* volume has passed staging
+ * for delete operation
+ */
};
typedef enum gd_snap_status_ {
- GD_SNAP_STATUS_NONE,
- GD_SNAP_STATUS_INIT,
- GD_SNAP_STATUS_IN_USE,
- GD_SNAP_STATUS_DECOMMISSION,
- GD_SNAP_STATUS_UNDER_RESTORE,
- GD_SNAP_STATUS_RESTORED,
+ GD_SNAP_STATUS_NONE,
+ GD_SNAP_STATUS_INIT,
+ GD_SNAP_STATUS_IN_USE,
+ GD_SNAP_STATUS_DECOMMISSION,
+ GD_SNAP_STATUS_UNDER_RESTORE,
+ GD_SNAP_STATUS_RESTORED,
} gd_snap_status_t;
struct glusterd_snap_ {
- gf_lock_t lock;
- struct cds_list_head volumes;
- struct cds_list_head snap_list;
- char snapname[GLUSTERD_MAX_SNAP_NAME];
- uuid_t snap_id;
- char *description;
- time_t time_stamp;
- gf_boolean_t snap_restored;
- gd_snap_status_t snap_status;
- gf_store_handle_t *shandle;
+ gf_lock_t lock;
+ struct cds_list_head volumes;
+ struct cds_list_head snap_list;
+ char snapname[GLUSTERD_MAX_SNAP_NAME];
+ uuid_t snap_id;
+ char *description;
+ time_t time_stamp;
+ gf_boolean_t snap_restored;
+ gd_snap_status_t snap_status;
+ gf_store_handle_t *shandle;
};
typedef struct glusterd_snap_op_ {
- char *snap_vol_id;
- int32_t brick_num;
- char *brick_path;
- int32_t op;
- int32_t status;
- struct cds_list_head snap_ops_list;
+ char *snap_vol_id;
+ int32_t brick_num;
+ char *brick_path;
+ int32_t op;
+ int32_t status;
+ struct cds_list_head snap_ops_list;
} glusterd_snap_op_t;
typedef struct glusterd_missed_snap_ {
- char *node_uuid;
- char *snap_uuid;
- struct cds_list_head missed_snaps;
- struct cds_list_head snap_ops;
+ char *node_uuid;
+ char *snap_uuid;
+ struct cds_list_head missed_snaps;
+ struct cds_list_head snap_ops;
} glusterd_missed_snap_info;
typedef enum gd_node_type_ {
- GD_NODE_NONE,
- GD_NODE_BRICK,
- GD_NODE_SHD,
- GD_NODE_REBALANCE,
- GD_NODE_NFS,
- GD_NODE_QUOTAD,
- GD_NODE_SNAPD,
- GD_NODE_BITD,
- GD_NODE_SCRUB,
- GD_NODE_TIERD
+ GD_NODE_NONE,
+ GD_NODE_BRICK,
+ GD_NODE_SHD,
+ GD_NODE_REBALANCE,
+ GD_NODE_NFS,
+ GD_NODE_QUOTAD,
+ GD_NODE_SNAPD,
+ GD_NODE_BITD,
+ GD_NODE_SCRUB,
+ GD_NODE_TIERD
} gd_node_type;
typedef enum missed_snap_stat {
- GD_MISSED_SNAP_NONE,
- GD_MISSED_SNAP_PENDING,
- GD_MISSED_SNAP_DONE,
+ GD_MISSED_SNAP_NONE,
+ GD_MISSED_SNAP_PENDING,
+ GD_MISSED_SNAP_DONE,
} missed_snap_stat;
typedef struct glusterd_pending_node_ {
- struct cds_list_head list;
- void *node;
- gd_node_type type;
- int32_t index;
+ struct cds_list_head list;
+ void *node;
+ gd_node_type type;
+ int32_t index;
} glusterd_pending_node_t;
struct gsync_config_opt_vals_ {
- char *op_name;
- int no_of_pos_vals;
- gf_boolean_t case_sensitive;
- char *values[GEO_CONF_MAX_OPT_VALS];
+ char *op_name;
+ int no_of_pos_vals;
+ gf_boolean_t case_sensitive;
+ char *values[GEO_CONF_MAX_OPT_VALS];
};
enum glusterd_op_ret {
- GLUSTERD_CONNECTION_AWAITED = 100,
+ GLUSTERD_CONNECTION_AWAITED = 100,
};
enum glusterd_vol_comp_status_ {
- GLUSTERD_VOL_COMP_NONE = 0,
- GLUSTERD_VOL_COMP_SCS = 1,
- GLUSTERD_VOL_COMP_UPDATE_REQ,
- GLUSTERD_VOL_COMP_RJT,
+ GLUSTERD_VOL_COMP_NONE = 0,
+ GLUSTERD_VOL_COMP_SCS = 1,
+ GLUSTERD_VOL_COMP_UPDATE_REQ,
+ GLUSTERD_VOL_COMP_RJT,
};
typedef struct addrinfo_list {
- struct cds_list_head list;
- struct addrinfo *info;
+ struct cds_list_head list;
+ struct addrinfo *info;
} addrinfo_list_t;
typedef enum {
- GF_AI_COMPARE_NO_MATCH = 0,
- GF_AI_COMPARE_MATCH = 1,
- GF_AI_COMPARE_ERROR = 2
+ GF_AI_COMPARE_NO_MATCH = 0,
+ GF_AI_COMPARE_MATCH = 1,
+ GF_AI_COMPARE_ERROR = 2
} gf_ai_compare_t;
-#define GLUSTERD_DEFAULT_PORT GF_DEFAULT_BASE_PORT
-#define GLUSTERD_INFO_FILE "glusterd.info"
+#define GLUSTERD_DEFAULT_PORT GF_DEFAULT_BASE_PORT
+#define GLUSTERD_INFO_FILE "glusterd.info"
#define GLUSTERD_VOLUME_QUOTA_CONFIG "quota.conf"
#define GLUSTERD_VOLUME_DIR_PREFIX "vols"
#define GLUSTERD_PEER_DIR_PREFIX "peers"
@@ -607,813 +609,883 @@ typedef enum {
#define GLUSTERD_MISSED_SNAPS_LIST_FILE "missed_snaps_list"
#define GLUSTERD_VOL_SNAP_DIR_PREFIX "snaps"
-#define GLUSTERD_DEFAULT_SNAPS_BRICK_DIR "/gluster/snaps"
-#define GLUSTERD_BITD_RUN_DIR "/bitd"
-#define GLUSTERD_SCRUB_RUN_DIR "/scrub"
-#define GLUSTERD_GLUSTERSHD_RUN_DIR "/glustershd"
-#define GLUSTERD_NFS_RUN_DIR "/nfs"
-#define GLUSTERD_QUOTAD_RUN_DIR "/quotad"
-#define GLUSTER_SHARED_STORAGE_BRICK_DIR GLUSTERD_DEFAULT_WORKDIR"/ss_brick"
-#define GLUSTERD_VAR_RUN_DIR "/var/run"
-#define GLUSTERD_RUN_DIR "/run"
+#define GLUSTERD_DEFAULT_SNAPS_BRICK_DIR "/gluster/snaps"
+#define GLUSTERD_BITD_RUN_DIR "/bitd"
+#define GLUSTERD_SCRUB_RUN_DIR "/scrub"
+#define GLUSTERD_GLUSTERSHD_RUN_DIR "/glustershd"
+#define GLUSTERD_NFS_RUN_DIR "/nfs"
+#define GLUSTERD_QUOTAD_RUN_DIR "/quotad"
+#define GLUSTER_SHARED_STORAGE_BRICK_DIR GLUSTERD_DEFAULT_WORKDIR "/ss_brick"
+#define GLUSTERD_VAR_RUN_DIR "/var/run"
+#define GLUSTERD_RUN_DIR "/run"
/* definitions related to replace brick */
-#define RB_CLIENT_MOUNTPOINT "rb_mount"
-#define RB_CLIENTVOL_FILENAME "rb_client.vol"
-#define RB_DSTBRICK_PIDFILE "rb_dst_brick.pid"
+#define RB_CLIENT_MOUNTPOINT "rb_mount"
+#define RB_CLIENTVOL_FILENAME "rb_client.vol"
+#define RB_DSTBRICK_PIDFILE "rb_dst_brick.pid"
#define RB_DSTBRICKVOL_FILENAME "rb_dst_brick.vol"
-#define RB_PUMP_DEF_ARG "default"
+#define RB_PUMP_DEF_ARG "default"
#define GLUSTERD_UUID_LEN 50
-typedef ssize_t (*gd_serialize_t) (struct iovec outmsg, void *args);
-
-#define GLUSTERD_GET_VOLUME_DIR(path, volinfo, priv) \
- do { \
- int32_t _vol_dir_len; \
- if (volinfo->is_snap_volume) { \
- _vol_dir_len = snprintf (path, PATH_MAX, "%s/snaps/%s/%s", \
- priv->workdir, \
- volinfo->snapshot->snapname, \
- volinfo->volname); \
- } else { \
- _vol_dir_len = snprintf (path, PATH_MAX, "%s/vols/%s",\
- priv->workdir, volinfo->volname); \
- } \
- if ((_vol_dir_len < 0) || (_vol_dir_len >= PATH_MAX)) { \
- path[0] = 0; \
- } \
- } while (0)
-
-#define GLUSTERD_GET_TIER_DIR(path, volinfo, priv) do { \
- int32_t _tier_dir_len; \
- _tier_dir_len = snprintf (path, PATH_MAX, "%s/tier/%s", \
- priv->workdir, volinfo->volname); \
- if ((_tier_dir_len < 0) || (_tier_dir_len >= PATH_MAX)) { \
- path[0] = 0; \
- } \
- } while (0)
-
-#define GLUSTERD_GET_TIER_PID_FILE(path, volinfo, priv) do { \
- char tier_path[PATH_MAX]; \
- int32_t _tier_pid_len; \
- GLUSTERD_GET_TIER_DIR(tier_path, volinfo, priv); \
- _tier_pid_len = snprintf (path, PATH_MAX, "%s/run/%s-tierd.pid", \
- tier_path, volinfo->volname); \
- if ((_tier_pid_len < 0) || (_tier_pid_len >= PATH_MAX)) { \
- path[0] = 0; \
- } \
- } while (0)
-
-#define GLUSTERD_GET_VOLUME_PID_DIR(path, volinfo, priv) \
-do { \
- int32_t _vol_pid_len; \
- if (volinfo->is_snap_volume) { \
- _vol_pid_len = snprintf (path, PATH_MAX, "%s/snaps/%s/%s", \
- priv->rundir, \
- volinfo->snapshot->snapname, \
- volinfo->volname); \
- } else { \
- _vol_pid_len = snprintf (path, PATH_MAX, "%s/vols/%s", \
- priv->rundir, \
- volinfo->volname); \
- } \
- if ((_vol_pid_len < 0) || (_vol_pid_len >= PATH_MAX)) { \
- path[0] = 0; \
- } \
-} while (0)
-
-#define GLUSTERD_GET_SNAP_DIR(path, snap, priv) \
- do { \
- int32_t _snap_dir_len; \
- _snap_dir_len = snprintf (path, PATH_MAX, "%s/snaps/%s", priv->workdir, \
- snap->snapname); \
- if ((_snap_dir_len < 0) || (_snap_dir_len >= PATH_MAX)) { \
- path[0] = 0; \
- } \
- } while (0)
-
-#define GLUSTERD_GET_SNAP_GEO_REP_DIR(path, snap, priv) \
- do { \
- int32_t _snap_geo_len; \
- _snap_geo_len = snprintf (path, PATH_MAX, "%s/snaps/%s/%s", \
- priv->workdir, snap->snapname, GEOREP); \
- if ((_snap_geo_len < 0) || (_snap_geo_len >= PATH_MAX)) { \
- path[0] = 0; \
- } \
- } while (0)
-
-#define GLUSTERD_GET_BRICK_DIR(path, volinfo, priv) \
- do { \
- int32_t _brick_len; \
- if (volinfo->is_snap_volume) { \
- _brick_len = snprintf (path, PATH_MAX, "%s/snaps/%s/%s/%s", \
- priv->workdir, \
- volinfo->snapshot->snapname, \
- volinfo->volname, \
- GLUSTERD_BRICK_INFO_DIR); \
- } else { \
- _brick_len = snprintf (path, PATH_MAX, "%s/%s/%s/%s", \
- priv->workdir, \
- GLUSTERD_VOLUME_DIR_PREFIX, \
- volinfo->volname, \
- GLUSTERD_BRICK_INFO_DIR); \
- } \
- if ((_brick_len < 0) || (_brick_len >= PATH_MAX)) { \
- path[0] = 0; \
- } \
- } while (0)
-
-#define GLUSTERD_GET_NFS_DIR(path, priv) \
- do { \
- int32_t _nfs_dir_len; \
- _nfs_dir_len = snprintf (path, PATH_MAX, "%s/nfs", priv->workdir); \
- if ((_nfs_dir_len < 0) || (_nfs_dir_len >= PATH_MAX)) { \
- path[0] = 0; \
- } \
- } while (0)
-
-#define GLUSTERD_GET_QUOTAD_DIR(path, priv) \
- do { \
- int32_t _quotad_dir_len; \
- _quotad_dir_len = snprintf (path, PATH_MAX, "%s/quotad", priv->workdir); \
- if ((_quotad_dir_len < 0) || (_quotad_dir_len >= PATH_MAX)) { \
- path[0] = 0; \
- } \
- } while (0)
-
-#define GLUSTERD_GET_QUOTA_LIMIT_MOUNT_PATH(abspath, volname, path) do { \
- snprintf (abspath, sizeof (abspath)-1, \
- DEFAULT_VAR_RUN_DIRECTORY"/%s_quota_limit%s", volname, path);\
- } while (0)
-
-#define GLUSTERD_GET_QUOTA_LIST_MOUNT_PATH(abspath, volname, path) do { \
- snprintf (abspath, sizeof (abspath)-1, \
- DEFAULT_VAR_RUN_DIRECTORY"/%s_quota_list%s", volname, path);\
- } while (0)
-
-#define GLUSTERD_GET_TMP_PATH(abspath, path) do { \
- snprintf (abspath, sizeof (abspath)-1, \
- DEFAULT_VAR_RUN_DIRECTORY"/tmp%s", path); \
- } while (0)
-
-#define GLUSTERD_REMOVE_SLASH_FROM_PATH(path,string) do { \
- int i = 0; \
- for (i = 1; i < strlen (path); i++) { \
- string[i-1] = path[i]; \
- if (string[i-1] == '/' && (i != strlen(path) - 1)) \
- string[i-1] = '-'; \
- } \
- } while (0)
-
-#define GLUSTERD_GET_BRICK_PIDFILE(pidfile,volinfo,brickinfo, priv) do { \
- char exp_path[PATH_MAX] = {0,}; \
- char volpath[PATH_MAX] = {0,}; \
- int32_t _brick_pid_len = 0; \
- GLUSTERD_GET_VOLUME_PID_DIR (volpath, volinfo, priv); \
- GLUSTERD_REMOVE_SLASH_FROM_PATH (brickinfo->path, exp_path); \
- _brick_pid_len = snprintf (pidfile, PATH_MAX, "%s/%s-%s.pid", \
- volpath, brickinfo->hostname, exp_path); \
- if ((_brick_pid_len < 0) || (_brick_pid_len >= PATH_MAX)) { \
- pidfile[0] = 0; \
- } \
- } while (0)
-
-#define GLUSTERD_GET_NFS_PIDFILE(pidfile, nfspath, priv) do { \
- int32_t _nfs_pid_len; \
- _nfs_pid_len = snprintf (pidfile, PATH_MAX, "%s/nfs/nfs.pid", \
- priv->rundir); \
- if ((_nfs_pid_len < 0) || (_nfs_pid_len >= PATH_MAX)) { \
- pidfile[0] = 0; \
- } \
- } while (0)
-
-#define GLUSTERD_GET_QUOTAD_PIDFILE(pidfile, quotadpath, priv) do { \
- int32_t _quotad_pid_len; \
- _quotad_pid_len = snprintf (pidfile, PATH_MAX, "%s/quotad/quotad.pid", \
- priv->rundir); \
- if ((_quotad_pid_len < 0) || (_quotad_pid_len >= PATH_MAX)) { \
- pidfile[0] = 0; \
- } \
- } while (0)
-
-#define GLUSTERD_GET_QUOTA_CRAWL_PIDDIR(piddir, volinfo, type) do { \
- char _volpath[PATH_MAX] = {0,}; \
- int32_t _crawl_pid_len; \
- GLUSTERD_GET_VOLUME_DIR (_volpath, volinfo, priv); \
- if (type == GF_QUOTA_OPTION_TYPE_ENABLE || \
- type == GF_QUOTA_OPTION_TYPE_ENABLE_OBJECTS) \
- _crawl_pid_len = snprintf (piddir, PATH_MAX, \
- "%s/run/quota/enable", _volpath); \
- else \
- _crawl_pid_len = snprintf (piddir, PATH_MAX, \
- "%s/run/quota/disable", _volpath); \
- if ((_crawl_pid_len < 0) || (_crawl_pid_len >= PATH_MAX)) { \
- piddir[0] = 0; \
- } \
- } while (0)
-
-#define GLUSTERD_STACK_DESTROY(frame) do {\
- frame->local = NULL; \
- STACK_DESTROY (frame->root); \
- } while (0)
-
-#define GLUSTERD_GET_DEFRAG_PROCESS(path, volinfo) do { \
- if (volinfo->rebal.defrag_cmd == GF_DEFRAG_CMD_START_TIER) \
- snprintf (path, NAME_MAX, "tier"); \
- else \
- snprintf (path, NAME_MAX, "rebalance"); \
- } while (0)
-
-#define GLUSTERD_GET_DEFRAG_DIR(path, volinfo, priv) do { \
- char vol_path[PATH_MAX]; \
- char operation[NAME_MAX]; \
- int32_t _defrag_dir_len; \
- GLUSTERD_GET_VOLUME_DIR(vol_path, volinfo, priv); \
- GLUSTERD_GET_DEFRAG_PROCESS(operation, volinfo); \
- _defrag_dir_len = snprintf (path, PATH_MAX, "%s/%s", vol_path,\
- operation); \
- if ((_defrag_dir_len < 0) || (_defrag_dir_len >= PATH_MAX)) { \
- path[0] = 0; \
- } \
- } while (0)
-
-#define GLUSTERD_GET_DEFRAG_SOCK_FILE_OLD(path, volinfo, priv) do { \
- char defrag_path[PATH_MAX]; \
- int32_t _sockfile_old_len; \
- GLUSTERD_GET_DEFRAG_DIR(defrag_path, volinfo, priv); \
- _sockfile_old_len = snprintf (path, PATH_MAX, "%s/%s.sock", \
- defrag_path, uuid_utoa(MY_UUID)); \
- if ((_sockfile_old_len < 0) || (_sockfile_old_len >= PATH_MAX)) { \
- path[0] = 0; \
- } \
- } while (0)
-
-#define GLUSTERD_GET_DEFRAG_SOCK_FILE(path, volinfo) do { \
- char operation[NAME_MAX]; \
- int32_t _defrag_sockfile_len; \
- GLUSTERD_GET_DEFRAG_PROCESS(operation, volinfo); \
- _defrag_sockfile_len = snprintf (path, UNIX_PATH_MAX, \
- DEFAULT_VAR_RUN_DIRECTORY \
- "/gluster-%s-%s.sock", operation, \
- uuid_utoa(volinfo->volume_id)); \
- if ((_defrag_sockfile_len < 0) || (_defrag_sockfile_len >= PATH_MAX)) { \
- path[0] = 0; \
- } \
- } while (0)
-
-#define GLUSTERD_GET_DEFRAG_PID_FILE(path, volinfo, priv) do { \
- char defrag_path[PATH_MAX]; \
- int32_t _defrag_pidfile_len; \
- GLUSTERD_GET_DEFRAG_DIR(defrag_path, volinfo, priv); \
- _defrag_pidfile_len = snprintf (path, PATH_MAX, "%s/%s.pid", \
- defrag_path, uuid_utoa(MY_UUID)); \
- if ((_defrag_pidfile_len < 0) || (_defrag_pidfile_len >= PATH_MAX)) { \
- path[0] = 0; \
- } \
- } while (0)
-
-#define GLUSTERFS_GET_QUOTA_LIMIT_MOUNT_PIDFILE(pidfile, volname) { \
- snprintf (pidfile, PATH_MAX-1, \
- DEFAULT_VAR_RUN_DIRECTORY"/%s_quota_limit.pid", \
- volname); \
- }
-
-#define GLUSTERFS_GET_QUOTA_LIST_MOUNT_PIDFILE(pidfile, volname) { \
- snprintf (pidfile, PATH_MAX-1, \
- DEFAULT_VAR_RUN_DIRECTORY"/%s_quota_list.pid", \
- volname); \
- }
-
-
-#define GLUSTERD_GET_UUID_NOHYPHEN(ret_string, uuid) do { \
- char *snap_volname_ptr = ret_string; \
- char tmp_uuid[64]; \
- char *snap_volid_ptr = uuid_utoa_r(uuid, tmp_uuid); \
- while (*snap_volid_ptr) { \
- if (*snap_volid_ptr == '-') { \
- snap_volid_ptr++; \
- } else { \
- (*snap_volname_ptr++) = \
- (*snap_volid_ptr++); \
- } \
- } \
- *snap_volname_ptr = '\0'; \
- } while (0)
-
-#define GLUSTERD_DUMP_PEERS(head, member, xpeers) do { \
- glusterd_peerinfo_t *_peerinfo = NULL; \
- int index = 1; \
- char *key = NULL; \
- \
- key = xpeers ? "glusterd.xaction_peer" : "glusterd.peer"; \
- \
- rcu_read_lock (); \
- cds_list_for_each_entry_rcu (_peerinfo, head, member) { \
- glusterd_dump_peer (_peerinfo, key, index, xpeers); \
- if (!xpeers) \
- glusterd_dump_peer_rpcstat (_peerinfo, key, \
- index); \
- index++; \
- } \
- rcu_read_unlock (); \
- \
- } while (0)
-
-int glusterd_uuid_init();
-
-int glusterd_uuid_generate_save ();
+typedef ssize_t (*gd_serialize_t)(struct iovec outmsg, void *args);
+
+#define GLUSTERD_GET_VOLUME_DIR(path, volinfo, priv) \
+ do { \
+ int32_t _vol_dir_len; \
+ if (volinfo->is_snap_volume) { \
+ _vol_dir_len = snprintf( \
+ path, PATH_MAX, "%s/snaps/%s/%s", priv->workdir, \
+ volinfo->snapshot->snapname, volinfo->volname); \
+ } else { \
+ _vol_dir_len = snprintf(path, PATH_MAX, "%s/vols/%s", \
+ priv->workdir, volinfo->volname); \
+ } \
+ if ((_vol_dir_len < 0) || (_vol_dir_len >= PATH_MAX)) { \
+ path[0] = 0; \
+ } \
+ } while (0)
+
+#define GLUSTERD_GET_TIER_DIR(path, volinfo, priv) \
+ do { \
+ int32_t _tier_dir_len; \
+ _tier_dir_len = snprintf(path, PATH_MAX, "%s/tier/%s", priv->workdir, \
+ volinfo->volname); \
+ if ((_tier_dir_len < 0) || (_tier_dir_len >= PATH_MAX)) { \
+ path[0] = 0; \
+ } \
+ } while (0)
+
+#define GLUSTERD_GET_TIER_PID_FILE(path, volinfo, priv) \
+ do { \
+ char tier_path[PATH_MAX]; \
+ int32_t _tier_pid_len; \
+ GLUSTERD_GET_TIER_DIR(tier_path, volinfo, priv); \
+ _tier_pid_len = snprintf(path, PATH_MAX, "%s/run/%s-tierd.pid", \
+ tier_path, volinfo->volname); \
+ if ((_tier_pid_len < 0) || (_tier_pid_len >= PATH_MAX)) { \
+ path[0] = 0; \
+ } \
+ } while (0)
+
+#define GLUSTERD_GET_VOLUME_PID_DIR(path, volinfo, priv) \
+ do { \
+ int32_t _vol_pid_len; \
+ if (volinfo->is_snap_volume) { \
+ _vol_pid_len = snprintf(path, PATH_MAX, "%s/snaps/%s/%s", \
+ priv->rundir, volinfo->snapshot->snapname, \
+ volinfo->volname); \
+ } else { \
+ _vol_pid_len = snprintf(path, PATH_MAX, "%s/vols/%s", \
+ priv->rundir, volinfo->volname); \
+ } \
+ if ((_vol_pid_len < 0) || (_vol_pid_len >= PATH_MAX)) { \
+ path[0] = 0; \
+ } \
+ } while (0)
+
+#define GLUSTERD_GET_SNAP_DIR(path, snap, priv) \
+ do { \
+ int32_t _snap_dir_len; \
+ _snap_dir_len = snprintf(path, PATH_MAX, "%s/snaps/%s", priv->workdir, \
+ snap->snapname); \
+ if ((_snap_dir_len < 0) || (_snap_dir_len >= PATH_MAX)) { \
+ path[0] = 0; \
+ } \
+ } while (0)
+
+#define GLUSTERD_GET_SNAP_GEO_REP_DIR(path, snap, priv) \
+ do { \
+ int32_t _snap_geo_len; \
+ _snap_geo_len = snprintf(path, PATH_MAX, "%s/snaps/%s/%s", \
+ priv->workdir, snap->snapname, GEOREP); \
+ if ((_snap_geo_len < 0) || (_snap_geo_len >= PATH_MAX)) { \
+ path[0] = 0; \
+ } \
+ } while (0)
+
+#define GLUSTERD_GET_BRICK_DIR(path, volinfo, priv) \
+ do { \
+ int32_t _brick_len; \
+ if (volinfo->is_snap_volume) { \
+ _brick_len = snprintf(path, PATH_MAX, "%s/snaps/%s/%s/%s", \
+ priv->workdir, volinfo->snapshot->snapname, \
+ volinfo->volname, GLUSTERD_BRICK_INFO_DIR); \
+ } else { \
+ _brick_len = snprintf(path, PATH_MAX, "%s/%s/%s/%s", \
+ priv->workdir, GLUSTERD_VOLUME_DIR_PREFIX, \
+ volinfo->volname, GLUSTERD_BRICK_INFO_DIR); \
+ } \
+ if ((_brick_len < 0) || (_brick_len >= PATH_MAX)) { \
+ path[0] = 0; \
+ } \
+ } while (0)
+
+#define GLUSTERD_GET_NFS_DIR(path, priv) \
+ do { \
+ int32_t _nfs_dir_len; \
+ _nfs_dir_len = snprintf(path, PATH_MAX, "%s/nfs", priv->workdir); \
+ if ((_nfs_dir_len < 0) || (_nfs_dir_len >= PATH_MAX)) { \
+ path[0] = 0; \
+ } \
+ } while (0)
+
+#define GLUSTERD_GET_QUOTAD_DIR(path, priv) \
+ do { \
+ int32_t _quotad_dir_len; \
+ _quotad_dir_len = snprintf(path, PATH_MAX, "%s/quotad", \
+ priv->workdir); \
+ if ((_quotad_dir_len < 0) || (_quotad_dir_len >= PATH_MAX)) { \
+ path[0] = 0; \
+ } \
+ } while (0)
+
+#define GLUSTERD_GET_QUOTA_LIMIT_MOUNT_PATH(abspath, volname, path) \
+ do { \
+ snprintf(abspath, sizeof(abspath) - 1, \
+ DEFAULT_VAR_RUN_DIRECTORY "/%s_quota_limit%s", volname, \
+ path); \
+ } while (0)
+
+#define GLUSTERD_GET_QUOTA_LIST_MOUNT_PATH(abspath, volname, path) \
+ do { \
+ snprintf(abspath, sizeof(abspath) - 1, \
+ DEFAULT_VAR_RUN_DIRECTORY "/%s_quota_list%s", volname, path); \
+ } while (0)
+
+#define GLUSTERD_GET_TMP_PATH(abspath, path) \
+ do { \
+ snprintf(abspath, sizeof(abspath) - 1, \
+ DEFAULT_VAR_RUN_DIRECTORY "/tmp%s", path); \
+ } while (0)
+
+#define GLUSTERD_REMOVE_SLASH_FROM_PATH(path, string) \
+ do { \
+ int i = 0; \
+ for (i = 1; i < strlen(path); i++) { \
+ string[i - 1] = path[i]; \
+ if (string[i - 1] == '/' && (i != strlen(path) - 1)) \
+ string[i - 1] = '-'; \
+ } \
+ } while (0)
+
+#define GLUSTERD_GET_BRICK_PIDFILE(pidfile, volinfo, brickinfo, priv) \
+ do { \
+ char exp_path[PATH_MAX] = { \
+ 0, \
+ }; \
+ char volpath[PATH_MAX] = { \
+ 0, \
+ }; \
+ int32_t _brick_pid_len = 0; \
+ GLUSTERD_GET_VOLUME_PID_DIR(volpath, volinfo, priv); \
+ GLUSTERD_REMOVE_SLASH_FROM_PATH(brickinfo->path, exp_path); \
+ _brick_pid_len = snprintf(pidfile, PATH_MAX, "%s/%s-%s.pid", volpath, \
+ brickinfo->hostname, exp_path); \
+ if ((_brick_pid_len < 0) || (_brick_pid_len >= PATH_MAX)) { \
+ pidfile[0] = 0; \
+ } \
+ } while (0)
+
+#define GLUSTERD_GET_NFS_PIDFILE(pidfile, nfspath, priv) \
+ do { \
+ int32_t _nfs_pid_len; \
+ _nfs_pid_len = snprintf(pidfile, PATH_MAX, "%s/nfs/nfs.pid", \
+ priv->rundir); \
+ if ((_nfs_pid_len < 0) || (_nfs_pid_len >= PATH_MAX)) { \
+ pidfile[0] = 0; \
+ } \
+ } while (0)
+
+#define GLUSTERD_GET_QUOTAD_PIDFILE(pidfile, quotadpath, priv) \
+ do { \
+ int32_t _quotad_pid_len; \
+ _quotad_pid_len = snprintf(pidfile, PATH_MAX, "%s/quotad/quotad.pid", \
+ priv->rundir); \
+ if ((_quotad_pid_len < 0) || (_quotad_pid_len >= PATH_MAX)) { \
+ pidfile[0] = 0; \
+ } \
+ } while (0)
+
+#define GLUSTERD_GET_QUOTA_CRAWL_PIDDIR(piddir, volinfo, type) \
+ do { \
+ char _volpath[PATH_MAX] = { \
+ 0, \
+ }; \
+ int32_t _crawl_pid_len; \
+ GLUSTERD_GET_VOLUME_DIR(_volpath, volinfo, priv); \
+ if (type == GF_QUOTA_OPTION_TYPE_ENABLE || \
+ type == GF_QUOTA_OPTION_TYPE_ENABLE_OBJECTS) \
+ _crawl_pid_len = snprintf(piddir, PATH_MAX, "%s/run/quota/enable", \
+ _volpath); \
+ else \
+ _crawl_pid_len = snprintf(piddir, PATH_MAX, \
+ "%s/run/quota/disable", _volpath); \
+ if ((_crawl_pid_len < 0) || (_crawl_pid_len >= PATH_MAX)) { \
+ piddir[0] = 0; \
+ } \
+ } while (0)
+
+#define GLUSTERD_STACK_DESTROY(frame) \
+ do { \
+ frame->local = NULL; \
+ STACK_DESTROY(frame->root); \
+ } while (0)
+
+#define GLUSTERD_GET_DEFRAG_PROCESS(path, volinfo) \
+ do { \
+ if (volinfo->rebal.defrag_cmd == GF_DEFRAG_CMD_START_TIER) \
+ snprintf(path, NAME_MAX, "tier"); \
+ else \
+ snprintf(path, NAME_MAX, "rebalance"); \
+ } while (0)
+
+#define GLUSTERD_GET_DEFRAG_DIR(path, volinfo, priv) \
+ do { \
+ char vol_path[PATH_MAX]; \
+ char operation[NAME_MAX]; \
+ int32_t _defrag_dir_len; \
+ GLUSTERD_GET_VOLUME_DIR(vol_path, volinfo, priv); \
+ GLUSTERD_GET_DEFRAG_PROCESS(operation, volinfo); \
+ _defrag_dir_len = snprintf(path, PATH_MAX, "%s/%s", vol_path, \
+ operation); \
+ if ((_defrag_dir_len < 0) || (_defrag_dir_len >= PATH_MAX)) { \
+ path[0] = 0; \
+ } \
+ } while (0)
+
+#define GLUSTERD_GET_DEFRAG_SOCK_FILE_OLD(path, volinfo, priv) \
+ do { \
+ char defrag_path[PATH_MAX]; \
+ int32_t _sockfile_old_len; \
+ GLUSTERD_GET_DEFRAG_DIR(defrag_path, volinfo, priv); \
+ _sockfile_old_len = snprintf(path, PATH_MAX, "%s/%s.sock", \
+ defrag_path, uuid_utoa(MY_UUID)); \
+ if ((_sockfile_old_len < 0) || (_sockfile_old_len >= PATH_MAX)) { \
+ path[0] = 0; \
+ } \
+ } while (0)
+
+#define GLUSTERD_GET_DEFRAG_SOCK_FILE(path, volinfo) \
+ do { \
+ char operation[NAME_MAX]; \
+ int32_t _defrag_sockfile_len; \
+ GLUSTERD_GET_DEFRAG_PROCESS(operation, volinfo); \
+ _defrag_sockfile_len = snprintf( \
+ path, UNIX_PATH_MAX, \
+ DEFAULT_VAR_RUN_DIRECTORY "/gluster-%s-%s.sock", operation, \
+ uuid_utoa(volinfo->volume_id)); \
+ if ((_defrag_sockfile_len < 0) || \
+ (_defrag_sockfile_len >= PATH_MAX)) { \
+ path[0] = 0; \
+ } \
+ } while (0)
+
+#define GLUSTERD_GET_DEFRAG_PID_FILE(path, volinfo, priv) \
+ do { \
+ char defrag_path[PATH_MAX]; \
+ int32_t _defrag_pidfile_len; \
+ GLUSTERD_GET_DEFRAG_DIR(defrag_path, volinfo, priv); \
+ _defrag_pidfile_len = snprintf(path, PATH_MAX, "%s/%s.pid", \
+ defrag_path, uuid_utoa(MY_UUID)); \
+ if ((_defrag_pidfile_len < 0) || (_defrag_pidfile_len >= PATH_MAX)) { \
+ path[0] = 0; \
+ } \
+ } while (0)
+
+#define GLUSTERFS_GET_QUOTA_LIMIT_MOUNT_PIDFILE(pidfile, volname) \
+ { \
+ snprintf(pidfile, PATH_MAX - 1, \
+ DEFAULT_VAR_RUN_DIRECTORY "/%s_quota_limit.pid", volname); \
+ }
+
+#define GLUSTERFS_GET_QUOTA_LIST_MOUNT_PIDFILE(pidfile, volname) \
+ { \
+ snprintf(pidfile, PATH_MAX - 1, \
+ DEFAULT_VAR_RUN_DIRECTORY "/%s_quota_list.pid", volname); \
+ }
+
+#define GLUSTERD_GET_UUID_NOHYPHEN(ret_string, uuid) \
+ do { \
+ char *snap_volname_ptr = ret_string; \
+ char tmp_uuid[64]; \
+ char *snap_volid_ptr = uuid_utoa_r(uuid, tmp_uuid); \
+ while (*snap_volid_ptr) { \
+ if (*snap_volid_ptr == '-') { \
+ snap_volid_ptr++; \
+ } else { \
+ (*snap_volname_ptr++) = (*snap_volid_ptr++); \
+ } \
+ } \
+ *snap_volname_ptr = '\0'; \
+ } while (0)
+
+#define GLUSTERD_DUMP_PEERS(head, member, xpeers) \
+ do { \
+ glusterd_peerinfo_t *_peerinfo = NULL; \
+ int index = 1; \
+ char *key = NULL; \
+ \
+ key = xpeers ? "glusterd.xaction_peer" : "glusterd.peer"; \
+ \
+ rcu_read_lock(); \
+ cds_list_for_each_entry_rcu(_peerinfo, head, member) \
+ { \
+ glusterd_dump_peer(_peerinfo, key, index, xpeers); \
+ if (!xpeers) \
+ glusterd_dump_peer_rpcstat(_peerinfo, key, index); \
+ index++; \
+ } \
+ rcu_read_unlock(); \
+ \
+ } while (0)
+
+int
+glusterd_uuid_init();
+
+int
+glusterd_uuid_generate_save();
#define MY_UUID (__glusterd_uuid())
static inline unsigned char *
__glusterd_uuid()
{
- glusterd_conf_t *priv = THIS->private;
+ glusterd_conf_t *priv = THIS->private;
- if (gf_uuid_is_null (priv->uuid))
- glusterd_uuid_init();
- return &priv->uuid[0];
+ if (gf_uuid_is_null(priv->uuid))
+ glusterd_uuid_init();
+ return &priv->uuid[0];
}
-int glusterd_big_locked_notify (struct rpc_clnt *rpc, void *mydata,
- rpc_clnt_event_t event,
- void *data, rpc_clnt_notify_t notify_fn);
+int
+glusterd_big_locked_notify(struct rpc_clnt *rpc, void *mydata,
+ rpc_clnt_event_t event, void *data,
+ rpc_clnt_notify_t notify_fn);
int
-glusterd_big_locked_cbk (struct rpc_req *req, struct iovec *iov,
- int count, void *myframe, fop_cbk_fn_t fn);
+glusterd_big_locked_cbk(struct rpc_req *req, struct iovec *iov, int count,
+ void *myframe, fop_cbk_fn_t fn);
-int glusterd_big_locked_handler (rpcsvc_request_t *req, rpcsvc_actor actor_fn);
+int
+glusterd_big_locked_handler(rpcsvc_request_t *req, rpcsvc_actor actor_fn);
int32_t
-glusterd_brick_from_brickinfo (glusterd_brickinfo_t *brickinfo,
- char **new_brick);
+glusterd_brick_from_brickinfo(glusterd_brickinfo_t *brickinfo,
+ char **new_brick);
int
-glusterd_probe_begin (rpcsvc_request_t *req, const char *hoststr, int port,
- dict_t *dict, int *op_errno);
+glusterd_probe_begin(rpcsvc_request_t *req, const char *hoststr, int port,
+ dict_t *dict, int *op_errno);
int
-glusterd_xfer_friend_add_resp (rpcsvc_request_t *req, char *myhostname,
- char *remote_hostname, int port, int32_t op_ret,
- int32_t op_errno);
+glusterd_xfer_friend_add_resp(rpcsvc_request_t *req, char *myhostname,
+ char *remote_hostname, int port, int32_t op_ret,
+ int32_t op_errno);
int
-glusterd_friend_add (const char *hoststr, int port,
- glusterd_friend_sm_state_t state,
- uuid_t *uuid, glusterd_peerinfo_t **friend,
- gf_boolean_t restore, glusterd_peerctx_args_t *args);
+glusterd_friend_add(const char *hoststr, int port,
+ glusterd_friend_sm_state_t state, uuid_t *uuid,
+ glusterd_peerinfo_t **friend, gf_boolean_t restore,
+ glusterd_peerctx_args_t *args);
int
-glusterd_friend_add_from_peerinfo (glusterd_peerinfo_t *friend,
- gf_boolean_t restore,
- glusterd_peerctx_args_t *args);
+glusterd_friend_add_from_peerinfo(glusterd_peerinfo_t *friend,
+ gf_boolean_t restore,
+ glusterd_peerctx_args_t *args);
int
-glusterd_friend_rpc_create (xlator_t *this, glusterd_peerinfo_t *peerinfo,
- glusterd_peerctx_args_t *args);
+glusterd_friend_rpc_create(xlator_t *this, glusterd_peerinfo_t *peerinfo,
+ glusterd_peerctx_args_t *args);
int
-glusterd_friend_remove (uuid_t uuid, char *hostname);
+glusterd_friend_remove(uuid_t uuid, char *hostname);
int
-glusterd_op_lock_send_resp (rpcsvc_request_t *req, int32_t status);
+glusterd_op_lock_send_resp(rpcsvc_request_t *req, int32_t status);
int
-glusterd_op_unlock_send_resp (rpcsvc_request_t *req, int32_t status);
+glusterd_op_unlock_send_resp(rpcsvc_request_t *req, int32_t status);
int
-glusterd_op_mgmt_v3_lock_send_resp (rpcsvc_request_t *req,
- uuid_t *txn_id, int32_t status);
+glusterd_op_mgmt_v3_lock_send_resp(rpcsvc_request_t *req, uuid_t *txn_id,
+ int32_t status);
int
-glusterd_op_mgmt_v3_unlock_send_resp (rpcsvc_request_t *req,
- uuid_t *txn_id, int32_t status);
+glusterd_op_mgmt_v3_unlock_send_resp(rpcsvc_request_t *req, uuid_t *txn_id,
+ int32_t status);
int
-glusterd_op_stage_send_resp (rpcsvc_request_t *req,
- int32_t op, int32_t status,
- char *op_errstr, dict_t *rsp_dict);
+glusterd_op_stage_send_resp(rpcsvc_request_t *req, int32_t op, int32_t status,
+ char *op_errstr, dict_t *rsp_dict);
int
-glusterd_op_commmit_send_resp (rpcsvc_request_t *req,
- int32_t op, int32_t status);
+glusterd_op_commmit_send_resp(rpcsvc_request_t *req, int32_t op,
+ int32_t status);
int32_t
-glusterd_create_volume (rpcsvc_request_t *req, dict_t *dict);
+glusterd_create_volume(rpcsvc_request_t *req, dict_t *dict);
int
-glusterd_handle_incoming_friend_req (rpcsvc_request_t *req);
+glusterd_handle_incoming_friend_req(rpcsvc_request_t *req);
int
-glusterd_handle_probe_query (rpcsvc_request_t *req);
+glusterd_handle_probe_query(rpcsvc_request_t *req);
int
-glusterd_handle_cluster_lock (rpcsvc_request_t *req);
+glusterd_handle_cluster_lock(rpcsvc_request_t *req);
int
-glusterd_handle_cluster_unlock (rpcsvc_request_t *req);
+glusterd_handle_cluster_unlock(rpcsvc_request_t *req);
int
-glusterd_handle_stage_op (rpcsvc_request_t *req);
+glusterd_handle_stage_op(rpcsvc_request_t *req);
int
-glusterd_handle_commit_op (rpcsvc_request_t *req);
+glusterd_handle_commit_op(rpcsvc_request_t *req);
int
-glusterd_handle_cli_probe (rpcsvc_request_t *req);
+glusterd_handle_cli_probe(rpcsvc_request_t *req);
int
-glusterd_handle_create_volume (rpcsvc_request_t *req);
+glusterd_handle_create_volume(rpcsvc_request_t *req);
int
-glusterd_handle_defrag_volume (rpcsvc_request_t *req);
+glusterd_handle_defrag_volume(rpcsvc_request_t *req);
int
-glusterd_handle_defrag_volume_v2 (rpcsvc_request_t *req);
+glusterd_handle_defrag_volume_v2(rpcsvc_request_t *req);
int
-glusterd_xfer_cli_probe_resp (rpcsvc_request_t *req, int32_t op_ret,
- int32_t op_errno, char *op_errstr, char *hostname,
- int port, dict_t *dict);
+glusterd_xfer_cli_probe_resp(rpcsvc_request_t *req, int32_t op_ret,
+ int32_t op_errno, char *op_errstr, char *hostname,
+ int port, dict_t *dict);
int
-glusterd_op_commit_send_resp (rpcsvc_request_t *req,
- int32_t op, int32_t status, char *op_errstr,
- dict_t *rsp_dict);
+glusterd_op_commit_send_resp(rpcsvc_request_t *req, int32_t op, int32_t status,
+ char *op_errstr, dict_t *rsp_dict);
int
-glusterd_xfer_friend_remove_resp (rpcsvc_request_t *req, char *hostname, int port);
+glusterd_xfer_friend_remove_resp(rpcsvc_request_t *req, char *hostname,
+ int port);
int
-glusterd_deprobe_begin (rpcsvc_request_t *req, const char *hoststr, int port,
- uuid_t uuid, dict_t *dict, int *op_errno);
+glusterd_deprobe_begin(rpcsvc_request_t *req, const char *hoststr, int port,
+ uuid_t uuid, dict_t *dict, int *op_errno);
int
-glusterd_handle_cli_deprobe (rpcsvc_request_t *req);
+glusterd_handle_cli_deprobe(rpcsvc_request_t *req);
int
-glusterd_handle_incoming_unfriend_req (rpcsvc_request_t *req);
+glusterd_handle_incoming_unfriend_req(rpcsvc_request_t *req);
int32_t
-glusterd_list_friends (rpcsvc_request_t *req, dict_t *dict, int32_t flags);
+glusterd_list_friends(rpcsvc_request_t *req, dict_t *dict, int32_t flags);
int
-glusterd_handle_cli_list_friends (rpcsvc_request_t *req);
+glusterd_handle_cli_list_friends(rpcsvc_request_t *req);
int
-glusterd_handle_cli_start_volume (rpcsvc_request_t *req);
+glusterd_handle_cli_start_volume(rpcsvc_request_t *req);
int
-glusterd_handle_friend_update (rpcsvc_request_t *req);
+glusterd_handle_friend_update(rpcsvc_request_t *req);
int
-glusterd_handle_cli_stop_volume (rpcsvc_request_t *req);
+glusterd_handle_cli_stop_volume(rpcsvc_request_t *req);
int
-glusterd_handle_cli_delete_volume (rpcsvc_request_t *req);
+glusterd_handle_cli_delete_volume(rpcsvc_request_t *req);
int
-glusterd_handle_cli_get_volume (rpcsvc_request_t *req);
+glusterd_handle_cli_get_volume(rpcsvc_request_t *req);
int32_t
-glusterd_get_volumes (rpcsvc_request_t *req, dict_t *dict, int32_t flags);
+glusterd_get_volumes(rpcsvc_request_t *req, dict_t *dict, int32_t flags);
int
-glusterd_handle_add_brick (rpcsvc_request_t *req);
+glusterd_handle_add_brick(rpcsvc_request_t *req);
int
-glusterd_handle_tier (rpcsvc_request_t *req);
+glusterd_handle_tier(rpcsvc_request_t *req);
int
-glusterd_handle_attach_tier (rpcsvc_request_t *req);
+glusterd_handle_attach_tier(rpcsvc_request_t *req);
int
-glusterd_handle_detach_tier (rpcsvc_request_t *req);
+glusterd_handle_detach_tier(rpcsvc_request_t *req);
int
-glusterd_handle_add_tier_brick (rpcsvc_request_t *req);
+glusterd_handle_add_tier_brick(rpcsvc_request_t *req);
int
-glusterd_handle_replace_brick (rpcsvc_request_t *req);
+glusterd_handle_replace_brick(rpcsvc_request_t *req);
int
-glusterd_handle_remove_brick (rpcsvc_request_t *req);
+glusterd_handle_remove_brick(rpcsvc_request_t *req);
int
-glusterd_handle_log_rotate (rpcsvc_request_t *req);
+glusterd_handle_log_rotate(rpcsvc_request_t *req);
int
-glusterd_handle_sync_volume (rpcsvc_request_t *req);
+glusterd_handle_sync_volume(rpcsvc_request_t *req);
int
-glusterd_defrag_start_validate (glusterd_volinfo_t *volinfo, char *op_errstr,
- size_t len, glusterd_op_t op);
+glusterd_defrag_start_validate(glusterd_volinfo_t *volinfo, char *op_errstr,
+ size_t len, glusterd_op_t op);
int
-glusterd_rebalance_cmd_validate (int cmd, char *volname,
- glusterd_volinfo_t **volinfo,
- char *op_errstr, size_t len);
+glusterd_rebalance_cmd_validate(int cmd, char *volname,
+ glusterd_volinfo_t **volinfo, char *op_errstr,
+ size_t len);
int32_t
-glusterd_log_filename (rpcsvc_request_t *req, dict_t *dict);
+glusterd_log_filename(rpcsvc_request_t *req, dict_t *dict);
int32_t
-glusterd_log_rotate (rpcsvc_request_t *req, dict_t *dict);
+glusterd_log_rotate(rpcsvc_request_t *req, dict_t *dict);
int32_t
-glusterd_remove_brick (rpcsvc_request_t *req, dict_t *dict);
+glusterd_remove_brick(rpcsvc_request_t *req, dict_t *dict);
int32_t
-glusterd_set_volume (rpcsvc_request_t *req, dict_t *dict);
+glusterd_set_volume(rpcsvc_request_t *req, dict_t *dict);
int32_t
-glusterd_reset_volume (rpcsvc_request_t *req, dict_t *dict);
+glusterd_reset_volume(rpcsvc_request_t *req, dict_t *dict);
int32_t
-glusterd_gsync_set (rpcsvc_request_t *req, dict_t *dict);
+glusterd_gsync_set(rpcsvc_request_t *req, dict_t *dict);
int32_t
-glusterd_quota (rpcsvc_request_t *req, dict_t *dict);
+glusterd_quota(rpcsvc_request_t *req, dict_t *dict);
int
-glusterd_handle_set_volume (rpcsvc_request_t *req);
+glusterd_handle_set_volume(rpcsvc_request_t *req);
int
-glusterd_handle_reset_volume (rpcsvc_request_t *req);
+glusterd_handle_reset_volume(rpcsvc_request_t *req);
int
-glusterd_handle_copy_file (rpcsvc_request_t *req);
+glusterd_handle_copy_file(rpcsvc_request_t *req);
int
-glusterd_handle_sys_exec (rpcsvc_request_t *req);
+glusterd_handle_sys_exec(rpcsvc_request_t *req);
int
-glusterd_handle_gsync_set (rpcsvc_request_t *req);
+glusterd_handle_gsync_set(rpcsvc_request_t *req);
int
-glusterd_handle_quota (rpcsvc_request_t *req);
+glusterd_handle_quota(rpcsvc_request_t *req);
int
-glusterd_handle_bitrot (rpcsvc_request_t *req);
+glusterd_handle_bitrot(rpcsvc_request_t *req);
int
-glusterd_handle_fsm_log (rpcsvc_request_t *req);
+glusterd_handle_fsm_log(rpcsvc_request_t *req);
int
-glusterd_handle_reset_brick (rpcsvc_request_t *req);
+glusterd_handle_reset_brick(rpcsvc_request_t *req);
int
-glusterd_xfer_cli_deprobe_resp (rpcsvc_request_t *req, int32_t op_ret,
- int32_t op_errno, char *op_errstr,
- char *hostname, dict_t *dict);
+glusterd_xfer_cli_deprobe_resp(rpcsvc_request_t *req, int32_t op_ret,
+ int32_t op_errno, char *op_errstr,
+ char *hostname, dict_t *dict);
int
-glusterd_client_statedump_submit_req (char *volname, char *target_ip,
- char *pid);
+glusterd_client_statedump_submit_req(char *volname, char *target_ip, char *pid);
int
-glusterd_fetchspec_notify (xlator_t *this);
+glusterd_fetchspec_notify(xlator_t *this);
int
-glusterd_fetchsnap_notify (xlator_t *this);
+glusterd_fetchsnap_notify(xlator_t *this);
int
-glusterd_add_tier_volume_detail_to_dict (glusterd_volinfo_t *volinfo,
- dict_t *volumes, int count);
+glusterd_add_tier_volume_detail_to_dict(glusterd_volinfo_t *volinfo,
+ dict_t *volumes, int count);
int
-glusterd_add_volume_detail_to_dict (glusterd_volinfo_t *volinfo,
- dict_t *volumes, int count);
+glusterd_add_volume_detail_to_dict(glusterd_volinfo_t *volinfo, dict_t *volumes,
+ int count);
int
-glusterd_restart_bricks ();
+glusterd_restart_bricks();
int32_t
-glusterd_volume_txn (rpcsvc_request_t *req, char *volname, int flags,
- glusterd_op_t op);
+glusterd_volume_txn(rpcsvc_request_t *req, char *volname, int flags,
+ glusterd_op_t op);
int
-glusterd_peer_dump_version (xlator_t *this, struct rpc_clnt *rpc,
- glusterd_peerctx_t *peerctx);
+glusterd_peer_dump_version(xlator_t *this, struct rpc_clnt *rpc,
+ glusterd_peerctx_t *peerctx);
int
-glusterd_validate_reconfopts (glusterd_volinfo_t *volinfo, dict_t *val_dict, char **op_errstr);
+glusterd_validate_reconfopts(glusterd_volinfo_t *volinfo, dict_t *val_dict,
+ char **op_errstr);
int
-glusterd_handle_cli_profile_volume (rpcsvc_request_t *req);
+glusterd_handle_cli_profile_volume(rpcsvc_request_t *req);
int
-glusterd_handle_getwd (rpcsvc_request_t *req);
+glusterd_handle_getwd(rpcsvc_request_t *req);
int32_t
-glusterd_set_volume (rpcsvc_request_t *req, dict_t *dict);
+glusterd_set_volume(rpcsvc_request_t *req, dict_t *dict);
int
-glusterd_peer_rpc_notify (struct rpc_clnt *rpc, void *mydata,
- rpc_clnt_event_t event,
- void *data);
+glusterd_peer_rpc_notify(struct rpc_clnt *rpc, void *mydata,
+ rpc_clnt_event_t event, void *data);
int
-glusterd_brick_rpc_notify (struct rpc_clnt *rpc, void *mydata,
+glusterd_brick_rpc_notify(struct rpc_clnt *rpc, void *mydata,
rpc_clnt_event_t event, void *data);
int
-glusterd_rpc_create (struct rpc_clnt **rpc, dict_t *options,
- rpc_clnt_notify_t notify_fn, void *notify_data,
- gf_boolean_t force);
-
+glusterd_rpc_create(struct rpc_clnt **rpc, dict_t *options,
+ rpc_clnt_notify_t notify_fn, void *notify_data,
+ gf_boolean_t force);
/* handler functions */
-int32_t glusterd_op_begin (rpcsvc_request_t *req, glusterd_op_t op, void *ctx,
- char *err_str, size_t size);
+int32_t
+glusterd_op_begin(rpcsvc_request_t *req, glusterd_op_t op, void *ctx,
+ char *err_str, size_t size);
/* removed other definitions as they have been defined elsewhere in this file*/
-int glusterd_handle_cli_statedump_volume (rpcsvc_request_t *req);
-int glusterd_handle_cli_clearlocks_volume (rpcsvc_request_t *req);
+int
+glusterd_handle_cli_statedump_volume(rpcsvc_request_t *req);
+int
+glusterd_handle_cli_clearlocks_volume(rpcsvc_request_t *req);
-int glusterd_handle_defrag_start (glusterd_volinfo_t *volinfo, char *op_errstr,
- size_t len, int cmd, defrag_cbk_fn_t cbk,
- glusterd_op_t op);
int
-glusterd_rebalance_rpc_create (glusterd_volinfo_t *volinfo);
+glusterd_handle_defrag_start(glusterd_volinfo_t *volinfo, char *op_errstr,
+ size_t len, int cmd, defrag_cbk_fn_t cbk,
+ glusterd_op_t op);
+int
+glusterd_rebalance_rpc_create(glusterd_volinfo_t *volinfo);
-int glusterd_rebalance_defrag_init (glusterd_volinfo_t *volinfo,
- defrag_cbk_fn_t cbk);
+int
+glusterd_rebalance_defrag_init(glusterd_volinfo_t *volinfo,
+ defrag_cbk_fn_t cbk);
-int glusterd_handle_cli_heal_volume (rpcsvc_request_t *req);
+int
+glusterd_handle_cli_heal_volume(rpcsvc_request_t *req);
-int glusterd_handle_cli_list_volume (rpcsvc_request_t *req);
+int
+glusterd_handle_cli_list_volume(rpcsvc_request_t *req);
int
-glusterd_handle_snapshot (rpcsvc_request_t *req);
+glusterd_handle_snapshot(rpcsvc_request_t *req);
/* op-sm functions */
-int glusterd_op_stage_heal_volume (dict_t *dict, char **op_errstr);
-int glusterd_op_heal_volume (dict_t *dict, char **op_errstr);
-int glusterd_op_stage_gsync_set (dict_t *dict, char **op_errstr);
-int glusterd_op_gsync_set (dict_t *dict, char **op_errstr, dict_t *rsp_dict);
-int glusterd_op_stage_copy_file (dict_t *dict, char **op_errstr);
-int glusterd_op_copy_file (dict_t *dict, char **op_errstr);
-int glusterd_op_stage_sys_exec (dict_t *dict, char **op_errstr);
-int glusterd_op_sys_exec (dict_t *dict, char **op_errstr, dict_t *rsp_dict);
-int glusterd_op_stage_gsync_create (dict_t *dict, char **op_errstr);
-int glusterd_op_gsync_create (dict_t *dict, char **op_errstr, dict_t *rsp_dict);
-int glusterd_op_quota (dict_t *dict, char **op_errstr, dict_t *rsp_dict);
-
-int glusterd_op_bitrot (dict_t *dict, char **op_errstr, dict_t *rsp_dict);
-
-int glusterd_op_stage_quota (dict_t *dict, char **op_errstr, dict_t *rsp_dict);
-
-int glusterd_op_stage_bitrot (dict_t *dict, char **op_errstr, dict_t *rsp_dict);
-
-int glusterd_op_stage_replace_brick (dict_t *dict, char **op_errstr,
- dict_t *rsp_dict);
-int glusterd_op_replace_brick (dict_t *dict, dict_t *rsp_dict);
-int glusterd_op_log_rotate (dict_t *dict);
-int glusterd_op_stage_log_rotate (dict_t *dict, char **op_errstr);
-int glusterd_op_stage_create_volume (dict_t *dict, char **op_errstr,
- dict_t *rsp_dict);
-int glusterd_op_stage_start_volume (dict_t *dict, char **op_errstr,
- dict_t *rsp_dict);
-int glusterd_op_stage_stop_volume (dict_t *dict, char **op_errstr);
-int glusterd_op_stage_delete_volume (dict_t *dict, char **op_errstr);
-int glusterd_op_create_volume (dict_t *dict, char **op_errstr);
-int glusterd_op_start_volume (dict_t *dict, char **op_errstr);
-int glusterd_op_stop_volume (dict_t *dict);
-int glusterd_op_delete_volume (dict_t *dict);
-int manage_export_config (char *volname, char *value, char **op_errstr);
-
-int glusterd_op_add_brick (dict_t *dict, char **op_errstr);
-int glusterd_op_add_tier_brick (dict_t *dict, char **op_errstr);
-int glusterd_op_remove_brick (dict_t *dict, char **op_errstr);
-int glusterd_op_stage_add_brick (dict_t *dict, char **op_errstr,
- dict_t *rsp_dict);
-int glusterd_op_stage_remove_brick (dict_t *dict, char **op_errstr);
-
-int glusterd_op_stage_rebalance (dict_t *dict, char **op_errstr);
-int glusterd_op_rebalance (dict_t *dict, char **op_errstr, dict_t *rsp_dict);
-
-int glusterd_op_stage_statedump_volume (dict_t *dict, char **op_errstr);
-int glusterd_op_statedump_volume (dict_t *dict, char **op_errstr);
-
-int glusterd_op_stage_clearlocks_volume (dict_t *dict, char **op_errstr);
-int glusterd_op_clearlocks_volume (dict_t *dict, char **op_errstr,
- dict_t *rsp_dict);
-
-
-int glusterd_op_stage_barrier (dict_t *dict, char **op_errstr);
-int glusterd_op_barrier (dict_t *dict, char **op_errstr);
+int
+glusterd_op_stage_heal_volume(dict_t *dict, char **op_errstr);
+int
+glusterd_op_heal_volume(dict_t *dict, char **op_errstr);
+int
+glusterd_op_stage_gsync_set(dict_t *dict, char **op_errstr);
+int
+glusterd_op_gsync_set(dict_t *dict, char **op_errstr, dict_t *rsp_dict);
+int
+glusterd_op_stage_copy_file(dict_t *dict, char **op_errstr);
+int
+glusterd_op_copy_file(dict_t *dict, char **op_errstr);
+int
+glusterd_op_stage_sys_exec(dict_t *dict, char **op_errstr);
+int
+glusterd_op_sys_exec(dict_t *dict, char **op_errstr, dict_t *rsp_dict);
+int
+glusterd_op_stage_gsync_create(dict_t *dict, char **op_errstr);
+int
+glusterd_op_gsync_create(dict_t *dict, char **op_errstr, dict_t *rsp_dict);
+int
+glusterd_op_quota(dict_t *dict, char **op_errstr, dict_t *rsp_dict);
+
+int
+glusterd_op_bitrot(dict_t *dict, char **op_errstr, dict_t *rsp_dict);
+
+int
+glusterd_op_stage_quota(dict_t *dict, char **op_errstr, dict_t *rsp_dict);
+
+int
+glusterd_op_stage_bitrot(dict_t *dict, char **op_errstr, dict_t *rsp_dict);
+
+int
+glusterd_op_stage_replace_brick(dict_t *dict, char **op_errstr,
+ dict_t *rsp_dict);
+int
+glusterd_op_replace_brick(dict_t *dict, dict_t *rsp_dict);
+int
+glusterd_op_log_rotate(dict_t *dict);
+int
+glusterd_op_stage_log_rotate(dict_t *dict, char **op_errstr);
+int
+glusterd_op_stage_create_volume(dict_t *dict, char **op_errstr,
+ dict_t *rsp_dict);
+int
+glusterd_op_stage_start_volume(dict_t *dict, char **op_errstr,
+ dict_t *rsp_dict);
+int
+glusterd_op_stage_stop_volume(dict_t *dict, char **op_errstr);
+int
+glusterd_op_stage_delete_volume(dict_t *dict, char **op_errstr);
+int
+glusterd_op_create_volume(dict_t *dict, char **op_errstr);
+int
+glusterd_op_start_volume(dict_t *dict, char **op_errstr);
+int
+glusterd_op_stop_volume(dict_t *dict);
+int
+glusterd_op_delete_volume(dict_t *dict);
+int
+manage_export_config(char *volname, char *value, char **op_errstr);
+
+int
+glusterd_op_add_brick(dict_t *dict, char **op_errstr);
+int
+glusterd_op_add_tier_brick(dict_t *dict, char **op_errstr);
+int
+glusterd_op_remove_brick(dict_t *dict, char **op_errstr);
+int
+glusterd_op_stage_add_brick(dict_t *dict, char **op_errstr, dict_t *rsp_dict);
+int
+glusterd_op_stage_remove_brick(dict_t *dict, char **op_errstr);
+
+int
+glusterd_op_stage_rebalance(dict_t *dict, char **op_errstr);
+int
+glusterd_op_rebalance(dict_t *dict, char **op_errstr, dict_t *rsp_dict);
+
+int
+glusterd_op_stage_statedump_volume(dict_t *dict, char **op_errstr);
+int
+glusterd_op_statedump_volume(dict_t *dict, char **op_errstr);
+
+int
+glusterd_op_stage_clearlocks_volume(dict_t *dict, char **op_errstr);
+int
+glusterd_op_clearlocks_volume(dict_t *dict, char **op_errstr, dict_t *rsp_dict);
+
+int
+glusterd_op_stage_barrier(dict_t *dict, char **op_errstr);
+int
+glusterd_op_barrier(dict_t *dict, char **op_errstr);
/* misc */
-int glusterd_op_perform_remove_brick (glusterd_volinfo_t *volinfo, char *brick,
- int force, int *need_migrate);
-int glusterd_op_stop_volume_args_get (dict_t *dict, char** volname, int *flags);
-int glusterd_op_statedump_volume_args_get (dict_t *dict, char **volname,
- char **options, int *option_cnt);
+int
+glusterd_op_perform_remove_brick(glusterd_volinfo_t *volinfo, char *brick,
+ int force, int *need_migrate);
+int
+glusterd_op_stop_volume_args_get(dict_t *dict, char **volname, int *flags);
+int
+glusterd_op_statedump_volume_args_get(dict_t *dict, char **volname,
+ char **options, int *option_cnt);
-int glusterd_op_gsync_args_get (dict_t *dict, char **op_errstr,
- char **master, char **slave, char **host_uuid);
+int
+glusterd_op_gsync_args_get(dict_t *dict, char **op_errstr, char **master,
+ char **slave, char **host_uuid);
-int glusterd_op_get_max_opversion (char **op_errstr, dict_t *rsp_dict);
+int
+glusterd_op_get_max_opversion(char **op_errstr, dict_t *rsp_dict);
-int glusterd_start_volume (glusterd_volinfo_t *volinfo, int flags,
- gf_boolean_t wait);
+int
+glusterd_start_volume(glusterd_volinfo_t *volinfo, int flags,
+ gf_boolean_t wait);
-int glusterd_stop_volume (glusterd_volinfo_t *volinfo);
+int
+glusterd_stop_volume(glusterd_volinfo_t *volinfo);
/* Synctask part */
-int32_t glusterd_op_begin_synctask (rpcsvc_request_t *req, glusterd_op_t op,
- void *dict);
int32_t
-glusterd_defrag_event_notify_handle (dict_t *dict);
+glusterd_op_begin_synctask(rpcsvc_request_t *req, glusterd_op_t op, void *dict);
+int32_t
+glusterd_defrag_event_notify_handle(dict_t *dict);
int32_t
-glusterd_txn_opinfo_dict_init ();
+glusterd_txn_opinfo_dict_init();
void
-glusterd_txn_opinfo_dict_fini ();
+glusterd_txn_opinfo_dict_fini();
void
-glusterd_txn_opinfo_init ();
+glusterd_txn_opinfo_init();
/* snapshot */
-glusterd_snap_t*
+glusterd_snap_t *
glusterd_new_snap_object();
int32_t
-glusterd_list_add_snapvol (glusterd_volinfo_t *origin_vol,
- glusterd_volinfo_t *snap_vol);
+glusterd_list_add_snapvol(glusterd_volinfo_t *origin_vol,
+ glusterd_volinfo_t *snap_vol);
-glusterd_snap_t*
-glusterd_remove_snap_by_id (uuid_t snap_id);
+glusterd_snap_t *
+glusterd_remove_snap_by_id(uuid_t snap_id);
-glusterd_snap_t*
-glusterd_remove_snap_by_name (char *snap_name);
+glusterd_snap_t *
+glusterd_remove_snap_by_name(char *snap_name);
-glusterd_snap_t*
-glusterd_find_snap_by_name (char *snap_name);
+glusterd_snap_t *
+glusterd_find_snap_by_name(char *snap_name);
-glusterd_snap_t*
-glusterd_find_snap_by_id (uuid_t snap_id);
+glusterd_snap_t *
+glusterd_find_snap_by_id(uuid_t snap_id);
int
-glusterd_snapshot_prevalidate (dict_t *dict, char **op_errstr,
- dict_t *rsp_dict, uint32_t *op_errno);
+glusterd_snapshot_prevalidate(dict_t *dict, char **op_errstr, dict_t *rsp_dict,
+ uint32_t *op_errno);
int
-glusterd_snapshot_brickop (dict_t *dict, char **op_errstr, dict_t *rsp_dict);
+glusterd_snapshot_brickop(dict_t *dict, char **op_errstr, dict_t *rsp_dict);
int
-glusterd_snapshot (dict_t *dict, char **op_errstr,
- uint32_t *op_errno, dict_t *rsp_dict);
+glusterd_snapshot(dict_t *dict, char **op_errstr, uint32_t *op_errno,
+ dict_t *rsp_dict);
int
-glusterd_snapshot_postvalidate (dict_t *dict, int32_t op_ret, char **op_errstr,
- dict_t *rsp_dict);
+glusterd_snapshot_postvalidate(dict_t *dict, int32_t op_ret, char **op_errstr,
+ dict_t *rsp_dict);
char *
-glusterd_build_snap_device_path (char *device, char *snapname,
- int32_t brick_count);
+glusterd_build_snap_device_path(char *device, char *snapname,
+ int32_t brick_count);
int32_t
-glusterd_snap_remove (dict_t *rsp_dict, glusterd_snap_t *snap,
- gf_boolean_t remove_lvm, gf_boolean_t force,
- gf_boolean_t is_clone);
+glusterd_snap_remove(dict_t *rsp_dict, glusterd_snap_t *snap,
+ gf_boolean_t remove_lvm, gf_boolean_t force,
+ gf_boolean_t is_clone);
int32_t
-glusterd_snapshot_cleanup (dict_t *dict, char **op_errstr, dict_t *rsp_dict);
+glusterd_snapshot_cleanup(dict_t *dict, char **op_errstr, dict_t *rsp_dict);
int32_t
-glusterd_add_missed_snaps_to_list (dict_t *dict, int32_t missed_snap_count);
+glusterd_add_missed_snaps_to_list(dict_t *dict, int32_t missed_snap_count);
int32_t
-glusterd_add_new_entry_to_list (char *missed_info, char *snap_vol_id,
- int32_t brick_num, char *brick_path,
- int32_t snap_op, int32_t snap_status);
+glusterd_add_new_entry_to_list(char *missed_info, char *snap_vol_id,
+ int32_t brick_num, char *brick_path,
+ int32_t snap_op, int32_t snap_status);
int
-glusterd_snapshot_revert_restore_from_snap (glusterd_snap_t *snap);
-
+glusterd_snapshot_revert_restore_from_snap(glusterd_snap_t *snap);
int
-glusterd_add_brick_status_to_dict (dict_t *dict, glusterd_volinfo_t *volinfo,
- glusterd_brickinfo_t *brickinfo,
- char *key_prefix);
+glusterd_add_brick_status_to_dict(dict_t *dict, glusterd_volinfo_t *volinfo,
+ glusterd_brickinfo_t *brickinfo,
+ char *key_prefix);
int32_t
-glusterd_handle_snap_limit (dict_t *dict, dict_t *rsp_dict);
+glusterd_handle_snap_limit(dict_t *dict, dict_t *rsp_dict);
gf_boolean_t
-glusterd_should_i_stop_bitd ();
+glusterd_should_i_stop_bitd();
int
-glusterd_remove_brick_migrate_cbk (glusterd_volinfo_t *volinfo,
- gf_defrag_status_t status);
+glusterd_remove_brick_migrate_cbk(glusterd_volinfo_t *volinfo,
+ gf_defrag_status_t status);
/* tier */
int
-__glusterd_handle_reset_brick (rpcsvc_request_t *req);
-int glusterd_op_stage_tier (dict_t *dict, char **op_errstr, dict_t *rsp_dict);
-int glusterd_op_tier_start_stop (dict_t *dict, char **op_errstr,
- dict_t *rsp_dict);
-int glusterd_op_remove_tier_brick (dict_t *dict, char **op_errstr,
- dict_t *rsp_dict);
+__glusterd_handle_reset_brick(rpcsvc_request_t *req);
+int
+glusterd_op_stage_tier(dict_t *dict, char **op_errstr, dict_t *rsp_dict);
+int
+glusterd_op_tier_start_stop(dict_t *dict, char **op_errstr, dict_t *rsp_dict);
+int
+glusterd_op_remove_tier_brick(dict_t *dict, char **op_errstr, dict_t *rsp_dict);
int
-glusterd_tier_prevalidate (dict_t *dict, char **op_errstr,
- dict_t *rsp_dict, uint32_t *op_errno);
+glusterd_tier_prevalidate(dict_t *dict, char **op_errstr, dict_t *rsp_dict,
+ uint32_t *op_errno);
int
-glusterd_options_init (xlator_t *this);
+glusterd_options_init(xlator_t *this);
#endif