LinuxQuestions.org
Visit the LQ Articles and Editorials section
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Password
Ubuntu This forum is for the discussion of Ubuntu Linux.

Notices

Reply
 
Search this Thread
Old 07-10-2010, 10:54 PM   #1
feffer777
LQ Newbie
 
Registered: Feb 2005
Posts: 25

Rep: Reputation: 0
CIFS share does not umount at shutdown


I have a network share mounted with cifs which does not work as expected. It should automount at boot and dismount at shutdown. It does not automount at boot, but "# mount -a" will mount it in the gui after booting finishes. This I can live with, but at shutdown or reboot, the cifs share hangs for about 30 seconds before dying. My /etc/fstab entry
Code:
# CIFS share for Sheeva backups etc
//sheeva/data-srv  /media/data-srv  cifs    auto,defaults,rw,credentials=/path-to-username-passwd
I saw a bug report about the cifs umount issue, but can't find it at the moment. I did notice that it was a very old bug. If I remember to do "# umount /media/data-srv" before rebooting, all is fine, but I seem to constantly forget and then stew as the system hangs for an extra 30-45 seconds. I've tried several things to automate it including shutdown scripts added to /etc/init.d/ and elsewhere, but nothing seems to work. Anyone have this issue and find a work-around?
 
Old 07-11-2010, 06:10 AM   #2
smoker
Senior Member
 
Registered: Oct 2004
Distribution: Fedora Core 4, 12, 13, 14, 15, 17
Posts: 2,279

Rep: Reputation: 248Reputation: 248Reputation: 248
30 seconds is such a big problem ?
As for mounting at boot, see this post.
 
0 members found this post helpful.
Old 07-13-2010, 06:35 AM   #3
jschiwal
Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 654Reputation: 654Reputation: 654Reputation: 654Reputation: 654Reputation: 654
If you use the _netdev option, mounting the share will be deferred until the network is ready.

As to the time it takes to unmount, it may depend partly on how the share is mounted and how the device at the server is mounted. The async option allows asyncronous updates & caching. This will improve performance while you are using the device but unsynced data needs to be written to the device before it can be umounted.

30 seconds may be a time-out value for something that is failing. The kernel logs or samba logs may indicate the cause. If you can correct, you may be able to umount the drive quicker.
 
Old 07-15-2010, 03:20 AM   #4
jschiwal
Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 654Reputation: 654Reputation: 654Reputation: 654Reputation: 654Reputation: 654
You might also look at configuring automount. This will automatically mount directories when you enter them and unmount them if you haven't used them for a while. In other words, the directory may be unmounted already, so if you are shutting down for example, you won't have a delay.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
The system does not umount filesystems on shutdown or restart ctrl0l Linux - General 3 06-03-2009 03:20 PM
samba CIFS umount hangs if disconnecting network Benanzo Linux - Networking 3 04-13-2007 08:30 AM
HDD failure after shutdown. Umount tmpfs fails. Clemente Linux - Hardware 1 04-02-2006 08:28 AM
umount on shutdown plisken Linux - General 1 10-02-2003 04:14 PM
ext3 part fails umount during shutdown paulmccs Linux - General 0 02-18-2002 01:22 PM


All times are GMT -5. The time now is 12:19 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration