[Bug 758391] New: autofs does not umount after timeout
https://bugzilla.novell.com/show_bug.cgi?id=758391 https://bugzilla.novell.com/show_bug.cgi?id=758391#c0 Summary: autofs does not umount after timeout Classification: openSUSE Product: openSUSE 12.1 Version: Final Platform: i686 OS/Version: openSUSE 12.1 Status: NEW Severity: Major Priority: P5 - None Component: Basesystem AssignedTo: bnc-team-screening@forge.provo.novell.com ReportedBy: p.bhat@gramtechnet.co.in QAContact: qa-bugs@suse.de Found By: --- Blocker: --- User-Agent: Mozilla/5.0 (X11; Linux i686) AppleWebKit/534.34 (KHTML, like Gecko) konqueror/4.8.1 Safari/534.34 I have an automount and my /etc/sysconfig/autofs options sets 'timeout' to 30 secs. The auto.master is not overriding these settings. in OS 11.4, my setup used to unmount the automount on inactivity. But in 12.1 this unmounting does not work. Reproducible: Always Steps to Reproduce: 1.set up an automount 2.'cd' into automount point and 'cd' back out 3.wait for 'timeout', period an check system mounts. The acivated mount at (2) would still be available Actual Results: automounts did not unmount Expected Results: the automounts are unmounted after inactivity of 'timeout' period -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=758391 https://bugzilla.novell.com/show_bug.cgi?id=758391#c1 kk zhang <kkzhang@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |kkzhang@suse.com AssignedTo|bnc-team-screening@forge.pr |dmueller@suse.com |ovo.novell.com | --- Comment #1 from kk zhang <kkzhang@suse.com> 2012-04-23 06:44:33 UTC --- HI,could you please help to have a look this?I am not sure whether it is right to assign it to you.Feel free to reassign it.Thank you. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=758391 https://bugzilla.novell.com/show_bug.cgi?id=758391#c Dirk Mueller <dmueller@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- AssignedTo|dmueller@suse.com |lchiquitto@suse.com -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=758391 https://bugzilla.novell.com/show_bug.cgi?id=758391#c Leonardo Chiquitto <lchiquitto@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=758391 https://bugzilla.novell.com/show_bug.cgi?id=758391#c2 Leonardo Chiquitto <lchiquitto@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Priority|P5 - None |P3 - Medium Status|ASSIGNED |NEEDINFO InfoProvider| |p.bhat@gramtechnet.co.in --- Comment #2 from Leonardo Chiquitto <lchiquitto@suse.com> 2012-04-30 12:51:02 UTC --- Please provide the following information: 1. output of "rpm -q autofs" 2. debug logs - set DEFAULT_LOGGING="debug" in /etc/sysconfig/autofs - restart the automounter - trigger a mount and wait until the timeout expires - attach the complete output (/var/log/messages) here 3. autofs configuration - attach /etc/sysconfig/autofs and /etc/auto.master here Thanks. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=758391 https://bugzilla.novell.com/show_bug.cgi?id=758391#c3 --- Comment #3 from Parameshwara Bhat <p.bhat@gramtechnet.co.in> 2012-05-02 02:02:48 UTC --- Created an attachment (id=489030) --> (http://bugzilla.novell.com/attachment.cgi?id=489030) autofs debug output in /var/log/messages -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=758391 https://bugzilla.novell.com/show_bug.cgi?id=758391#c4 --- Comment #4 from Parameshwara Bhat <p.bhat@gramtechnet.co.in> 2012-05-02 02:09:19 UTC --- Created an attachment (id=489031) --> (http://bugzilla.novell.com/attachment.cgi?id=489031) /etc/auto.master -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=758391 https://bugzilla.novell.com/show_bug.cgi?id=758391#c5 --- Comment #5 from Parameshwara Bhat <p.bhat@gramtechnet.co.in> 2012-05-02 02:10:33 UTC --- Created an attachment (id=489032) --> (http://bugzilla.novell.com/attachment.cgi?id=489032) autofs configuration -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=758391 https://bugzilla.novell.com/show_bug.cgi?id=758391#c6 --- Comment #6 from Parameshwara Bhat <p.bhat@gramtechnet.co.in> 2012-05-02 02:11:50 UTC --- Created an attachment (id=489033) --> (http://bugzilla.novell.com/attachment.cgi?id=489033) automount file -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=758391 https://bugzilla.novell.com/show_bug.cgi?id=758391#c7 --- Comment #7 from Parameshwara Bhat <p.bhat@gramtechnet.co.in> 2012-05-02 02:16:25 UTC --- (In reply to comment #2)
Please provide the following information:
1. output of "rpm -q autofs"
2. debug logs
- set DEFAULT_LOGGING="debug" in /etc/sysconfig/autofs - restart the automounter - trigger a mount and wait until the timeout expires - attach the complete output (/var/log/messages) here
3. autofs configuration
- attach /etc/sysconfig/autofs and /etc/auto.master here
Thanks.
1. pbhat@linux-u7cr:~> rpm -q autofs autofs-5.0.6-5.4.1.i586 2 & 3. Attached. 4. the automount through all this, has remained mounted, though was supposed to expire in 5 secs. See the 'mount' output below. In 11.4, the same setup used to work very well. pbhat@linux-u7cr:~> mount devtmpfs on /dev type devtmpfs (rw,relatime,size=754732k,nr_inodes=188683,mode=755) tmpfs on /dev/shm type tmpfs (rw,relatime) tmpfs on /run type tmpfs (rw,nosuid,nodev,relatime,mode=755) devpts on /dev/pts type devpts (rw,relatime,gid=5,mode=620,ptmxmode=000) /dev/mapper/system-root on / type ext4 (rw,relatime,user_xattr,acl,commit=600,barrier=1,data=ordered) proc on /proc type proc (rw,relatime) sysfs on /sys type sysfs (rw,relatime) debugfs on /sys/kernel/debug type debugfs (rw,relatime) securityfs on /sys/kernel/security type securityfs (rw,relatime) /dev/sda1 on /boot type ext4 (rw,relatime,user_xattr,acl,commit=600,barrier=1,data=ordered) /dev/mapper/system-home on /home type ext4 (rw,relatime,user_xattr,acl,commit=600,barrier=1,data=ordered) tmpfs on /var/lock type tmpfs (rw,nosuid,nodev,relatime,mode=755) tmpfs on /var/run type tmpfs (rw,nosuid,nodev,relatime,mode=755) tmpfs on /media type tmpfs (rw,nosuid,nodev,relatime,mode=755) gvfs-fuse-daemon on /home/pbhat/.gvfs type fuse.gvfs-fuse-daemon (rw,nosuid,nodev,relatime,user_id=1000,group_id=100) /home/pbhat/.automount.local on /home/pbhat/backup type autofs (rw,relatime,fd=7,pgrp=20171,timeout=5,minproto=5,maxproto=5,direct) /dev/sdb2 on /home/pbhat/backup type ext2 (rw,relatime,user_xattr,acl,barrier=1) -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=758391 https://bugzilla.novell.com/show_bug.cgi?id=758391#c Parameshwara Bhat <p.bhat@gramtechnet.co.in> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEEDINFO |NEW InfoProvider|p.bhat@gramtechnet.co.in | -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=758391 https://bugzilla.novell.com/show_bug.cgi?id=758391#c8 --- Comment #8 from Parameshwara Bhat <p.bhat@gramtechnet.co.in> 2012-06-07 13:31:32 UTC --- Hi, Any work in progress on this? Any more info needed from me ? -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=758391 https://bugzilla.novell.com/show_bug.cgi?id=758391#c Leonardo Chiquitto <lchiquitto@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #489031|application/x-master-page |text/plain mime type| | -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=758391 https://bugzilla.novell.com/show_bug.cgi?id=758391#c Leonardo Chiquitto <lchiquitto@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #489032|application/octet-stream |text/plain mime type| | -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=758391 https://bugzilla.novell.com/show_bug.cgi?id=758391#c Leonardo Chiquitto <lchiquitto@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #489033|application/octet-stream |text/plain mime type| | -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=758391 https://bugzilla.novell.com/show_bug.cgi?id=758391#c9 Leonardo Chiquitto <lchiquitto@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |NEEDINFO InfoProvider| |p.bhat@gramtechnet.co.in --- Comment #9 from Leonardo Chiquitto <lchiquitto@suse.com> 2012-07-10 21:04:34 UTC --- Sorry for the delay. It looks like something keeps /home/pbhat/backup busy. That's why AutoFS do not unmount the volume. Please run 'lsof -n /home/pbhat/backup' and check if there's some process with open files in the directory. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=758391 https://bugzilla.novell.com/show_bug.cgi?id=758391#c10 --- Comment #10 from Leonardo Chiquitto <lchiquitto@suse.com> 2012-11-07 16:59:43 UTC --- Hi, are you still facing this problem? Do you think you'll be able to provide the information requested? -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=758391 https://bugzilla.novell.com/show_bug.cgi?id=758391#c Leonardo Chiquitto <lchiquitto@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Priority|P3 - Medium |P4 - Low -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=758391 https://bugzilla.novell.com/show_bug.cgi?id=758391#c11 --- Comment #11 from Parameshwara Bhat <p.bhat@gramtechnet.co.in> 2012-11-11 08:13:02 UTC --- That configuration is no more existing. But I will be able to simulate exact conditions. Basically, my contention is, the conditions were exactly similar between 11.4 and 12.1, but behaviours were different. So, the problem must lie in the changed code. Anyway I will post back the update. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=758391 https://bugzilla.novell.com/show_bug.cgi?id=758391#c12 --- Comment #12 from Leonardo Chiquitto <lchiquitto@suse.com> 2012-11-12 11:01:15 UTC --- There's one fundamental difference between the AutoFS kernel modules from 11.4 and 12.1. This might explain why you're seeing the behavior described here. Some back ground information: Every AutoFS mount point has a timeout defined. This timeout specifies how long AutoFS will wait before trying to unmount the volume. The default timeout in our configuration (/etc/sysconfig/autofs) is 600 seconds, or 10 minutes. Every $TIMEOUT/4 seconds, AutoFS checks whether the volume is being used or not and updates the expiration timer accordingly, lets call this operation the "expiration check". This is the important difference: On kernels older than 2.6.39, the expiration check is basically asking the kernel whether the mount point can be unmounted *now*. If the kernel says 'no', it means that at least one process holds an open file in or has the current working directory set to that mount point. In this case, when the volume is effectively busy, AutoFS will reset the expiration timer. On kernels 2.6.39 and newer, the expiration check is much broader: it knows exactly when the volume was last accessed. In other words, the volume doesn't need to be busy at the time of the check for the timer to be reset: every file accessed causes a reset in the timeout. A practical example: Suppose /nfs is an automounted volume with a timeout of 60 seconds and that /nfs/file is a regular text file. If you run the following command: $ while true; do cat /nfs/file; sleep 5; done .. on openSUSE 11.4 (kernel 2.6.37), you'll notice that ~60 seconds after /nfs was mounted, it will be unmounted, regardless of the multiple accesses to /nfs/file. Few seconds after the unmount, 'cat' will trigger the mount again. .. on openSUSE 12.1 (kernel 3.1), you'll notice that as long as the command is running, the volume will NOT be unmounted. Bottom line is: on 12.1 expiring a mount point is, in general, less likely to happen. Expiration only happens when no access to files or directories inside the mount point happened during $TIMEOUT seconds. Please check if you don't have processes accessing the volume in a frequency shorter than the timeout. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=758391 https://bugzilla.novell.com/show_bug.cgi?id=758391#c13 --- Comment #13 from Parameshwara Bhat <p.bhat@gramtechnet.co.in> 2012-11-12 12:36:00 UTC --- (In reply to comment #12) Thanks for the detailed explanation. I tell you how I have used the automount. I have an Opensuse appliance which runs a Java application. I have hidden all OS functions and exposing only Java Application. Within the application, user needs to copy a iReport output to a pendrive. So, he clicks on the auto-mount point provided, pendrive is mounted, he saves in the folder and closes the report. Now in 11.4, as the unmount is set for 10 secs, before the user realises, the pendrive is unmounted and the user can safely remove the pendrive. But in 12.1, the pendrive remains mounted, the user cannot safely remove the pendrive. We have checked that even 10 minutes after the file-writing is over, in 12.1 unmounting never occurs. As the writing by the Jasperviewer to pendrive is one-time event, I do not see even in the new logic (>2.39 kernels) why un-mounting should not occur unless automount kernel module is misbehaving. But I will confirm to you by this weekend after I simulate it. ( We are in festival holidays in India). I also think the new behaviour may be undesirable. In old-time Linux, if a mounted CD was not explicitly un-mounted, CD drive would not be released. Now, in dolphin, even as the CD is listed, I click on the CD, ask for release, it will be unmounted and released. The new behaviour of automounter looks to me like the old behaviour of Linux w.r.t CD. If there is an inactive file handle lying around, it seems to not un-mount. But that would be so unlike auto-mounter. I remember using auto-mounter to un-mount the floppy drive after a certain amount of idle time, so that I do not see stale data when I quickly remove floppy and insert a new floppy. That was around 2004-2005. I think the new auto-mount would fail me in that use case. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
participants (1)
-
bugzilla_noreply@novell.com