Bug 800681

Summary: NFSv4 Fix the handling of a revoked or bad delegation stateid
Product: Red Hat Enterprise Linux 6 Reporter: Andy Adamson <andros>
Component: kernelAssignee: nfs-maint
Status: CLOSED DUPLICATE QA Contact: Red Hat Kernel QE team <kernel-qe>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.3CC: acase, jlayton, steved, syeghiay
Target Milestone: rc   
Target Release: 6.4   
Hardware: Unspecified   
OS: Linux   
Whiteboard: NFSv4
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-10-12 10:06:02 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Andy Adamson 2012-03-06 22:58:12 UTC
Description of problem:

If we know that the delegation stateid is bad or revoked, we need to
remove that delegation as soon as possible, and then mark all the
stateids that relied on that delegation for recovery. We cannot use
the delegation as part of the recovery process.


Version-Release number of selected component (if applicable):


How reproducible:
100% with the ability for the admin to revoke a stateid on the NFSv4.0/v4.1 server


Steps to Reproduce:
1. Open a file with a delegation
2. Perform I/O - READ the file
3. During I/O revoke the delegation stated
  
Actual results:
A READ will return with NFS4ERR_BAD_STATEID. The client will start the recovery process, but it will not complete.  Either the client will hang, or the READ will be resent with the revoked stateid, and the application will see an input/output error.

Expected results:
With this patch, the (possibly a delegation) stateid is recovered via an OPEN with CLAIM_NULL, the READ is resent with the new stateid and all is well.

Additional info:

Here is the upstream patch queued for stable:

From a1d0b5eebc4fd6e0edb02688b35f17f67f42aea5 Mon Sep 17 00:00:00 2001
From: Trond Myklebust <Trond.Myklebust>
Date: Mon, 5 Mar 2012 19:56:44 -0500
Subject: [PATCH] NFS: Properly handle the case where the delegation is
 revoked

Comment 2 RHEL Program Management 2012-05-03 05:19:13 UTC
Since RHEL 6.3 External Beta has begun, and this bug remains
unresolved, it has been rejected as it is not proposed as
exception or blocker.

Red Hat invites you to ask your support representative to
propose this request, if appropriate and relevant, in the
next release of Red Hat Enterprise Linux.

Comment 3 Jeff Layton 2012-10-12 10:06:02 UTC

*** This bug has been marked as a duplicate of bug 842435 ***