I've read the automount and autofs man pages and, while I'm somewhat the wiser, I'm still not sure if it's possible to do what I want.
What I want to do is prevent automount from automounting one particular directory. Now from what I (think I) have understood I think it's a /net entry in /etc/auto.master is making the script in /etc/auto.net execute and, essentially, allowing one to automount all file systems which other computers on the network have exported.
What I want is to stop just *one* of these exported file systems being mounted on just my Fedora Core 6 system at work so I can have a local file system there instead.
So, does anyone know if this is remotely possible?
Eur Ing Chris Green cl@isbd.net wrote: [automount /net filesystem]
What I want is to stop just *one* of these exported file systems being mounted on just my Fedora Core 6 system at work so I can have a local file system there instead.
So, does anyone know if this is remotely possible?
No idea. By your description of /net, I assume that's a /net/hostname/exportedfs - or is that amd?
I'd anticipate it breaking horribly (as in hard lock) but I'd try starting the automounter, making the directory appear (maybe safer to do this with a ghost or dummy directory) and then mount the local filesystem on that directory (directly or with --bind option).
If you try to do it the other way (make a directory /net/whatever/local and mount the local fs there, then start the automounter), the autofs will be "on top" of the local fs, so be hidden.
Let us know how it goes and whether you junk a filesystem (hope not),
On Mon, Mar 19, 2007 at 07:55:46PM +0000, MJ Ray wrote:
Eur Ing Chris Green cl@isbd.net wrote: [automount /net filesystem]
What I want is to stop just *one* of these exported file systems being mounted on just my Fedora Core 6 system at work so I can have a local file system there instead.
So, does anyone know if this is remotely possible?
No idea. By your description of /net, I assume that's a /net/hostname/exportedfs - or is that amd?
I can find no documentation at all that really helps, all the autofs documentation I can find concentrates on using autofs to mount floppies and CDs.
I'd anticipate it breaking horribly (as in hard lock) but I'd try starting the automounter, making the directory appear (maybe safer to do this with a ghost or dummy directory) and then mount the local filesystem on that directory (directly or with --bind option).
If you try to do it the other way (make a directory /net/whatever/local and mount the local fs there, then start the automounter), the autofs will be "on top" of the local fs, so be hidden.
It doesn't seem to be like that, the actual directory in question that is automounted (among many others) is /proj/chris. This is mounted from a remote Solaris computer called crusade such that 'mount' reports:-
/proj/chris mounted on crusade:/scratch/chris
(which seems the wrong way around to me, but still). /scratch/chris is a 'real' file system on crusade which is exported by crusade.
/net seems to be just a sort of link between /etc/auto.master and /etc/auto.net. /etc/auto.net is a script which uses the showmount command to find what file systems are exported from where. At least that's what my initial investigation suggests, but as I said I'm totally stuck in trying to find any documentation.
Not sure if this is what you're after - but... from my auto.mount file: (goes in your auto.net) I have:
heimdall_storage -fstype=smbfs,uid=rob,credentials=/etc/samba/private/aut h.cred ://heimdall/storage
Which means you should be able to do something like:
local_directory -fstype=ext3 :/dev/hda5
or whatever, and it might work... maybe..
Rob.
On 19/03/07, Eur Ing Chris Green cl@isbd.net wrote:
On Mon, Mar 19, 2007 at 07:55:46PM +0000, MJ Ray wrote:
Eur Ing Chris Green cl@isbd.net wrote: [automount /net filesystem]
What I want is to stop just *one* of these exported file systems being mounted on just my Fedora Core 6 system at work so I can have a local file system there instead.
So, does anyone know if this is remotely possible?
No idea. By your description of /net, I assume that's a /net/hostname/exportedfs - or is that amd?
I can find no documentation at all that really helps, all the autofs documentation I can find concentrates on using autofs to mount floppies and CDs.
I'd anticipate it breaking horribly (as in hard lock) but I'd try starting the automounter, making the directory appear (maybe safer to do this with a ghost or dummy directory) and then mount the local filesystem on that directory (directly or with --bind option).
If you try to do it the other way (make a directory /net/whatever/local and mount the local fs there, then start the automounter), the autofs will be "on top" of the local fs, so be hidden.
It doesn't seem to be like that, the actual directory in question that is automounted (among many others) is /proj/chris. This is mounted from a remote Solaris computer called crusade such that 'mount' reports:-
/proj/chris mounted on crusade:/scratch/chris
(which seems the wrong way around to me, but still). /scratch/chris is a 'real' file system on crusade which is exported by crusade.
/net seems to be just a sort of link between /etc/auto.master and /etc/auto.net. /etc/auto.net is a script which uses the showmount command to find what file systems are exported from where. At least that's what my initial investigation suggests, but as I said I'm totally stuck in trying to find any documentation.
-- Chris Green
main@lists.alug.org.uk http://www.alug.org.uk/ http://lists.alug.org.uk/mailman/listinfo/main Unsubscribe? See message headers or the web site above!
If you try to do it the other way (make a directory /net/whatever/local and mount the local fs there, then start the automounter), the autofs will be "on top" of the local fs, so be hidden.
It doesn't seem to be like that, the actual directory in question that is automounted (among many others) is /proj/chris. This is mounted from a remote Solaris computer called crusade such that 'mount' reports:-
/proj/chris mounted on crusade:/scratch/chris
(which seems the wrong way around to me, but still). /scratch/chris is a 'real' file system on crusade which is exported by crusade.
Well, I've got it done the 'right' way. I looked at the "other end", i.e. the Solaris box that was sharing the filesystem and it turns out that share can specificallly exclude targets. So I got the sysadmin (who has root on the Solaris boxes) to do:-
unshare /scratch/chris share -F nfs -o rw=-chrisg:-ricky:ourdomain /scratch/chris
This means that the share is explicitly *not* available to chrisg (my Linux box) and ricky (another Linux box I use occasionally). Thus the automounter doesn't pick it up and I've got rid of the directory on the Linux boxes. I can now create my own /proj/chris on the Linux box and have what I need.
By the way it would appear that you can mount as many things as you like in one place and only the last one is left working. Before doing the above I could get the effect I wanted by mounting a local file system 'on top of' what the automounter had done. However I couln't automate this by putting the mount in /etc/fstab because autofs came along and did its thing after that.