linux-nfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH Version 2 0/3] NFS filelayout fix a GETDEVINO hang`
@ 2017-03-20 22:06 andros
  2017-03-20 22:07 ` [PATCH Version 2 1/3] NFS cleanup struct nfs4_filelayout_segment andros
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: andros @ 2017-03-20 22:06 UTC (permalink / raw)
  To: trondmy; +Cc: linux-nfs, Andy Adamson

From: Andy Adamson <andros@netapp.com>

NOTE: this change can result in two GETDEVINFO calls on the wire to
resolve a layout deviceid when there are multiple async I/O calls as
the initial nfs4_find_get_deviceid() GETDEVINFO call may not have
returned and inserted the new deviceid prior to a subsequent
nfs4_find_get_deviceid() searches for the deviceid.

Fix a filelayout GETDEVICEINFO call hang triggered from the LAYOUTGET
pnfs_layout_process where the GETDEVICEINFO call is waiting for a
session slot, and the LAYOUGET call is waiting for pnfs_layout_process
to complete before freeing the slot GETDEVICEINFO is waiting for..

This occurs in testing against the pynfs pNFS server where the
the on-wire reply highest_slotid and slot id are zero, and the
target high slot id is 8 (negotiated in CREATE_SESSION).

The internal fore channel slot table max_slotid, the maximum allowed
table slotid value, has been reduced via nfs41_set_max_slotid_locked
 from 8 to 1.  Thus there is one slot (slotid 0) available for use but
it has not been freed by LAYOUTGET  proir to the GETDEVICEINFO request.

In order to ensure that layoutrecall callbacks are processed in the
correct order, nfs4_proc_layoutget processing needs to be finished
e.g. pnfs_layout_process) before giving up the slot that identifies
the layoutget (see referring_call_exists).

Move the filelayout_check_layout nfs4_find_get_device call outside of
the pnfs_layout_process call tree.


Andy Adamson (3):
  NFS cleanup struct nfs4_filelayout_segment
  NFS store nfs4_deviceid in struct nfs4_filelayout_segment
  NFS filelayout:call GETDEVICEINFO after pnfs_layout_process completes

 fs/nfs/filelayout/filelayout.c | 149 ++++++++++++++++++++++++++---------------
 fs/nfs/filelayout/filelayout.h |  19 +++---
 2 files changed, 105 insertions(+), 63 deletions(-)

-- 
1.8.3.1


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2017-03-20 22:07 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-03-20 22:06 [PATCH Version 2 0/3] NFS filelayout fix a GETDEVINO hang` andros
2017-03-20 22:07 ` [PATCH Version 2 1/3] NFS cleanup struct nfs4_filelayout_segment andros
2017-03-20 22:07 ` [PATCH Version 2 2/3] NFS store nfs4_deviceid in " andros
2017-03-20 22:07 ` [PATCH Version 2 3/3] NFS filelayout:call GETDEVICEINFO after pnfs_layout_process completes andros

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).