Results 1 to 10 of 11
Hey I and binding some folders with
Code:
mount --bind /folder /folder
I need to make sure that these are done when I (re)boot the machine.
Would that be done ...
- 04-06-2005 #1Just Joined!
- Join Date
- Aug 2004
- Location
- SLC, UT
- Posts
- 67
FSTab and Mount?
Hey I and binding some folders with
I need to make sure that these are done when I (re)boot the machine.Code:mount --bind /folder /folder
Would that be done in the FSTAB?
If so can you also help me out with the format?
I am going to read the MAN on FSTAB (if there is one now
)
===================
Read it - still need help! -- Thanks!
===================
- 04-06-2005 #2Linux Newbie
- Join Date
- Mar 2005
- Posts
- 230
Here's the syntax for a bind mount in /etc/fstab
/my/real/dir /to/mount/dir none rw,bind 0 0
none - No options associated with mount point (like quotas)
rw - The mount point is read and writeable.
bind - The mount point is a bound directory
- 04-06-2005 #3Just Joined!
- Join Date
- Aug 2004
- Location
- SLC, UT
- Posts
- 67
Thanks!
- 04-06-2005 #4in fstab that none would specify that the partition has none fs type. you would need:
Originally Posted by SilentRage
(i think)Code:/my/real/dir /to/mount/dir <filesystem> rw,bind 0 0
where filesystem is something like ext2, ext3 reiserfs or vfat"I am not an alcoholic, alcoholics go to meetings"
Registered Linux user = #372327
- 04-06-2005 #5Just Joined!
- Join Date
- Mar 2005
- Posts
- 13
sdousley is right. You'll need to put the filesystem in there, or you won't be reading or writing anything.
- 04-07-2005 #6Linux Newbie
- Join Date
- Mar 2005
- Posts
- 230
I didn't put anything, and it works for me. It may work differently for mount --bind.
- 04-07-2005 #7Linux Newbie
- Join Date
- Jul 2004
- Location
- Calcutta, India
- Posts
- 220
mount works so wonderfully on redhat .. isnt it SilentRage ???
For eg., I use ntfs auto in my fstab with kernel-ntfs installed, and it works peacefully. However same is not the case with other guyz who use, say fc2, or SuSE, maybe.
- 04-07-2005 #8
Actually, many distros (Suse and Mandrake among them) mount ntfs partitions without having to install anything to enable it. Fedora Core uses the same system for mounting ntfs partitions as redhat.
There are two major products that come out of Berkeley: LSD and UNIX. We don't believe this to be a coincidence.
- Jeremy S. Anderson
- 04-07-2005 #9Why would they change the way it mounts from RedHat to FC?
Originally Posted by Flatline
Either way, in the fstab, you should put the fstype."I am not an alcoholic, alcoholics go to meetings"
Registered Linux user = #372327
- 04-11-2005 #10Just Joined!
- Join Date
- Apr 2005
- Posts
- 1
No fstype
A bind mount has no fstype, thus you should put no fs type. In any event it's ignored by mount(2). This is because an fstype is used to tell the kernel how to access the device file. Since the device file isn't a device, but rather a directory, telling it to use a directory as a device file make no sense.
Of course, you could put it there for your own notes, but then the type is already noted in its "real" mount line. And then you'd have to remember to change it anytime the other mount is altered (not a big deal.. shouldn't happen often).


Reply With Quote
