Bug 109918 - kio-nfs - doesn't work with linux TCP based NFS servers
Summary: kio-nfs - doesn't work with linux TCP based NFS servers
Status: RESOLVED WORKSFORME
Alias: None
Product: kio-extras
Classification: Frameworks and Libraries
Component: NFS (show other bugs)
Version: 18.04.3
Platform: Gentoo Packages Linux
: NOR normal
Target Milestone: ---
Assignee: Alexander Neundorf
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-07-31 02:11 UTC by Andrew de Quincey
Modified: 2021-03-08 04:33 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Andrew de Quincey 2005-07-31 02:11:21 UTC
Version:            (using KDE KDE 3.4.1)
Installed from:    Gentoo Packages
Compiler:          gcc 3.4.4 
OS:                Linux

If I use nfs:// to browse a TCP NFS file server, copying files TO the server larger than a certain length fails - it'll definitely happen with > 20k files. Other operations work fine.

The server reports: RPC: bad TCP reclen 0x00000f9c (non-terminal) in dmesg.

This is because the linux sunrpc implementation is incomplete and cannot handle fragmented sunrpc requests. If you look at the relevant code in net/sunrpc/svcsock.c/svc_tcp_recvfrom() in a recent kernel, you see the following:
			/* FIXME: technically, a record can be fragmented,
			 *  and non-terminal fragments will not have the top
			 *  bit set in the fragment length header.
			 *  But apparently no known nfs clients send fragmented
			 *  records. */

I can't figure out why KDE/glibc's sunrpc client implementation is sending fragmented records and I don't have the time to fix the kernel sunrpc implementation.

A simple "fix" would be to disable TCP NFS support from kio_nfs completely, and rely on UDP only (UDP works fine BTW). But obviously this isn't great :(

I'm using glibc 2.3.5 BTW.
Comment 1 Carsten Lohrke 2006-09-08 20:27:09 UTC
I'm not familiar with nfs, but it looks like someone simply copied the showmount(8) code from nfs-utils, not the connection code.

In mnt_openclnt (conn.c in recent nfs-utils) 2048/1024 bytes for send/receive are used.
Comment 2 Anthony Messina 2013-04-22 11:59:17 UTC
This is an old bug, but I can confirm that kio_nfs is a complete failure in TCP-based NFSv4 or NFSv4.1 environments.  In addition, enabling Nepomuk services presents a "Documents" entry in Dolphin which seems to rely on kio_nfs udp so it is now worthless with the following errors in .xsession-errors:

mount clntudp_create: RPC: Port mapper failure - RPC: Unable to receive
kio_nfs(3981)/kio (kioslave) KIO::SlaveBase::error: error() called twice! Please fix the KIO slave.
Comment 3 Alexander Lüdtke 2014-02-06 14:44:13 UTC
Guess this bug still exists, on my NFS client machines, programs (like Okular, Dolphin and so on) are freezing (from time to time) for some minutes until I can go on to use them. I just compiled a little example from the kde.org page what only opens a file - even that is freezing.
Comment 4 Jonathan Marten 2021-02-06 09:52:01 UTC
Bug reported a long time ago, not sure whether the kernel has been fixed in the meantime but the quoted comment is no longer present.  Please test with an up to date setup if possible.
Comment 5 Bug Janitor Service 2021-02-21 04:33:10 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least
15 days. Please provide the requested information as soon as
possible and set the bug status as REPORTED. Due to regular bug
tracker maintenance, if the bug is still in NEEDSINFO status with
no change in 30 days the bug will be closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please
mark the bug as REPORTED so that the KDE team knows that the bug is
ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 6 Bug Janitor Service 2021-03-08 04:33:33 UTC
This bug has been in NEEDSINFO status with no change for at least
30 days. The bug is now closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

Thank you for helping us make KDE software even better for everyone!