diff options
| author | Krishnan Parthasarathi <kp@gluster.com> | 2012-02-22 19:38:14 +0530 | 
|---|---|---|
| committer | Vijay Bellur <vijay@gluster.com> | 2012-02-23 01:57:19 -0800 | 
| commit | d4ff4103e09ba076653aa6f0774269c47cc931f2 (patch) | |
| tree | d27188fb30644a42af18e3b3ee8d70c692bee757 | |
| parent | 5842656feba99a239b922f8099fb336c66b61929 (diff) | |
glusterd: Modified server graph to have index xl above pump
Index xlator needs a resolved inode in the incoming xattrop request to perform
its indexing. In the case of replace-brick pump xlator doesn't resolve the
inode in the (fop) requests it sends 'downwards', leading to null gfid sent to
index xlator.
Change-Id: I6b6e7af4354670616bf342292df1a25c219dd9e9
BUG: 796171
Signed-off-by: Krishnan Parthasarathi <kp@gluster.com>
Reviewed-on: http://review.gluster.com/2801
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Pranith Kumar Karampuri <pranithk@gluster.com>
| -rw-r--r-- | xlators/mgmt/glusterd/src/glusterd-volgen.c | 36 | 
1 files changed, 18 insertions, 18 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-volgen.c b/xlators/mgmt/glusterd/src/glusterd-volgen.c index bc856bebfaf..f15f57edc22 100644 --- a/xlators/mgmt/glusterd/src/glusterd-volgen.c +++ b/xlators/mgmt/glusterd/src/glusterd-volgen.c @@ -1614,24 +1614,6 @@ server_graph_builder (volgen_graph_t *graph, glusterd_volinfo_t *volinfo,          if (ret)                  return -1; -        if (glusterd_is_volume_replicate (volinfo)) { -                xl = volgen_graph_add (graph, "features/index", volname); -                if (!xl) -                        return -1; - -                snprintf (index_basepath, sizeof (index_basepath), "%s/%s", -                          path, ".glusterfs/indices"); -                ret = xlator_set_option (xl, "index-base", index_basepath); -                if (ret) -                        return -1; - -                ret = check_and_add_debug_xl (graph, set_dict, volname, -                                              "index"); -                if (ret) -                        return -1; - -        } -          ret = dict_get_int32 (volinfo->dict, "enable-pump", &pump);          if (ret == -ENOENT)                  ret = pump = 0; @@ -1682,6 +1664,24 @@ server_graph_builder (volgen_graph_t *graph, glusterd_volinfo_t *volinfo,                          return -1;          } +        if (glusterd_is_volume_replicate (volinfo)) { +                xl = volgen_graph_add (graph, "features/index", volname); +                if (!xl) +                        return -1; + +                snprintf (index_basepath, sizeof (index_basepath), "%s/%s", +                          path, ".glusterfs/indices"); +                ret = xlator_set_option (xl, "index-base", index_basepath); +                if (ret) +                        return -1; + +                ret = check_and_add_debug_xl (graph, set_dict, volname, +                                              "index"); +                if (ret) +                        return -1; + +        } +          xl = volgen_graph_add (graph, "features/marker", volname);          if (!xl)                  return -1;  | 
