Accepting request 222653 from Base:System
- udp-fallback.fix: Fix fallback from tcp to udp (bnc#863749) OBS-URL: https://build.opensuse.org/request/show/222653 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/nfs-utils?expand=0&rev=113
This commit is contained in:
commit
f43ddda523
@ -1,3 +1,9 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Mon Feb 17 04:40:41 UTC 2014 - nfbrown@suse.com
|
||||||
|
|
||||||
|
- udp-fallback.fix: Fix fallback from tcp to udp
|
||||||
|
(bnc#863749)
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Tue Feb 4 05:18:48 UTC 2014 - nfbrown@suse.com
|
Tue Feb 4 05:18:48 UTC 2014 - nfbrown@suse.com
|
||||||
|
|
||||||
|
@ -81,8 +81,10 @@ Patch8: mountd-fix-bug-affecting-exports-of-dirs-with-64bit-.patch
|
|||||||
Patch9: exportfs-exit-with-error-code-if-there-was-any-error.patch
|
Patch9: exportfs-exit-with-error-code-if-there-was-any-error.patch
|
||||||
# PATCH-FIX_UPSTREAM exportfs-report-failure-if-asked-to-unexport-somethi.patch nfbrown@suse.de
|
# PATCH-FIX_UPSTREAM exportfs-report-failure-if-asked-to-unexport-somethi.patch nfbrown@suse.de
|
||||||
Patch10: exportfs-report-failure-if-asked-to-unexport-somethi.patch
|
Patch10: exportfs-report-failure-if-asked-to-unexport-somethi.patch
|
||||||
# PATCH-FIX-UPSTRAM gssd-mount-hang-fix bnc#833543 nfbrown@suse.de
|
# PATCH-FIX-UPSTREAM gssd-mount-hang-fix bnc#833543 nfbrown@suse.de
|
||||||
Patch11: gssd-mount-hang-fix
|
Patch11: gssd-mount-hang-fix
|
||||||
|
# PATCH-FIX-UPSTREAM udp-fallback.fix bnc#863749 nfbrown@suse.de
|
||||||
|
Patch12: udp-fallback.fix
|
||||||
Suggests: python-base
|
Suggests: python-base
|
||||||
|
|
||||||
%description
|
%description
|
||||||
@ -145,6 +147,7 @@ This package contains additional NFS documentation.
|
|||||||
%patch9 -p1
|
%patch9 -p1
|
||||||
%patch10 -p1
|
%patch10 -p1
|
||||||
%patch11 -p1
|
%patch11 -p1
|
||||||
|
%patch12 -p1
|
||||||
cp %{S:6} .
|
cp %{S:6} .
|
||||||
|
|
||||||
%build
|
%build
|
||||||
|
36
udp-fallback.fix
Normal file
36
udp-fallback.fix
Normal file
@ -0,0 +1,36 @@
|
|||||||
|
From: NeilBrown <neilb@suse.de>
|
||||||
|
Subject: Fix fallback from tcp to udp
|
||||||
|
References: bnc#863749
|
||||||
|
|
||||||
|
Protocol negotiation in mount.nfs does not correctly negotiate with a
|
||||||
|
server which only support NFSv3 and UDP.
|
||||||
|
|
||||||
|
When mount.nfs attempts an NFSv4 mount and fails with ECONNREFUSED
|
||||||
|
it does not fall back to NFSv3, as this is not recognised as a
|
||||||
|
"does not support NFSv4" error.
|
||||||
|
However ECONNREFUSED is a clear indication that the server doesn't
|
||||||
|
support TCP, and ipso facto does not support NFSv4.
|
||||||
|
So ECONNREFUSED should trigger a fallback from v4 to v2/3.
|
||||||
|
|
||||||
|
Once we allow that error, NFSv3 is attempted and mount.nfs talks to
|
||||||
|
rpcbind and discovers that UDP should be used for v3 and the mount
|
||||||
|
succeeds.
|
||||||
|
|
||||||
|
Signed-off-by: NeilBrown <neilb@suse.de>
|
||||||
|
Reported-by: Carsten Ziepke <kieltux@gmail.com>
|
||||||
|
---
|
||||||
|
utils/mount/stropts.c | 3 +++
|
||||||
|
1 file changed, 3 insertions(+)
|
||||||
|
|
||||||
|
--- nfs-utils-1.2.8.orig/utils/mount/stropts.c
|
||||||
|
+++ nfs-utils-1.2.8/utils/mount/stropts.c
|
||||||
|
@@ -807,6 +807,9 @@ static int nfs_autonegotiate(struct nfsm
|
||||||
|
/* Linux servers prior to 2.6.25 may return
|
||||||
|
* EPERM when NFS version 4 is not supported. */
|
||||||
|
goto fall_back;
|
||||||
|
+ case ECONNREFUSED:
|
||||||
|
+ /* UDP-Only server won't support v4 */
|
||||||
|
+ goto fall_back;
|
||||||
|
default:
|
||||||
|
return result;
|
||||||
|
}
|
Loading…
x
Reference in New Issue
Block a user