]> git.baikalelectronics.ru Git - kernel.git/commit
NFS4: Fix v4.0 client state corruption when mount
authorZhangXiaoxu <zhangxiaoxu5@huawei.com>
Mon, 6 May 2019 03:57:03 +0000 (11:57 +0800)
committerAnna Schumaker <Anna.Schumaker@Netapp.com>
Thu, 9 May 2019 20:26:05 +0000 (16:26 -0400)
commit7393ea5adc4790b3e015e4d7f0e48f5c54daa4d3
tree3226baca94a8477bf7b9e7a66b18aaff1d51a318
parent3b98377158ab43cad7121e151a02adaf7a29cec4
NFS4: Fix v4.0 client state corruption when mount

stat command with soft mount never return after server is stopped.

When alloc a new client, the state of the client will be set to
NFS4CLNT_LEASE_EXPIRED.

When the server is stopped, the state manager will work, and accord
the state to recover. But the state is NFS4CLNT_LEASE_EXPIRED, it
will drain the slot table and lead other task to wait queue, until
the client recovered. Then the stat command is hung.

When discover server trunking, the client will renew the lease,
but check the client state, it lead the client state corruption.

So, we need to call state manager to recover it when detect server
ip trunking.

Signed-off-by: ZhangXiaoxu <zhangxiaoxu5@huawei.com>
Cc: stable@vger.kernel.org
Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
fs/nfs/nfs4state.c