Bug 508174

Summary: RHL 9 (i.e., old) nfs client can no longer do seeks for nfs mounted files on server running kernel-PAE-
Product: [Fedora] Fedora Reporter: Dale Stimson <ml-bz-dale>
Component: kernelAssignee: Kernel Maintainer List <kernel-maint>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: low Docs Contact:
Priority: low    
Version: 11CC: csimpson, dshaw, itamar, kernel-maint, ml-bz-dale, quintela
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: i386   
OS: Linux   
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2009-07-22 17:58:30 EDT Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Description Dale Stimson 2009-06-25 18:00:55 EDT
Description of problem:

Red Hat Linux 9 nfs client can no longer do seeks for nfs mounted files on server running kernel-PAE-

Problem occurs with update kernel:
    kernel-PAE- .
Problem does not occur with original F11 kernel:

Presumably this problem is still relevant, even if one of the systems involved is very old, as one imagines that a valid nfs call is not being properly handled by the new kernel.

I have a Fedora 11 system (with full updates) acting as an NFS server.  I have a separate system running Red Hat Linux 9 (for various backwards compatibility building and testing reasons) that is an nfs client of the aforementioned server (using autofs for auto-mounting).

On the nfs client, *with current working directory set to a directory under the nfs mount*, an attempted compilation results in something like:

    $ gcc -c hw.c
    hw.o: Input/output error
    /usr/tmp/cckOXVqu.s: Assembler messages:
    /usr/tmp/cckOXVqu.s:25: FATAL: Can't write hw.o: Illegal seek

Sometimes it complains about "Illegal seek" and sometimes about "Input/Output error", although I believe the problem is wholly seek-related.

The following command reveals that the program actually issuing the diagnostic is "as":
    $ gcc -c -v -save-temps hw.c
    as -V -Qy -o hw.o hw.s
    GNU assembler version (i386-redhat-linux) using BFD version 20030206
    hw.o: Input/output error
    hw.s: Assembler messages:
    hw.s:25: FATAL: Can't write hw.o: Input/output error

Presumably, the assembler attempts to seek within the output object file and fails.

I have worked around this problem for my own sake using a script to wrap the "as" command, substituting a tmp file on a local disk for the original output file on the nfs filesystem and then mv'ing the local file into the desired output file after assembly completes.  This workaround works reliably, again suggesting that the problem is related to the attempted seek on the nfs file.

How reproducible:

Always fails under kernel-PAE- .

Always works under the previous kernel:

Steps to Reproduce:
1.  Fedora 11 server running kernel-PAE-
2.  RHL 9 client, autofs for auto-mount of nfs file system from server.
3.  Set current working directory to be on the nfs filesystem.
3.  Attempt compilation of a .c file using gcc
Comment 1 Dale Stimson 2009-06-26 20:53:10 EDT
This problem is also seen for the output file of ld (not just "as").

(By the way, for what it's worth, the (client) RHL 9 kernel is 2.4.20-43.9.legacy.)

This problem goes away from Fedora kernel-PAE- when that kernel is rebuilt without patch linux-2.6-nfsd-report-short-writes.patch .

Perhaps the patch is OK and the old kernel on the client is not handling things properly.  I'll ask about this on the linux-nfs list.
Comment 2 Dale Stimson 2009-06-30 11:31:46 EDT
J. Bruce Fields on linux-nfs@vger.kernel.org diagnosed this problem and suggested that I try patch

"nfsd: fix hung up of nfs client while sync write data to nfs server"

This patch fixes a problem with the short write patch (linux-2.6-nfsd-report-short-writes.patch).

Both of these patches are upstream in 2.26.30.  Only the short write patch is in Fedora 11 kernel-

Suggestion: Future Fedora kernels based on 2.6.29 should also include the second patch "nfsd: fix hung".

Once that is done (or once Fedora 11 kernels are based on 2.6.30) I would consider this bug closable.
Comment 3 Chuck Ebbert 2009-06-30 15:32:45 EDT
Fixed in
Comment 4 Jeff Layton 2009-07-02 06:49:52 EDT
*** Bug 508873 has been marked as a duplicate of this bug. ***
Comment 5 Dale Stimson 2009-07-02 10:38:49 EDT
Successfully tested with from

Marking this bug as closed.
Comment 6 Dale Stimson 2009-07-02 11:03:40 EDT
My apologies and sorry to cause a ping all the listeners of this bug again.

Upon reviewing
I see that I, as the bug submitter, should not have marked this bug as CLOSED (it should still be MODIFIED state) until an update was released and further that NEXTRELEASE does not mean what I thought it did.

Accordingly, since I'm not permitted to reclassify this bug as other than CLOSED or ASSIGNED, I guess the best thing for me to do is to change it back to ASSIGNED.

Again, sorry about that.
Comment 7 Fedora Update System 2009-07-08 08:13:54 EDT
kernel- has been submitted as an update for Fedora 11.
Comment 8 Fedora Update System 2009-07-16 03:12:51 EDT
kernel- has been pushed to the Fedora 11 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update kernel'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F11/FEDORA-2009-7617
Comment 9 Fedora Update System 2009-07-22 17:57:32 EDT
kernel- has been pushed to the Fedora 11 stable repository.  If problems still persist, please make note of it in this bug report.