Bug 519411 - bind mounts in /etc/fstab are not mounted automatically
Summary: bind mounts in /etc/fstab are not mounted automatically
Alias: None
Product: Fedora
Classification: Fedora
Component: initscripts
Version: 11
Hardware: All
OS: Linux
Target Milestone: ---
Assignee: Bill Nottingham
QA Contact: Fedora Extras Quality Assurance
Depends On:
TreeView+ depends on / blocked
Reported: 2009-08-26 14:27 UTC by Mads Kiilerich
Modified: 2014-03-17 03:20 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2009-08-27 10:20:15 UTC
Type: ---

Attachments (Terms of Use)
possible patch (737 bytes, patch)
2009-08-26 14:27 UTC, Mads Kiilerich
no flags Details | Diff

Description Mads Kiilerich 2009-08-26 14:27:52 UTC
Created attachment 358726 [details]
possible patch

Description of problem:

The fstab man page says that all filesystems without noauto will be mounted on boot time, just as "mount -a" does.

That NFS and proc is handled in a special way by rc.sysinit is an implementation detail.

It must thus be a bug that bind mounts not are mounted automatically.

It seems like bind (and perhaps other missing types?) just should be added to the mount -a in rc.sysinit.

Version-Release number of selected component (if applicable):


Comment 1 Bill Nottingham 2009-08-26 19:57:02 UTC
You're misunderstanding that statement. By adding bind to the list, you're telling it to not mount filesystems that have 'bind' as the filesystem type.

Comment 2 Bill Nottingham 2009-08-26 20:00:58 UTC
What does your fstab look like? A line like:

/var  /usr/local/var  none  bind  0 0

works fine for me on boot.

Comment 3 Mads Kiilerich 2009-08-27 10:20:15 UTC
notting: You are absolutely right. My bad. Thanks for the hints on IRC.

Forensic analysis:

I was probably mostly confused by not being aware that Live CDs /mnt/live is mounted _after_ /etc/rc.sysinit and "mount -a" has been executed. Seeing that the bind-mounted mount point was empty I must have concluded that nothing had been mounted.

I misunderstood the -t option from the manpage. Not knowing the exclusive list of file systems by heart I assumed that -t was an exclude list (which surprised me) and that nomsdos (and nonfs) was file systems. Assuming that the -t option was just a list I randomly but "bind" before or after the "no", so my test results were completely broken and supported my wrong conclusions.

After having tried "none" as file system type in fstab and concluded that it didn't work for the reasons above I changed to "bind". Apparently anything can be specified as file system type for bind mounts, and it will (only?) be used for filtering when doing "mount -a -t". So "mount -a -t bind" works just as well as "mount -a -t foo" if the fstab file system type is specified accordingly.


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