Leonardo Chiquitto wrote:
> Hello,
> 
> I've been doing some tests with AutoFS5 and I'd like to confirm that
> the behavior I'm seeing during the daemon initialization is expected
> or not.
> 
> The problem: when the autofs initscript returns, autofs is not really
> ready.
> 
> Reading the code, I see that the automount daemon detaches itself from
> the controlling terminal (becoming a daemon) early in its initialization.
> After that, it starts other threads to handle different tasks and just then
> reads the available maps. Normally, reading the maps is quick, but it
> could take a bit more if using NIS or LDAP, what explains the delay
> between the initscript returning (immediately after daemonization) and
> autofs being really ready to proceed.
> 
> I was thinking about some options to work around this problem (like deferring
> daemonization), but after a while, I couldn't find a clean and non-intrusive
> solution. Can you help me here?

I too have this issue.

We have been inserting a sleep into the startup script to allow autofs 
to finish reading the maps prior to other scripts executing.  The issue 
with this solution it the amount of sleep is dependedent on the site and 
how many NFS maps/mounts.  For some sites it is 1 second, for others it 
is almost 25.

Without it, many of our startup scripts fails because autofs isn't ready.

It would be nice to have a better solution.

Michael

_______________________________________________
autofs mailing list
autofs@linux.kernel.org
http://linux.kernel.org/mailman/listinfo/autofs

Reply via email to