Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
tmp not unmounting on shutdown/reboot
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
amasidlover
Apprentice
Apprentice


Joined: 16 Jun 2002
Posts: 275
Location: Manchester, UK

PostPosted: Tue Jan 29, 2013 8:41 am    Post subject: tmp not unmounting on shutdown/reboot Reply with quote

Hi,

I have two gentoo machines that no longer shutdown properly and simply hang at unmounting tmp - by that point I've got no console access so can't investigate further. I've searched the forums (including using Google) but can't find anyone else with this issue, however I've now got two machines doing it and I'm concerned that having to reset/unplug the machine to get it to reboot once it hangs is going to cause disk corruption before long.

Any ideas?
_________________
http://www.axiomtech.co.uk
http://www.zednax.com
Back to top
View user's profile Send private message
nanoczar
Apprentice
Apprentice


Joined: 10 Dec 2002
Posts: 189
Location: Henderson, TN

PostPosted: Tue Jan 29, 2013 5:20 pm    Post subject: Reply with quote

Do you happen to have a RAID setup?
_________________
Don't fight the LaTeX. WORK with the LaTeX!! Become one with the LaTeX!!! - JIC
Back to top
View user's profile Send private message
amasidlover
Apprentice
Apprentice


Joined: 16 Jun 2002
Posts: 275
Location: Manchester, UK

PostPosted: Tue Jan 29, 2013 8:47 pm    Post subject: Reply with quote

No, both machines are standard SATA, one is an SSD the other is a mechanical (magnetic platter) disk.

What would be the possible issue if it was RAID (in case it inspires me to the answer)?

Thanks! Alex
_________________
http://www.axiomtech.co.uk
http://www.zednax.com
Back to top
View user's profile Send private message
nanoczar
Apprentice
Apprentice


Joined: 10 Dec 2002
Posts: 189
Location: Henderson, TN

PostPosted: Tue Jan 29, 2013 11:30 pm    Post subject: Reply with quote

I had a strange problem like this and had to add an init script to take care of things...but I'm using a RAID system.

What's the exact error that it spits out as your trying to shutdown?

Do you have tmpfs in your kernel?
_________________
Don't fight the LaTeX. WORK with the LaTeX!! Become one with the LaTeX!!! - JIC
Back to top
View user's profile Send private message
amasidlover
Apprentice
Apprentice


Joined: 16 Jun 2002
Posts: 275
Location: Manchester, UK

PostPosted: Wed Jan 30, 2013 9:33 am    Post subject: Reply with quote

There is no error...

From memory it just says

Code:
Unmounting /tmp


and that's it, it just sits there, as if it is waiting for a process to release an open file on /tmp - however, without console access at that point I can't check what process it is...

tmpfs is compiled into the kernel.

I've just updated to kernel 3.6.11 to allow udev 197 to work - if the problem persists I might try adding lsof/fuser of /tmp to the unmount of local filesystem so it logs/displays what has files open there (if anything).

What did your init script do? unmount /tmp with -l ?

Thanks,

Alex
_________________
http://www.axiomtech.co.uk
http://www.zednax.com
Back to top
View user's profile Send private message
luciano
Tux's lil' helper
Tux's lil' helper


Joined: 18 Nov 2004
Posts: 92

PostPosted: Mon Apr 15, 2013 11:24 pm    Post subject: Reply with quote

Did you find a solution?

I appear to be having this same problem. I have kernel 3.7.10 and udev-197-r8. Now my boot partition is getting corrupted beacause of this.

I have /tmp mounted on tmpfs. It's not clear from your post but it also appears to be the case for you.

Could you tell me if you have ACL list enabled (CONFIG_TMPFS_POSIX_ACL)? Also, do you have any nfs mounts, or use pam_mount by any chance?
Back to top
View user's profile Send private message
amasidlover
Apprentice
Apprentice


Joined: 16 Jun 2002
Posts: 275
Location: Manchester, UK

PostPosted: Tue Apr 16, 2013 8:18 am    Post subject: Reply with quote

The best I could come up with was a workaround which was to stop using tmpfs, i.e., comment out the tmp entry in /etc/fstab.
_________________
http://www.axiomtech.co.uk
http://www.zednax.com
Back to top
View user's profile Send private message
luciano
Tux's lil' helper
Tux's lil' helper


Joined: 18 Nov 2004
Posts: 92

PostPosted: Fri Apr 19, 2013 12:55 pm    Post subject: Reply with quote

Still appears to be occuring, but it looks like the culprit is a buggy pulseaudio which respawns constantly when it is shutdown ... I will try disabling this, but it happens intermittently so it's difficult to find the cause.
Back to top
View user's profile Send private message
amasidlover
Apprentice
Apprentice


Joined: 16 Jun 2002
Posts: 275
Location: Manchester, UK

PostPosted: Mon Apr 22, 2013 9:20 am    Post subject: Reply with quote

luciano wrote:

Could you tell me if you have ACL list enabled (CONFIG_TMPFS_POSIX_ACL)? Also, do you have any nfs mounts, or use pam_mount by any chance?


Yes to all three I'm afraid so that doesn't narrow it down...
_________________
http://www.axiomtech.co.uk
http://www.zednax.com
Back to top
View user's profile Send private message
actionbuddha
n00b
n00b


Joined: 22 May 2008
Posts: 5

PostPosted: Fri May 10, 2013 9:09 am    Post subject: Reply with quote

luciano wrote:
Did you find a solution?
Could you tell me if you have ACL list enabled (CONFIG_TMPFS_POSIX_ACL)? Also, do you have any nfs mounts, or use pam_mount by any chance?


Same problem here on all my machines which have nfs mounts. Kerberised nfs, if that makes a difference. If I carefully kill all pids that have any handles to an nfs mount before reboot, seems to work ok.

As an example, typing reboot at a root prompt in KDE is guaranteed to cause a hang. Using KDE's own reboot option, which cleans up desktop processes before bouncing, works well, unless there's an underlying tmux session with additional handles.
Back to top
View user's profile Send private message
luciano
Tux's lil' helper
Tux's lil' helper


Joined: 18 Nov 2004
Posts: 92

PostPosted: Sat Jun 08, 2013 7:21 pm    Post subject: Reply with quote

Just to update this in case anybody else is interested, the problem appears to have stopped occurring after I updated pulse audio to v3. It appears that (as stated elsewhere on teh forums) there are some file handles left open. I also changed a config option in pulse audio settings (can't remember exactly what it was) which controls respawning.
Back to top
View user's profile Send private message
actionbuddha
n00b
n00b


Joined: 22 May 2008
Posts: 5

PostPosted: Mon Jul 08, 2013 11:17 am    Post subject: Reply with quote

I've had some success with the following patch to /etc/init.d/nfsmount:

--- /etc/init.d/nfsmount.orig 2013-07-08 11:48:24.037171098 +0100
+++ /etc/init.d/nfsmount 2013-07-08 11:55:43.278235733 +0100
@@ -42,6 +42,9 @@
}

stop() {
+ ebegin "Killing all processes with open handles on nfs mounts"
+ for fs in $(findmnt -t nfs,nfs4 -n | awk -e '{print $1}'); do fuser -skm $fs; done
+ eend $?
ebegin "Unmounting NFS filesystems"
umount -a -t nfs,nfs4
eend $?

Essentially kill all processes with open handles to nfs mounts. I now find /tmp unmounts cleanly and the machine reboots remotely. YMMV.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum