Bug 242935 - faulty mounting of loop and bind entries from /etc/fstab
faulty mounting of loop and bind entries from /etc/fstab
Status: CLOSED WONTFIX
Product: Fedora
Classification: Fedora
Component: util-linux (Show other bugs)
6
i386 Linux
low Severity low
: ---
: ---
Assigned To: Karel Zak
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2007-06-06 11:01 EDT by vikram goyal
Modified: 2008-03-09 06:31 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2008-03-09 06:30:48 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
mount output in various scenarios (3.01 KB, text/plain)
2007-06-06 11:01 EDT, vikram goyal
no flags Details

  None (edit)
Description vikram goyal 2007-06-06 11:01:34 EDT
Description of problem:
I wanted to mount F-7 dvd iso through loop device on a dir /home/nfs
Also I wanted the same mount on /var/www/html/install through bind

So I made two entries in /etc/fstab:
/mnt/e/Fedora-7-i386/F-7-i386-DVD.iso  /home/nfs  iso9660 ro,loop  0 0

/home/nfs  /var/www/html/install  none  ro,bind  0 0

Version-Release number of selected component (if applicable):
setup-2.6.1.1-1.fc6

How reproducible:
When I mount /home/nfs from command line by doing:
mount /home/nfs
/var/www/html/install gets mounted of the empty /home/nfs dir
If I delete or hash second entry and then mount /home/nfs
The iso gets properly mounted on loop device and shows its contents.

Steps to Reproduce:
1.make the entries in /etc/fstab
2.mount the first entry
3.second entry gets mounted
  
Actual results:
second entry gets mounted


Expected results:
First entry should be mounted

Additional info:
attaching appropriate mount output
kernel 2.6.19-1.2911.6.5.fc6xen
Comment 1 vikram goyal 2007-06-06 11:01:34 EDT
Created attachment 156359 [details]
mount output in various scenarios
Comment 2 Karel Zak 2007-06-18 05:38:28 EDT
This is nothing new, see #193094.

The problem is that we can't change a way how the mount command interprets
command line options due to backward compatibility. The mount(8) is trying (in
sequence):

  1. option is a source (filesystem, device, dir, ...)
  2. option is a target (mountpoint)

it means your "/home/nfs" is always interpreted as a source (the bind mount).
Comment 3 vikram goyal 2008-03-09 06:30:48 EDT

*** This bug has been marked as a duplicate of 193094 ***

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