Bug 1397289

Summary: NFSv3 downloads never complete
Product: [Fedora] Fedora Reporter: Yaakov Selkowitz <yselkowi>
Component: libnfsAssignee: Ross Lagerwall <ross>
Status: CLOSED UPSTREAM QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 25CC: alexl, oholy, ross
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-11-23 07:26:42 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Yaakov Selkowitz 2016-11-22 08:03:20 UTC
Description of problem:
With gvfs-nfs connected to a unfsd (NFSv3 userspace daemon) instance, I can browse/ls directories but any operations involving file content (gvfs-cat, gvfs-copy, or opening the file in a GIO-capable application such as gedit or eog) never end.  However, nfs-cat and nfs-cp (from libnfs-utils, the same library used by gvfs-nfs) operations work fine, leading me to believe the issue is with neither the server nor libnfs.


Version-Release number of selected component (if applicable):
gvfs-nfs-1.28.3-1.fc24.x86_64 (and -1.30.1.1-1.fc25.x86_64)
libnfs-1.9.8-2.fc24.x86_64


How reproducible:
100% with this configuration.


Steps to Reproduce:
1. gvfs-mount a unfsd-based mount
2. gvfs-ls that mount
3. gvfs-cat or gvfs-copy a file therein


Actual results:
The download never ends.  For example with gvfs-copy -p, I see messages such as:

Transferred 6.2 kB out of 1.5 kB (46 bytes/s)

or with evince, the download in progress statusbar shows thousands of percent, and it never seems to stop counting.


Expected results:
The download completes, as with libnfs-utils.

Comment 3 Ondrej Holy 2016-11-22 12:28:52 UTC
I can reproduce it with unfsd. It stuck at the end of file and still reads 4 bytes of same data and never ends...

nfs-cat uses nfs_pread and call it until offset < size, gvfs uses nfs_read_async and expects that 0 is returned at the end of file, but it isn't returned, 4 is returned...

I can't reproduce it with exportfs. It sounds like bug in lower levels of libnfs, or unfsd bug. Result from rpc_nfs3_read_async seems to be wrong...

Can you please file bug report for libnfs upstream?
https://github.com/sahlberg/libnfs/issues

Comment 4 Yaakov Selkowitz 2016-11-22 16:19:25 UTC
Filed: https://github.com/sahlberg/libnfs/issues/157

Comment 5 Yaakov Selkowitz 2016-11-22 21:39:21 UTC
And with unfs3: https://sourceforge.net/p/unfs3/bugs/9/

Comment 6 Ondrej Holy 2016-11-23 07:26:42 UTC
Thanks! So, it is probably unfs3 bug and unfs3 seems not to be in our repositories, so closing...