diff options
Diffstat (limited to 'libglusterfs/src')
| -rw-r--r-- | libglusterfs/src/glusterfs.h | 1 | ||||
| -rw-r--r-- | libglusterfs/src/graph.c | 25 | 
2 files changed, 26 insertions, 0 deletions
diff --git a/libglusterfs/src/glusterfs.h b/libglusterfs/src/glusterfs.h index 70df63eebbc..93d7260cbe9 100644 --- a/libglusterfs/src/glusterfs.h +++ b/libglusterfs/src/glusterfs.h @@ -453,6 +453,7 @@ struct _glusterfs_ctx {          void               *listener; /* listener of the commands from glusterd */          unsigned char       measure_latency; /* toggle switch for latency measurement */          pthread_t           sigwaiter; +	char               *cmdlinestr;          struct mem_pool    *stub_mem_pool;          unsigned char       cleanup_started;          int                 graph_id; /* Incremented per graph, value should diff --git a/libglusterfs/src/graph.c b/libglusterfs/src/graph.c index b4eddd826f6..52e79ab68cd 100644 --- a/libglusterfs/src/graph.c +++ b/libglusterfs/src/graph.c @@ -196,6 +196,21 @@ glusterfs_graph_worm (glusterfs_graph_t *graph, glusterfs_ctx_t *ctx)          return ret;  } + +int +glusterfs_graph_meta (glusterfs_graph_t *graph, glusterfs_ctx_t *ctx) +{ +        int ret = 0; + +	if (!ctx->master) +		return 0; + +        ret = glusterfs_graph_insert (graph, ctx, "meta", +                                      "meta-autoload", 1); +        return ret; +} + +  int  glusterfs_graph_mac_compat (glusterfs_graph_t *graph, glusterfs_ctx_t *ctx)  { @@ -464,6 +479,14 @@ glusterfs_graph_prepare (glusterfs_graph_t *graph, glusterfs_ctx_t *ctx)                  return -1;          } +	/* XXX: topmost xlator */ +	ret = glusterfs_graph_meta (graph, ctx); +	if (ret) { +		gf_log ("graph", GF_LOG_ERROR, +			"glusterfs graph meta failed"); +		return -1; +	} +          /* XXX: this->ctx setting */          for (trav = graph->first; trav; trav = trav->next) {                  trav->ctx = ctx; @@ -671,6 +694,8 @@ glusterfs_volfile_reconfigure (int oldvollen, FILE *newvolfile_fp,                  goto out;          } +	glusterfs_graph_prepare (newvolfile_graph, ctx); +          if (!is_graph_topology_equal (oldvolfile_graph,                                        newvolfile_graph)) {  | 
