In my Fedora NFS(4.2) server I have created sparse files.(Attached packet capture). It contains file with (16 KB data followed by 32 KB hole) & (8 KB data followed by 16 KB hole).
After that I have used another Fedora 37 machine as client to do file copy operation using NFS 4.2.(packet capture attached).
In this copy operation it exchanges NFS 4.2 SEEK packet. while the response in most of SEEK operation is as per the size with which the file was created, sometimes, I could see that NFS SEEK response has skipped holes. As a result the next READ operation has more data length.(packet no 499,500,501) (1131,1132,1133) can be checked for this.
Reproducible: Always
Steps to Reproduce:
1. Create two exports in a NFS 4.2 server in Fedora 37.
2.Created a sparse file which contains 16KB data followed by 32KB Hole multiple times in one of the exports.
3.Then mount both exports using NFS 4.2.
4.Start packet capture at server/client and copy file from one export to the other.
5.Check the packet capture for SEEK response and next NFS READ size.
Actual Results:
It will be visible that few holes are skipped.
Expected Results:
It should not skip holes sometimes and report correct data in SEEK response.
Created attachment 1973828[details]
capture of sparse file creation in NFS 4.2 mount of Fedora 37 server
capture of sparse file creation in NFS 4.2 mount of Fedora 37 server.
10.52.72.77 is the NFS 4.2 Fedora 37 server
Kernel version 6.1.6-200.fc37.x86_64
Created attachment 1973829[details]
file copy operation in NFS 4.2 mount in Fedora 37 server
file copy operation in NFS 4.2 mount in Fedora 37 server.
10.52.72.77 is the server. 10.52.72.106 is the client
(packet no 499,500,501) (1131,1132,1133) can be checked. Multiple similar packet is present later.