lkml.org 
[lkml]   [2012]   [Mar]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
Subjectautofsv4: "ghost" entries prevent timeout of mounts
Dear kernel developers,

starting with at least kernel version 3.2.9, but probably earlier,
mounting autofs with the --ghost option to create dummy directory
entries in its mount point prevents the autofs mounts from timing out.
Instead, the mounts persist and are never unmounted.

This problem did not exist in kernel 2.6.35.13, at least, so autofs must
have been broken somewhere between 2.3.35.13 and 3.2.9.

/etc/auto.master reads as follows:

# $Id: auto.master,v 1.2 1997/10/06 21:52:03 hpa Exp $
# Sample auto.master file
# Format of this file:
# mountpoint map options
# For details of the format look at autofs(8).
#
# Note: Due to a bug in the init.d/autofs script, there
# *MUST* be a blank space behind the options (here: -t=10 <--).
# Unlike the debian reference, options must be given in the
# form "-option=<value>".
#
# -g is broken and stops automatic unmounting from working.
#

/var/autofs/misc /etc/auto.misc -g -t=2

/etc/auto.misc is as follows:

# $Id: auto.misc,v 1.2 1997/10/06 21:52:04 hpa Exp $
# This is an automounter map and it has the following format
# key [ -mount-options-separated-by-comma ] location
# Details may be found in the autofs(5) manpage

cdrom0 -fstype=auto,noatime,rw,user,nodev,nosuid :/dev/cdrom0
cdrom1 -fstype=auto,noatime,rw,user,nodev,nosuid :/dev/cdrom1
zip -fstype=auto,nodev,nosuid :/dev/zip
usbstick
-fstype=auto,noatime,rw,user,nodev,nosuid,gid=floppy,umask=0200
:/dev/usbstick
usbdisk -fstype=auto,noatime,rw,user,nodev,nosuid
:/dev/usbdisk
camera
-fstype=auto,noatime,rw,user,nodev,nosuid,gid=floppy,umask=0200 :/dev/camera
floppy -fstype=auto,rw,async,nodev,nosuid,umask=000 :/dev/fd0

/etc/default/autofs contains the following non-default entries:

MASTER_MAP_NAME="/etc/auto.master"
TIMEOUT=2 # <- also makes no difference
NEGATIVE_TIMEOUT=1 # <- neither this
BROWSE_MODE="no"
USE_MISC_DEVICE="no" # <- makes no difference, actually

Userspace tools are from Debian Squeeze (is there a relation? Might they
break autofs?)

How to reproduce:

Instead a medium in one of the auto-mounted devices, e.g. cdrom0,
mount it by going into /var/autofs/misc/cdrom0, then leave the
directory. Wait for the timeout (or longer). Testing with "mount" shows
that the corresponding device file remains mounted, regardless how long
you wait.


Best regards,

Thomas


\
 
 \ /
  Last update: 2012-03-14 22:09    [W:0.224 / U:0.128 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site