include a master file: where does the automounter look
Hello,
when I read the manpage for auto.master (and other docs) I see that I can include another master file by doing:
+auto.master
The comment says that by doing so, the you can specify a master map which is found using
nsswitch sources.
What happens then? Where does it look then?
When I add a line with an auto.master file with full path:
+/var/run/autofs/auto.master
it works also.
Stef
Ian Kent
maintainerQuoted 11 lines · Stef Bon
Hello,
when I read the manpage for auto.master (and other docs) I see that I can include another master file by doing:
+auto.master
The comment says that by doing so, the you can specify a master map which is found using
nsswitch sources.
What happens then? Where does it look then?
If you have a line in /etc/nsswitch.conf like:
automount: files nis
it will look in /etc for auto.master (files) and try to connect to a nis server and ask for auto.master.
So, it depends on the source specified in /etc/nsswitch.conf.
Quoted 6 lines
When I add a line with an auto.master file with full path:
+/var/run/autofs/auto.master
it works also.
That's right.
This just prevents autofs from consulting /etc/nsswitch.conf because it doesn't need to.
Ian
Ian Kent
maintainerQuoted 13 lines · Ian Kent
Quoted 11 lines · Stef Bon
Hello,
when I read the manpage for auto.master (and other docs) I see that I can include another master file by doing:
+auto.master
The comment says that by doing so, the you can specify a master map which is found using
nsswitch sources.
What happens then? Where does it look then?
Quoted 6 lines
If you have a line in
/etc/nsswitch.conflike:automount: files nis
it will look in /etc for auto.master (files) and try to connect to a nis server and ask for auto.master.
There's actually a bit more to it than that because of the possibility of different actions, such as continuing or returning when a source is found or not.
Ian
Quoted 20 lines · Ian Kent
Quoted 18 lines · Ian Kent
Quoted 5 lines · Stef Bon
Hello,
when I read the manpage for auto.master (and other docs) I see that I can include another master file by doing:
Quoted 7 lines
+auto.master
The comment says that by doing so, the you can specify a master map which is found using
nsswitch sources.
What happens then? Where does it look then?If you have a line in
/etc/nsswitch.conflike:automount: files nis
Quoted 8 lines
Quoted 3 lines
it will look in /etc for auto.master (files) and try to connect to a nis server and ask for auto.master.
There's actually a bit more to it than that because of the possibility of different actions, such as continuing or returning when a source is found or not.
Thanks a lot for the info.
Stef Bon
BTW I'm working on documentating the construction I'm using right now. It's not ready, but when I'm happy, I will also
redo the already existing documentation on howtoforge.
Look at:
http://linux.bononline.nl/linux/automountsmbshares/automountsmbshares-page01a.php
Ian Kent
maintainerQuoted 29 lines · Stef Bon
Quoted 20 lines · Ian Kent
Quoted 18 lines · Ian Kent
Quoted 5 lines · Stef Bon
Hello,
when I read the manpage for auto.master (and other docs) I see that I can include another master file by doing:
Quoted 7 lines
+auto.master
The comment says that by doing so, the you can specify a master map which is found using
nsswitch sources.
What happens then? Where does it look then?If you have a line in
/etc/nsswitch.conflike:automount: files nis
Quoted 8 lines
Quoted 3 lines
it will look in /etc for auto.master (files) and try to connect to a nis server and ask for auto.master.
There's actually a bit more to it than that because of the possibility of different actions, such as continuing or returning when a source is found or not.
Quoted 8 lines
Thanks a lot for the info.
Stef Bon
BTW I'm working on documentating the construction I'm using right now. It's not ready, but when I'm happy, I will also
redo the already existing documentation on howtoforge.
Did you know I have domain autofs.net.
Some time ago now I started a wiki but never went far enough to make it usable. http://wiki.autofs.net/ is still responding but is, of course, light on when it comes to useful doco, and I think out of date.
Ian
Quoted 15 lines · Ian Kent
Quoted 5 lines · Stef Bon
Hello,
when I read the manpage for auto.master (and other docs) I see that I can include another master file by doing:
Quoted 7 lines
+auto.master
The comment says that by doing so, the you can specify a master map which is found using
nsswitch sources.
What happens then? Where does it look then?
Quoted 7 lines
If you have a line in
/etc/nsswitch.conflike:automount: files nis
it will look in /etc for auto.master (files) and try to connect to a nis server and ask for auto.master.
Ok, it will search for the files first and after that the nis thing. But here: this line which instructed the automounter to look in the nsswitch.conf file is in a auto.master file, and then you instruct it to look for the same file again.
This does not make sense to me...
Stef Bon
Quoted 20 lines · Stef Bon
Quoted 19 lines · Ian Kent
Quoted 5 lines · Stef Bon
Hello,
when I read the manpage for auto.master (and other docs) I see that I can include another master file by doing:
Quoted 7 lines
+auto.master
The comment says that by doing so, the you can specify a master map which is found using
nsswitch sources.
What happens then? Where does it look then?If you have a line in
/etc/nsswitch.conflike:automount: files nis
Quoted 8 lines
Quoted 3 lines
it will look in /etc for auto.master (files) and try to connect to a nis server and ask for auto.master.
Ok, it will search for the files first and after that the nis thing. But here: this line which instructed the automounter to look in the nsswitch.conf file is in a auto.master file, and then you instruct it to look for the same file again.
This does not make sense to me...
The daemon has logic to check for recursion, so it won't include the same map over and over again. If it is processing auto.master, and it sees a +auto.master, it checks the next source in the list.
Cheers,
Jeff