Bug 650009

Summary: automount hangs on startup when started with an already mounted cifs share
Product: Red Hat Enterprise Linux 6 Reporter: Ian Kent <ikent>
Component: autofsAssignee: Ian Kent <ikent>
Status: CLOSED ERRATA QA Contact: yanfu,wang <yanwang>
Severity: urgent Docs Contact:
Priority: urgent    
Version: 6.0CC: dejohnso, eguan, ikent, jmoyer, jnansi, jwest, kzhang, rwheeler, sprabhu, syeghiay
Target Milestone: rcKeywords: ZStream
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: autofs-5.0.5-25.el6 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: 589573
: 650010 (view as bug list) Environment:
Last Closed: 2011-05-19 14:22:52 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 589573    
Bug Blocks: 650010, 689754    

Comment 2 yanfu,wang 2011-02-23 08:37:30 UTC
reproduced on rhel5.5 as comment #0:
[root@hp-bl490cg6-01 ~]# uname -a
Linux hp-bl490cg6-01.rhts.eng.bos.redhat.com 2.6.18-194.el5 #1 SMP Tue Mar 16 21:52:39 EDT 2010 x86_64 x86_64 x86_64 GNU/Linux
[root@hp-bl490cg6-01 ~]# rpm -qa|grep autofs
autofs-5.0.1-0.rc2.143.el5
[root@hp-bl490cg6-01 ~]# rpm -qa|grep samba
samba-common-3.0.33-3.28.el5
samba-client-3.0.33-3.28.el5
samba-3.0.33-3.28.el5
[root@hp-bl490cg6-01 ~]# service autofs start
Starting automount:  

verified against new package on i386 and x86_64:
[root@dell-pe2800-01 ~]# uname -a
Linux dell-pe2800-01.rhts.eng.bos.redhat.com 2.6.32-71.el6.x86_64 #1 SMP Wed Sep 1 01:33:01 EDT 2010 x86_64 x86_64 x86_64 GNU/Linux
[root@dell-pe2800-01 ~]# rpm -qa|grep autofs
autofs-5.0.5-29.el6.x86_64
[root@dell-pe2800-01 ~]# rpm -qa|grep samba
samba-3.5.4-68.el6.x86_64
samba-common-3.5.4-68.el6.x86_64
samba-client-3.5.4-68.el6.x86_64
samba-winbind-clients-3.5.4-68.el6.x86_64

[root@dell-pe2800-01 ~]# mkdir /testdir_A
[root@dell-pe2800-01 ~]# 
[root@dell-pe2800-01 ~]# mkdir /testdir_B
[root@dell-pe2800-01 ~]# echo "This is testB" > /testdir_B/testB
[root@dell-pe2800-01 ~]# setenforce 0
[root@dell-pe2800-01 ~]# mkdir /testdir_samba_A
[root@dell-pe2800-01 ~]# mkdir /testdir_samba_B
[root@dell-pe2800-01 ~]# echo "This is sambaB" > /testdir_samba_B/sambaB
[root@dell-pe2800-01 ~]# vim /etc/auto.master
[root@dell-pe2800-01 ~]# echo "test1   --bind     :/testdir_B" > /etc/auto.testmap
[root@dell-pe2800-01 ~]# 
[root@dell-pe2800-01 ~]# vim /etc/samba/smb.conf 
[root@dell-pe2800-01 ~]# service smb restart
Shutting down SMB services: [FAILED]
Starting SMB services: [  OK  ]
[root@dell-pe2800-01 ~]# service autofs restart
Starting automount: [  OK  ]
[root@dell-pe2800-01 ~]# cat /testdir_A/test1/testB
This is testB
[root@dell-pe2800-01 ~]# 
[root@dell-pe2800-01 ~]# cat /testdir_samba_A/127.0.0.1/automounttest/sambaB
This is sambaB
[root@dell-pe2800-01 ~]# sleep 1d > /testdir_samba_A/127.0.0.1/automounttest/hoge &
[1] 4149
[root@dell-pe2800-01 ~]# service autofs stop
Stopping automount: 
[  OK  ]
[root@dell-pe2800-01 ~]# 
[root@dell-pe2800-01 ~]# mount
...
//127.0.0.1/automounttest/ on /testdir_samba_A/127.0.0.1/automounttest type cifs (rw,mand)
[root@dell-pe2800-01 ~]# pkill sleep
[1]+  已终止               sleep 1d > /testdir_samba_A/127.0.0.1/automounttest/hoge
[root@dell-pe2800-01 ~]# mount
/dev/mapper/vg_dellpe280001-lv_root on / type ext4 (rw)
proc on /proc type proc (rw)
sysfs on /sys type sysfs (rw)
devpts on /dev/pts type devpts (rw,gid=5,mode=620)
tmpfs on /dev/shm type tmpfs (rw,rootcontext="system_u:object_r:tmpfs_t:s0")
/dev/sda1 on /boot type ext4 (rw)
/dev/mapper/vg_dellpe280001-lv_home on /home type ext4 (rw)
none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw)
//127.0.0.1/automounttest/ on /testdir_samba_A/127.0.0.1/automounttest type cifs (rw,mand)
[root@dell-pe2800-01 ~]# service autofs start
Starting automount: [  OK  ]
[root@dell-pe2800-01 ~]# cat /testdir_A/test1/testB
This is testB

Comment 3 Ian Kent 2011-03-22 03:20:28 UTC
*** Bug 689451 has been marked as a duplicate of this bug. ***

Comment 7 errata-xmlrpc 2011-05-19 14:22:52 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2011-0753.html