diff options
author | Sachin Pandit <spandit@redhat.com> | 2014-12-19 03:54:45 +0530 |
---|---|---|
committer | Raghavendra Bhat <raghavendra@redhat.com> | 2014-12-24 03:38:51 -0800 |
commit | f47c24d518d1b10bca04a16737dab88bba53a07e (patch) | |
tree | baac60e5dffb68b02a6265c774fe33e09d071caa /xlators/features/snapview-server/src | |
parent | 9f0589646b4932b33ac0a913b1a23d8f279faf2b (diff) |
gluster/uss: Handle ESTALE in snapview client when NFS server restarted
When NFS server is restarted inode-context is lost.
Nameless lookup will be sent to regular volume.
If the gfid is from virtual graph, lookup will fail
with ESTALE. We need to send a lookup to snapview server
Change-Id: I22920614f0d14cb90b53653fce95b6b70023eba6
BUG: 1175736
Signed-off-by: vmallika <vmallika@redhat.com>
Reviewed-on: http://review.gluster.org/9153
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Sachin Pandit <spandit@redhat.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Signed-off-by: Sachin Pandit <spandit@redhat.com>
Reviewed-on: http://review.gluster.org/9309
Reviewed-by: Raghavendra Bhat <raghavendra@redhat.com>
Diffstat (limited to 'xlators/features/snapview-server/src')
-rw-r--r-- | xlators/features/snapview-server/src/snapview-server.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/xlators/features/snapview-server/src/snapview-server.c b/xlators/features/snapview-server/src/snapview-server.c index 6c65497b34c..d66150e769a 100644 --- a/xlators/features/snapview-server/src/snapview-server.c +++ b/xlators/features/snapview-server/src/snapview-server.c @@ -536,6 +536,14 @@ svs_lookup (call_frame_t *frame, xlator_t *this, loc_t *loc, dict_t *xdata) fs = svs_initialise_snapshot_volume (this, dirent->name, NULL); } + if (inode_ctx && inode_ctx->type == SNAP_VIEW_ENTRY_POINT_INODE) { + /* entry-point may not be set in the dictonary. + * This can happen if snap-view client is restarted where + * inode-ctx not available and a nameless lookup has come + */ + entry_point = _gf_true; + } + /* lookup is on the entry point to the snapshot world */ if (entry_point) { op_ret = svs_lookup_entry_point (this, loc, parent, &buf, |