On Fri, Dec 12, 2008 at 07:26:10AM -0700, Robert Thurlow wrote: > Nicolas Williams wrote: > >where automountd_wait_for_cleanup() just waits for the child and then > >exits. The parent there seems to exist to serve door requests on > >did_fork_exec and did_exec_map, but why must that be done in a separate > >process when both processes run with the same credentials and > >privileges? > > This part is due to hangs we had when using executable > maps (ick). See 6368753 for more.
Fascinating. Truly fascinating. IMO auto_wait4mount() shouldn't sigintr() (one of the various linked CRs had a similar comment), and maybe automountd should do the lookup in the same thread and then do the mount(2) instead of this convoluted trigger- a-lookup-which-upcalls-to-the-same-process business. But the fix of having a separate process to do all executable map work was definitely expedient. There's only the tiniest comment in autod_main.c that only alludes to this ("This works around a potential hang in using fork1() within a multithreaded environment"). Nico --