linux_dsm_epyc7002/fs/nfs/blocklayout
Benjamin Coddington b3dce6a2f0 pnfs/blocklayout: handle transient devices
PNFS block/SCSI layouts should gracefully handle cases where block devices
are not available when a layout is retrieved, or the block devices are
removed while the client holds a layout.

While setting up a layout segment, keep a record of an unavailable or
un-parsable block device in cache with a flag so that subsequent layouts do
not spam the server with GETDEVINFO.  We can reuse the current
NFS_DEVICEID_UNAVAILABLE handling with one variation: instead of reusing
the device, we will discard it and send a fresh GETDEVINFO after the
timeout, since the lookup and validation of the device occurs within the
GETDEVINFO response handling.

A lookup of a layout segment that references an unavailable device will
return a segment with the NFS_LSEG_UNAVAILABLE flag set.  This will allow
the pgio layer to mark the layout with the appropriate fail bit, which
forces subsequent IO to the MDS, and prevents spamming the server with
LAYOUTGET, LAYOUTRETURN.

Finally, when IO to a block device fails, look up the block device(s)
referenced by the pgio header, and mark them as unavailable.

Signed-off-by: Benjamin Coddington <bcodding@redhat.com>
Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
2018-01-14 23:06:29 -05:00
..
blocklayout.c pnfs/blocklayout: handle transient devices 2018-01-14 23:06:29 -05:00
blocklayout.h pnfs/blocklayout: update last_write_offset atomically with extents 2016-08-23 11:41:38 -04:00
dev.c pnfs/blocklayout: handle transient devices 2018-01-14 23:06:29 -05:00
extent_tree.c License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
Makefile pnfs/blocklayout: in-kernel GETDEVICEINFO XDR parsing 2014-09-12 13:33:50 -04:00
rpc_pipefs.c nfs/blocklayout: add SCSI layout support 2016-03-18 11:38:17 -04:00