Bug 140016 - mount utility ignores "-o udp" option
mount utility ignores "-o udp" option
Status: CLOSED CURRENTRELEASE
Product: Fedora
Classification: Fedora
Component: util-linux (Show other bugs)
2
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Steve Dickson
:
: 128100 (view as bug list)
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2004-11-19 05:56 EST by Alexey Budankov
Modified: 2007-11-30 17:10 EST (History)
5 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2005-03-24 08:26:32 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
A patch that makes both mount and umount adhere to the current IP protocol. (2.92 KB, patch)
2004-11-29 15:24 EST, Steve Dickson
no flags Details | Diff
.spec file for applying suggested above patch and building rpm (44.85 KB, text/plain)
2004-11-30 00:10 EST, Alexey Budankov
no flags Details

  None (edit)
Description Alexey Budankov 2004-11-19 05:56:31 EST
Description of problem:

I tried to mount some of my NFS shares loacated behind a firewall 
using "-o udp" option: 
user@linux]$ mount -o udp server:/directory/folder  /mnt/nfs/folder
udp ports were specially opened on the firewall but tcp ones weren't.
Mount operation hanged for ~ 5 minutes. The mount connection was 
displayed in "netstat -a" as went over tcp protocol.
Interesting fact that the same mounting command worked just fine on 
SuSE 9.1 and SLES 9.0 distros - they have util-linux version 2.12-72 
and , as well as FC2, kernel 2.6. However if I didn't specify 
explicitly "-o udp" behaviour on SUSE distros was the same. When I 
replaced /bin/mount,/bin/umount binaries on FC2 with the same ones 
from  SUSE9.1 distro, the issue went away. Also the problem presents 
in util-linux from FC3 and is reproduced on EM64T architecture.

Version-Release number of selected component (if applicable):
util-linux-2.12-18 - FC2
util-linux-2.12a-16 - FC3

How reproducible:
always

Steps to Reproduce:
1. Install FC2
2. Try mount any NFS share over udp - 
[user@linux]$ mount -o udp server:/directory/folder  /mnt/nfs/folder
3.Use netstat for example:
[user@linux]$ netstat -a
There will be your nfs connection but established over tcp protocol.
Active Internet connections (servers and established)
Proto Recv-Q Send-Q Local Address           Foreign Address         
State       PID/Program name   
...
it is here ===> tcp        0      1 FC2.intel:996 server.int:4046 
SYN_SENT    2087/mount          
tcp        0      0 *:ssh                   *:*                     
LISTEN      1733/sshd           
tcp        0      0 localhos:x11-ssh-offset *:*                     
LISTEN      1988/0              
tcp        0      0 localhost:6011          *:*                     
LISTEN      2029/1              
tcp        0      0 localhost:6012          *:*                     
LISTEN      2088/2              
tcp        0      0 nntvtune20.inn.inte:ssh abudanko-linux.in:33368 
ESTABLISHED 1988/0              
tcp        0      0 nntvtune20.inn.inte:ssh abudanko-linux.in:33369 
ESTABLISHED 2029/1              
tcp        0    144 nntvtune20.inn.inte:ssh abudanko-linux.in:33372 
ESTABLISHED 2088/2              
udp        0      0 *:32768                 
*:*                                 1635/rpc.statd      
udp        0      0 *:963                   
*:*                                 1635/rpc.statd      
udp        0      0 *:sunrpc                
*:*                                 1615/portmap        
Active UNIX domain sockets (servers and established)
Proto RefCnt Flags       Type       State         I-Node PID/Program 
name    Path
unix  4      [ ]         DGRAM                    2673   
1582/syslogd        /dev/log
unix  2      [ ACC ]     STREAM     LISTENING     2994   
1759/xfs            /tmp/.font-unix/fs7100
unix  2      [ ]         DGRAM                    2742   
1635/rpc.statd      
unix  2      [ ]         DGRAM                    2682   
1586/klogd        
Actual results:


Expected results:


Additional info:
Comment 1 Steve Dickson 2004-11-19 19:59:44 EST
I am of the opition that is this more of a firewall bug
than an NFS problem becuase neither FC2 or FC3 mount command
ignore the udp option. 
Comment 2 Alexey Budankov 2004-11-22 02:16:13 EST
OK, but the same utilities work perfect on SUSE. Anyway I can't 
exactly know what the problem is in, but this only happens on FC2/3 
for me.
Comment 3 Steve Dickson 2004-11-22 11:25:18 EST
Try 'service iptables stop' and then the mount....
Comment 4 Alexey Budankov 2004-11-23 02:31:43 EST
Hi,
Of course, I disabled all local firewall services and iptables sevice 
first time, before mounting, but it did'not help.

Thanks,
Alexey
Comment 5 Steve Dickson 2004-11-23 16:07:20 EST
I didn't didn't mean to in insultive... :) I just wanted to cover the
obvious.....

Now what troubles me with the  
"it is here ===> tcp 0 1 FC2.intel:996 server.int:4046 "
is 4046 is the not the port that NFS listens on,  2049 is the port
so I would have expected some like:  "FC2.intel:996 server.int:nfs" or
"FC2.intel:996 server.int:2049" if TCP was really being used.... 
Comment 6 Alexey Budankov 2004-11-24 02:25:52 EST
Hi Steve,
First, you are right - 4046 is not the apropriate port for nfs - the 
2049 port is, but the question is why mount tried to operate over tcp 
whereas I explicitly made it to connect over udp.
Second, "FC2.intel:996 server.int:nfs" from your previous message 
indeed appears but only after about 5 minutes and nfs connection is 
really established then.

My question is why it hangs so long, while other utilities operate 
much more faster (I mean other distros).

Thanks,
Alexey
Comment 7 Steve Dickson 2004-11-29 10:05:50 EST
Yes this is a problem... looking at a network trace it seems
rpc.mountd creates a TCP connection to the server even when
the "-o udp" mount is used. 
Comment 8 Steve Dickson 2004-11-29 15:24:24 EST
Created attachment 107572 [details]
A patch that makes both mount and umount adhere to the current IP protocol.

To make NFS mount and umount firewall friendlier, the communication
between rpc.mound and the nfs server need to used the same IP protocol
that is given on the command line.
Comment 9 Alexey Budankov 2004-11-30 00:10:18 EST
Created attachment 107604 [details]
.spec file for applying suggested above patch and building rpm

replace original util-linux.spec with the new one
Comment 10 Alexey Budankov 2004-11-30 00:16:34 EST
Hi Steve,
I tried your fix and it indeed worked perfect for me, it is good 
job :), thanks! I also attached new .spec file for building fixed 
binaries. 

Thanks,
Alexey
Comment 11 Steve Dickson 2004-11-30 08:48:07 EST
Fixed in util-linux-2.12-19.i386.rpm for FC2
Fixed in util-linux-2.12a-17.i386.rpm for FC3

Comment 12 Steve Dickson 2004-12-10 20:20:39 EST
*** Bug 128100 has been marked as a duplicate of this bug. ***
Comment 13 Peter Åstrand 2005-02-25 08:44:17 EST
The fixed util-linux package is *still* not available in
updates-stable. Why?
Comment 14 Steve Dickson 2005-03-03 01:45:14 EST
It should be available now... 
Comment 17 Peter Åstrand 2005-03-11 03:30:52 EST
>It should be available now... 

Well, it's not in
ftp://ftp.funet.fi/pub/mirrors/ftp.redhat.com/pub/fedora/linux/core/updates/2/i386/
yet...
Comment 18 Peter Åstrand 2005-03-14 07:46:37 EST
It's not in
http://download.fedora.redhat.com/pub/fedora/linux/core/updates/2/i386/
either. 
Comment 19 Peter Åstrand 2005-03-24 09:01:36 EST
"CURRENTRELEASE" means: "The problem described has already been fixed and can be
obtained in the latest version of our product."

The latest version of Fedora is FC3, and the bug is still present in FC3. No
fixed util-linux package has been released as stable for FC3, at least not in
http://download.fedora.redhat.com/pub/fedora/linux/core/updates/3/i386/. 

So, closing this bug with CURRENTRELEASE seems wrong to me. 
Comment 20 Steve Dickson 2005-03-28 08:32:56 EST
I'm not sure why these updates are not being pushed out but
I put the latest rpm and srpm in  http://people.redhat.com/steved/bz140016/
Comment 21 Bill Nottingham 2005-03-28 14:59:47 EST
No one requested that these be pushed from final to testing... is that a request?
Comment 22 Steve Dickson 2005-03-30 14:09:36 EST
I guess that was my fault.... please push this out... 
Comment 23 Peter Åstrand 2005-04-06 04:11:15 EDT
The update is available for FC2 and FC3 now. Thanks. 

However, I've discovered that the same problem exists in RHEL4. Should I open up
a new bug for this? Using the package util-linux-2.12a-23.i386 from FC3 seems to
work, but I assume that's not a supported solution. 
Comment 24 Peter Åstrand 2005-04-12 11:03:02 EDT
I've opened up a new bug for this issue on RHEL4:
https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=154533

Note You need to log in before you can comment on or make changes to this bug.