All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH pynfs v1] 4.0 server tests: remove RPLY14
@ 2026-11-02 21:43 Chuck Lever
  2026-11-02 21:45 ` Jeff Layton
  2026-11-03  6:07 ` Frank Filz
  0 siblings, 2 replies; 4+ messages in thread
From: Chuck Lever @ 2026-11-02 21:43 UTC (permalink / raw)
  To: Calum Mackay, Jeff Layton; +Cc: linux-nfs

RPLY14 sends a CREATE, then resends it twice with the same XID on the
same TCP connection and expects NFS4_OK each time. The other RPLY tests
exercise the per-state-owner reply cache that RFC 7530 Section 9.1.7
requires, or replay an idempotent LOOKUP. RPLY14 alone depends on an
XID-based duplicate request cache, which RFC 7530 does not specify.
Section 3.1.1 also forbids an NFSv4.0 client from retrying a request
unless the transport connection has been broken.

A recent NFSD change drops a retransmission that arrives on the
connection that carried the original request, so RPLY14 now fails
against NFSD. Reconnecting before the replay does not rescue the test.
NFSD may evict a DRC entry once the client has acknowledged the cached
reply, so the replayed CREATE executes a second time and fails with
NFS4ERR_EXIST.

Remove RPLY14 and record its code as retired.

Signed-off-by: Chuck Lever <cel@kernel.org>
---
 nfs4.0/servertests/st_replay.py | 12 +-----------
 1 file changed, 1 insertion(+), 11 deletions(-)

diff --git a/nfs4.0/servertests/st_replay.py b/nfs4.0/servertests/st_replay.py
index 48e5363432ec..7f490e3d48c3 100644
--- a/nfs4.0/servertests/st_replay.py
+++ b/nfs4.0/servertests/st_replay.py
@@ -250,14 +250,4 @@ def testOpenConfirmFail(t, env):
     ops += [op.open_confirm(stateid, c.get_seqid(t.word())+1)]
     _replay(env, c, ops, NFS4ERR_BAD_SEQID)
 
-def testMkdirReplay(t, env):
-    """REPLAY a succesful directory CREATE
-
-    FLAGS: replay all
-    DEPEND: MKDIR
-    CODE: RPLY14
-    """
-    c = env.c1
-    c.init_connection()
-    ops = c.go_home() + [op.create(createtype4(NF4DIR), t.word(), {})]
-    _replay(env, c, ops)
+# RPLY14 permanently retired, please do not reuse
-- 
2.56.0


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

* Re: [PATCH pynfs v1] 4.0 server tests: remove RPLY14
  2026-11-02 21:43 [PATCH pynfs v1] 4.0 server tests: remove RPLY14 Chuck Lever
@ 2026-11-02 21:45 ` Jeff Layton
  2026-11-03  6:07 ` Frank Filz
  1 sibling, 0 replies; 4+ messages in thread
From: Jeff Layton @ 2026-11-02 21:45 UTC (permalink / raw)
  To: Chuck Lever, Calum Mackay; +Cc: linux-nfs

On Mon, 2026-11-02 at 16:43 -0500, Chuck Lever wrote:
> RPLY14 sends a CREATE, then resends it twice with the same XID on the
> same TCP connection and expects NFS4_OK each time. The other RPLY tests
> exercise the per-state-owner reply cache that RFC 7530 Section 9.1.7
> requires, or replay an idempotent LOOKUP. RPLY14 alone depends on an
> XID-based duplicate request cache, which RFC 7530 does not specify.
> Section 3.1.1 also forbids an NFSv4.0 client from retrying a request
> unless the transport connection has been broken.
> 
> A recent NFSD change drops a retransmission that arrives on the
> connection that carried the original request, so RPLY14 now fails
> against NFSD. Reconnecting before the replay does not rescue the test.
> NFSD may evict a DRC entry once the client has acknowledged the cached
> reply, so the replayed CREATE executes a second time and fails with
> NFS4ERR_EXIST.
> 
> Remove RPLY14 and record its code as retired.
> 
> Signed-off-by: Chuck Lever <cel@kernel.org>
> ---
>  nfs4.0/servertests/st_replay.py | 12 +-----------
>  1 file changed, 1 insertion(+), 11 deletions(-)
> 
> diff --git a/nfs4.0/servertests/st_replay.py b/nfs4.0/servertests/st_replay.py
> index 48e5363432ec..7f490e3d48c3 100644
> --- a/nfs4.0/servertests/st_replay.py
> +++ b/nfs4.0/servertests/st_replay.py
> @@ -250,14 +250,4 @@ def testOpenConfirmFail(t, env):
>      ops += [op.open_confirm(stateid, c.get_seqid(t.word())+1)]
>      _replay(env, c, ops, NFS4ERR_BAD_SEQID)
>  
> -def testMkdirReplay(t, env):
> -    """REPLAY a succesful directory CREATE
> -
> -    FLAGS: replay all
> -    DEPEND: MKDIR
> -    CODE: RPLY14
> -    """
> -    c = env.c1
> -    c.init_connection()
> -    ops = c.go_home() + [op.create(createtype4(NF4DIR), t.word(), {})]
> -    _replay(env, c, ops)
> +# RPLY14 permanently retired, please do not reuse

Works for me.

Reviewed-by: Jeff Layton <jlayton@kernel.org>

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

* RE: [PATCH pynfs v1] 4.0 server tests: remove RPLY14
  2026-11-02 21:43 [PATCH pynfs v1] 4.0 server tests: remove RPLY14 Chuck Lever
  2026-11-02 21:45 ` Jeff Layton
@ 2026-11-03  6:07 ` Frank Filz
  2026-11-03 13:14   ` Chuck Lever
  1 sibling, 1 reply; 4+ messages in thread
From: Frank Filz @ 2026-11-03  6:07 UTC (permalink / raw)
  To: 'Chuck Lever', 'Calum Mackay',
	'Jeff Layton'
  Cc: linux-nfs

Could we keep this test case but change the flags from "replay all" to
"ganesha"?

NFS-Ganesha still passes this test case.

Thanks

Frank

-----Original Message-----
From: Chuck Lever [mailto:cel@kernel.org] 
Sent: Monday, November 2, 2026 1:44 PM
To: Calum Mackay <calum.mackay@cdmnet.org>; Jeff Layton <jlayton@kernel.org>
Cc: linux-nfs@vger.kernel.org
Subject: [PATCH pynfs v1] 4.0 server tests: remove RPLY14

RPLY14 sends a CREATE, then resends it twice with the same XID on the same
TCP connection and expects NFS4_OK each time. The other RPLY tests exercise
the per-state-owner reply cache that RFC 7530 Section 9.1.7 requires, or
replay an idempotent LOOKUP. RPLY14 alone depends on an XID-based duplicate
request cache, which RFC 7530 does not specify.
Section 3.1.1 also forbids an NFSv4.0 client from retrying a request unless
the transport connection has been broken.

A recent NFSD change drops a retransmission that arrives on the connection
that carried the original request, so RPLY14 now fails against NFSD.
Reconnecting before the replay does not rescue the test.
NFSD may evict a DRC entry once the client has acknowledged the cached
reply, so the replayed CREATE executes a second time and fails with
NFS4ERR_EXIST.

Remove RPLY14 and record its code as retired.

Signed-off-by: Chuck Lever <cel@kernel.org>
---
 nfs4.0/servertests/st_replay.py | 12 +-----------
 1 file changed, 1 insertion(+), 11 deletions(-)

diff --git a/nfs4.0/servertests/st_replay.py
b/nfs4.0/servertests/st_replay.py index 48e5363432ec..7f490e3d48c3 100644
--- a/nfs4.0/servertests/st_replay.py
+++ b/nfs4.0/servertests/st_replay.py
@@ -250,14 +250,4 @@ def testOpenConfirmFail(t, env):
     ops += [op.open_confirm(stateid, c.get_seqid(t.word())+1)]
     _replay(env, c, ops, NFS4ERR_BAD_SEQID)
 
-def testMkdirReplay(t, env):
-    """REPLAY a succesful directory CREATE
-
-    FLAGS: replay all
-    DEPEND: MKDIR
-    CODE: RPLY14
-    """
-    c = env.c1
-    c.init_connection()
-    ops = c.go_home() + [op.create(createtype4(NF4DIR), t.word(), {})]
-    _replay(env, c, ops)
+# RPLY14 permanently retired, please do not reuse
--
2.56.0



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

* Re: [PATCH pynfs v1] 4.0 server tests: remove RPLY14
  2026-11-03  6:07 ` Frank Filz
@ 2026-11-03 13:14   ` Chuck Lever
  0 siblings, 0 replies; 4+ messages in thread
From: Chuck Lever @ 2026-11-03 13:14 UTC (permalink / raw)
  To: Frank Filz, Calum Mackay, Jeff Layton; +Cc: linux-nfs



On Tue, Nov 3, 2026, at 1:07 AM, Frank Filz wrote:
> Could we keep this test case but change the flags from "replay all" to
> "ganesha"?
>
> NFS-Ganesha still passes this test case.

The reason we're not keeping this test is that pynfs is a spec conformance
test suite (at least we're trying to keep it that way). The duplicate
reply cache is not covered by any of the NFS RFCs, so RPLY14 does not
belong in pynfs as written.


-- 
Chuck Lever (Come to NFS bake-a-thon! https://nfsv4bat.org)

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

end of thread, other threads:[~2026-11-03 13:14 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-02 21:43 [PATCH pynfs v1] 4.0 server tests: remove RPLY14 Chuck Lever
2026-11-02 21:45 ` Jeff Layton
2026-11-03  6:07 ` Frank Filz
2026-11-03 13:14   ` Chuck Lever

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.