Commit 6553498
nfsd: Don't reset the write verifier on a commit EAGAIN
[ Upstream commit 1b2021b ]
If fsync() is returning EAGAIN, then we can assume that the filesystem
being exported is something like NFS with the 'softerr' mount option
enabled, and that it is just asking us to replay the fsync() operation
at a later date.
If we see an ESTALE, then ditto: the file is gone, so there is no danger
of losing the error.
For those cases, do not reset the write verifier. A write verifier
change has a global effect, causing retransmission by all clients of
all uncommitted unstable writes for all files, so it is worth
mitigating where possible.
Link: https://lore.kernel.org/linux-nfs/20230911184357.11739-1-trond.myklebust@hammerspace.com/
Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
Reviewed-by: Jeff Layton <jlayton@kernel.org>
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Stable-dep-of: 2090b05 ("nfsd: reset write verifier on deferred writeback errors")
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>1 parent eeabb90 commit 6553498
1 file changed
Lines changed: 23 additions & 10 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
338 | 338 | | |
339 | 339 | | |
340 | 340 | | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
| 344 | + | |
| 345 | + | |
| 346 | + | |
| 347 | + | |
| 348 | + | |
| 349 | + | |
| 350 | + | |
| 351 | + | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
341 | 359 | | |
342 | 360 | | |
343 | 361 | | |
| |||
659 | 677 | | |
660 | 678 | | |
661 | 679 | | |
662 | | - | |
663 | | - | |
| 680 | + | |
664 | 681 | | |
665 | 682 | | |
666 | 683 | | |
| |||
1177 | 1194 | | |
1178 | 1195 | | |
1179 | 1196 | | |
1180 | | - | |
1181 | | - | |
| 1197 | + | |
1182 | 1198 | | |
1183 | 1199 | | |
1184 | 1200 | | |
| |||
1193 | 1209 | | |
1194 | 1210 | | |
1195 | 1211 | | |
1196 | | - | |
1197 | | - | |
1198 | | - | |
1199 | | - | |
| 1212 | + | |
| 1213 | + | |
1200 | 1214 | | |
1201 | 1215 | | |
1202 | 1216 | | |
| |||
1343 | 1357 | | |
1344 | 1358 | | |
1345 | 1359 | | |
1346 | | - | |
1347 | | - | |
| 1360 | + | |
1348 | 1361 | | |
1349 | 1362 | | |
1350 | 1363 | | |
| |||
0 commit comments