Bug 2219273 - sometimes NFS 4.2 SEEK operation is skipping holes and treating hole as data in a sparse file
Summary: sometimes NFS 4.2 SEEK operation is skipping holes and treating hole as data ...
Keywords:
Status: NEW
Alias: None
Product: Fedora
Classification: Fedora
Component: kernel
Version: 37
Hardware: Unspecified
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Kernel Maintainer List
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-07-03 07:12 UTC by Mohadeb Mondal
Modified: 2023-07-03 07:21 UTC (History)
16 users (show)

Fixed In Version:
Doc Type: ---
Doc Text:
Clone Of:
Environment:
Last Closed:
Type: ---
Embargoed:


Attachments (Terms of Use)
capture of sparse file creation in NFS 4.2 mount of Fedora 37 server (5.16 MB, application/vnd.tcpdump.pcap)
2023-07-03 07:17 UTC, Mohadeb Mondal
no flags Details
file copy operation in NFS 4.2 mount in Fedora 37 server (11.65 MB, application/vnd.tcpdump.pcap)
2023-07-03 07:21 UTC, Mohadeb Mondal
no flags Details

Description Mohadeb Mondal 2023-07-03 07:12:32 UTC
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.

Comment 1 Mohadeb Mondal 2023-07-03 07:17:36 UTC
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

Comment 2 Mohadeb Mondal 2023-07-03 07:21:06 UTC
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.


Note You need to log in before you can comment on or make changes to this bug.