[beta patch] NFS over TCP

G. Allen Morris III (gam3@dharma.sehda.com)
Sat, 02 Jan 1999 10:49:06 -0800


When I was trying to write `large' files over TCP NFS I was
getting `bad TCP reclen' errors.

The patch below gets rid of that problem.
------------------ patch ---------------------
diff -u linux-2.2.0-pre2/net/sunrpc/svcsock.c linux/net/sunrpc/svcsock.c
--- linux-2.2.0-pre2/net/sunrpc/svcsock.c Thu Nov 12 08:33:29 1998
+++ linux/net/sunrpc/svcsock.c Sat Jan 2 10:34:15 1999
@@ -635,8 +635,11 @@
if (len < svsk->sk_reclen) {
dprintk("svc: incomplete TCP record (%d of %ld)\n",
len, svsk->sk_reclen);
+#if 0
svc_sock_received(svsk, ready);
+#endif
len = -EAGAIN; /* record not complete */
+ goto error;
}

/* Frob argbuf */
diff -u linux-2.2.0-pre2/fs/nfsd/nfssvc.c linux/fs/nfsd/nfssvc.c
--- linux-2.2.0-pre2/fs/nfsd/nfssvc.c Fri Jan 1 23:03:09 1999
+++ linux/fs/nfsd/nfssvc.c Fri Jan 1 22:57:41 1999
@@ -76,7 +76,7 @@
if (error < 0)
goto failure;

-#if 0 /* Don't even pretend that TCP works. It doesn't. */
+#if 1 /* Pretend that TCP works. It might. */
error = svc_makesock(serv, IPPROTO_TCP, port);
if (error < 0)
goto failure;

---------------------------------
G. Allen Morris III <gam3@acm.org>

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/