* Is the "program" format correct ?
@ 2004-08-08 14:47 Andreas Neuper
0 siblings, 0 replies; 4+ messages in thread
From: Andreas Neuper @ 2004-08-08 14:47 UTC (permalink / raw)
To: autofs
Hello,
I am new to the list. I wanted to use the program format to provide some good solution.
Unfortunately, it showed a strange behaviour. It seems to me, nobody really ever used it!
Your example delivered with the distribuion works, although it should not IMHO.
I would expect that the program format causes the same action as
e.g. a nis-map or a file. Maybe I am wrong with my expectations.
Try this:
~# cat /etc/auto.master
/auto /etc/auto.auto
~# cat <<*** >/etc/auto.cat
#!/bin/sh
grep -v ^# /etc/auto.auto
exit 0
***
~# chmod a+x /etc/auto.cat
~# /etc/auto.cat
floppy -fstype=auto :/dev/fd0
video -fstype=nfs,rw,rsize=8192,wsize=8192 ok:/home/video
~# echo "/tmp/cat /etc/auto.cat" >> /etc/auto.master
~# /etc/rc.d/autofs restart
~# ls /auto/video
. .. DVD
~# ls /tmp/cat/
. ..
~# ls /tmp/cat/video
^C
~# tail -5 /var/log/messages
Aug 8 16:26:21 akemi automount[6212]: mount(nfs): host -fstype=auto: lookup failure
Aug 8 16:26:21 akemi automount[6212]: mount(nfs): host : lookup failure
Aug 8 16:26:21 akemi automount[6215]: mount(nfs): host floppy: lookup failure
Aug 8 16:26:21 akemi automount[6215]: mount(nfs): host -fstype=auto: lookup failure
Aug 8 16:26:21 akemi automount[6215]: mount(nfs): host : lookup failure
thanks for reading. Is there a simple solution?
Andreas
____________________________________________________
Aufnehmen, abschicken, nah sein - So einfach ist
WEB.DE Video-Mail: http://freemail.web.de/?mc=021200
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Is the "program" format correct ?
@ 2004-08-11 7:16 Takashi Yoshizawa
0 siblings, 0 replies; 4+ messages in thread
From: Takashi Yoshizawa @ 2004-08-11 7:16 UTC (permalink / raw)
To: autofs
Andreas Neuper wrote:
>~# /etc/auto.cat
>
>floppy -fstype=auto :/dev/fd0
>video -fstype=nfs,rw,rsize=8192,wsize=8192 ok:/home/video
>
I'm also using automounter program map.
It should behave like this:
~# /etc/auto.cat video
-fstype=nfs,rw,rsize=8192,wsize=8192 ok:/home/video
>~# echo "/tmp/cat /etc/auto.cat" >> /etc/auto.master
~# echo "/tmp/cat program:/etc/auto.cat" >> /etc/auto.master
Takashi Yoshizawa
_________________________________________________________________
Help STOP SPAM with the new MSN 8 and get 2 months FREE*
http://join.msn.com/?page=features/junkmail
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Is the "program" format correct ?
@ 2004-08-14 16:21 Andreas Neuper
2004-08-15 2:15 ` raven
0 siblings, 1 reply; 4+ messages in thread
From: Andreas Neuper @ 2004-08-14 16:21 UTC (permalink / raw)
To: autofs
Thank you Takashi,
this confirms my oppinion: The format for program maps differs!
Usual and documented format is:
key [-options] location
These maps swallow the key and accept only nfs location codes
where the hostname seems to be overwritten with the key. !?!
It seems strange to me. just try to use it for the floppy. I get
errors on hostname resolution! (even when omitting the key)
Is there a working release?
Andreas
____________________________________________________
Aufnehmen, abschicken, nah sein - So einfach ist
WEB.DE Video-Mail: http://freemail.web.de/?mc=021200
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Is the "program" format correct ?
2004-08-14 16:21 Is the "program" format correct ? Andreas Neuper
@ 2004-08-15 2:15 ` raven
0 siblings, 0 replies; 4+ messages in thread
From: raven @ 2004-08-15 2:15 UTC (permalink / raw)
To: Andreas Neuper; +Cc: autofs
On Sat, 14 Aug 2004, Andreas Neuper wrote:
> Thank you Takashi,
>
> this confirms my oppinion: The format for program maps differs!
> Usual and documented format is:
> key [-options] location
Not really.
>
> These maps swallow the key and accept only nfs location codes
> where the hostname seems to be overwritten with the key. !?!
It receives the key as a parameter.
Lookups always "lookup a key". The program map returns the map entry for
the given key only. All the lookup modules work this way.
The confusion here is because you are seeing what the lookup module needs
to complete its operation not what you expect a map to look like. It
already knows what key it's looking for and doesn't want or need the key
to be returned.
>
> It seems strange to me. just try to use it for the floppy. I get
> errors on hostname resolution! (even when omitting the key)
In what way are you using it with your floppy?
>
> Is there a working release?
Program maps are something that are used by people like yourself. The
auto.net is an example only.
Ian
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2004-08-15 2:15 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-08-14 16:21 Is the "program" format correct ? Andreas Neuper
2004-08-15 2:15 ` raven
-- strict thread matches above, loose matches on Subject: below --
2004-08-11 7:16 Takashi Yoshizawa
2004-08-08 14:47 Andreas Neuper
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.