LinuxAnswers - the LQ Linux tutorial section.
Go Back > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Debian This forum is for the discussion of Debian Linux.


  Search this Thread
Old 05-23-2013, 03:58 PM   #1
Thomas Mueller
LQ Newbie
Registered: Feb 2013
Posts: 11

Rep: Reputation: Disabled
Shutdown sequence stops before end

When shutting down my wheezy installation, it stops after rsyslog: syslogd.

Mister Google told me it may have to do with NTFS network mounts and indeed, if I ran umount /mnt/Jobe prior to the shutdown process, it finishes correctly.

Since I am too lazy to run that command manually every time, I tried to put it in a shutdownscript like that:

#! /bin/sh
# Provides:          umountJobe
# Required-Start:    $remote_fs $syslog
# Required-Stop:     $remote_fs $syslog
# Default-Start:     
# Default-Stop:      0 6
# Short-Description: Example initscript
# Description:       This file should be used to construct scripts to be
#                    placed in /etc/init.d.

echo "unmounting Jobe"

umount /mnt/Jobe

exit 0
and I ran
update-rc.d stop 01 0 6 .
And indeed it appeared in my shutdown sequence, but to no real effect. If anything it stopped at a different command (winbind daemon instead of rsyslogd).
Occasionally it finishes the shutdown sequence, but I am not able to reproduce it.
The K01umountJobe Symlink in rc0.d and rc6.d seem to be OK.

Any idea what I did wrong?
Old 05-24-2013, 10:42 AM   #2
Senior Member
Registered: Mar 2011
Location: Milford, MA. USA
Distribution: MINT Debian, Angstrom, SUSE, Ubuntu
Posts: 2,674
Blog Entries: 9

Rep: Reputation: 898Reputation: 898Reputation: 898Reputation: 898Reputation: 898Reputation: 898Reputation: 898
How are you invoking shutdown? Are you using poweroff, or using shutdown directly?

shutdown -h now
usually works. As does poweroff. Note that the -h means to halt the processor, thereby in most systems making it power down.

I feel it should shutdown no matter what you have mounted by the way.

If when you do this via command line, you at least put in some delay because you're typing, a script run during shutdown has no delay. Perhaps you can write another script to unmount your partition and then call shutdown/poweroff in the script and see if it's a too fast occurrence which is blocking the poweroff. Another test is if you invoke shutdown, verify that the rc.d script does run, that your umount did occur. If not, then something's wrong there.
Old 05-26-2013, 11:04 AM   #3
Thomas Mueller
LQ Newbie
Registered: Feb 2013
Posts: 11

Original Poster
Rep: Reputation: Disabled
Thanks for the reply.

I am using
shutdown -h now
, or the Shut Down Button of my XFCE4 desktop.
When I manually unmount the drive and then run shutdown, I receive a message that it can not be unmounted, because it is not mounted. So I believe the rc.d script is working.

Regarding the delay, I had a
sleep 5
command in the script, but that changed nothing. I will try a higher value and report back.
Old 05-27-2013, 03:39 PM   #4
Thomas Mueller
LQ Newbie
Registered: Feb 2013
Posts: 11

Original Poster
Rep: Reputation: Disabled
Problem solved. Look


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
Are results sent to an output file only at the end of a command sequence? Zebe Linux - Newbie 2 03-19-2009 06:34 PM
rc.d startup/shutdown sequence G00fy Linux - General 3 08-21-2008 01:41 AM
Need help adding a script to shutdown sequence trapix22 Linux - Newbie 1 12-29-2007 01:08 AM
boot sequence stops before login prompt rdnelson Linux - General 2 10-18-2004 09:56 AM
Knoppiz, Why go through shutdown sequence? jlturbos Linux - Distributions 3 02-09-2004 09:06 PM

All times are GMT -5. The time now is 09:57 AM.

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