Skip to content

Commit

Permalink
NFSv4.1 send layoutreturn to fence disconnected data server
Browse files Browse the repository at this point in the history
Let the MDS know that you are redirecting I/O from pNFS to MDS.

Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
  • Loading branch information
androsadamson authored and Trond Myklebust committed May 19, 2012
1 parent 671fb89 commit 0a57cda
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions fs/nfs/nfs4filelayout.c
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,8 @@ static int filelayout_async_handle_error(struct rpc_task *task,
case -EPIPE:
dprintk("%s DS connection error %d\n", __func__,
task->tk_status);
if (!filelayout_test_devid_invalid(devid))
_pnfs_return_layout(state->inode);
filelayout_mark_devid_invalid(devid);
rpc_wake_up(&tbl->slot_tbl_waitq);
/* fall through */
Expand Down
1 change: 1 addition & 0 deletions fs/nfs/pnfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -692,6 +692,7 @@ _pnfs_return_layout(struct inode *ino)
dprintk("<-- %s status: %d\n", __func__, status);
return status;
}
EXPORT_SYMBOL_GPL(_pnfs_return_layout);

bool pnfs_roc(struct inode *ino)
{
Expand Down

0 comments on commit 0a57cda

Please sign in to comment.