autofs appears to be started before it is truly functional

Bug #738209 reported by Mark Russell
22
This bug affects 4 people
Affects Status Importance Assigned to Milestone
autofs (Ubuntu)
Confirmed
Medium
Clint Byrum

Bug Description

Binary package hint: autofs

Description: Ubuntu 10.04.2 LTS
Release: 10.04

Installed: 5.0.4-3.1ubuntu5.1

Brief summary: autofs, in upstart terms, becomes "started" before it is actually ready. There seems to be a brief window immediately after "started" where if you run something expecting to be able to read or write to an automounted directory it will either fail (on a read or a write to a subdir of the mount) or write to the empty mountpoint (on a write to the root of the mount). Even though `status autofs` is "started/running" the mounts aren't ready.

If you sleep for a few seconds in the post-start script it covers up for the bug in most cases (probably) but the exact number may vary by system.

Tags: upstart
Revision history for this message
Mark Russell (marrusl) wrote :

You can work around this issue by adding this to the end of /etc/init/autofs.conf:

post-start script
    sleep 5
end script

Changed in autofs (Ubuntu):
importance: Undecided → Medium
assignee: nobody → Clint Byrum (clint-fewbar)
Revision history for this message
Clint Byrum (clint-fewbar) wrote :

There are two issues here. One is that the package appears to fork before it is actually ready for things to automount. Because of that, we don't have a clear point which we can emit the started event. So either a patch should be made to have it fork later (unlikely) or we need a post-start that looks for evidence that automounting is ready to be used and blocks started until that condition is true.

tags: added: upstart
Changed in autofs (Ubuntu):
status: New → Confirmed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.