From: Sachin Prabhu <sprabhu@redhat.com>
To: linux-nfs <linux-nfs@vger.kernel.org>
Subject: NFS4 clients cannot reclaim locks
Date: Fri, 1 Oct 2010 07:30:48 -0400 (EDT) [thread overview]
Message-ID: <25362267.86.1285932646433.JavaMail.sprabhu@dhcp-1-233.fab.redhat.com> (raw)
In-Reply-To: <8181361.84.1285932468389.JavaMail.sprabhu@dhcp-1-233.fab.redhat.com>
NFS4 clients appear to have problems reclaiming locks after a server reboot. I can recreate the issue on 2.6.34.7-56.fc13.x86_64 on a Fedora system.
The problem appears to happen in cases where after a reboot, a WRITE call is made just before the RENEW call. In that case, the NFS4ERR_STALE_STATEID is returned for the WRITE call which results in NFS_STATE_RECLAIM_REBOOT being set in the state flags. However the NFS4ERR_STALE_CLIENTID returned for the subsequent RENEW call is handled by
nfs4_recovery_handle_error() -> nfs4_state_end_reclaim_reboot(clp);
which ends up setting the state flag to NFS_STATE_RECLAIM_NOGRACE and clearing the NFS_STATE_RECLAIM_REBOOT in nfs4_state_mark_reclaim_nograce().
The process of reclaiming the locks then seem to hit another roadblock in nfs4_open_expired() where it fails to open the file and reset the state. It ends up calling nfs4_reclaim_locks() in a loop with the old stateid in nfs4_reclaim_open_state().
By commenting out the call to nfs4_state_end_reclaim_reboot(clp) in nfs4_recovery_handle_error(), the client was able to handle this particular scenario properly.
Has any one else seen this issue?
Sachin Prabhu
next parent reply other threads:[~2010-10-01 11:30 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <8181361.84.1285932468389.JavaMail.sprabhu@dhcp-1-233.fab.redhat.com>
2010-10-01 11:30 ` Sachin Prabhu [this message]
2010-10-01 20:46 ` NFS4 clients cannot reclaim locks Trond Myklebust
2010-10-05 15:03 ` Timo Aaltonen
2010-11-22 16:02 ` Timo Aaltonen
[not found] <18163799.104.1286186355944.JavaMail.sprabhu@dhcp-1-233.fab.redhat.com>
2010-10-04 10:03 ` Sachin Prabhu
2010-10-05 13:37 ` Trond Myklebust
2010-10-06 15:59 ` Sachin Prabhu
2010-10-05 13:38 ` Trond Myklebust
[not found] <18697573.14.1286380841649.JavaMail.sprabhu@dhcp-1-233.fab.redhat.com>
2010-10-06 16:01 ` Sachin Prabhu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=25362267.86.1285932646433.JavaMail.sprabhu@dhcp-1-233.fab.redhat.com \
--to=sprabhu@redhat.com \
--cc=linux-nfs@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).