Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a fresh installation of Ubuntu Server. "reboot" works, but shutdown fails on the * Killing all remaining processes... step. I am using:

sudo shutdown now

After the failure, indicated by [fail] (with "fail" in red), I get this message:

 * will now switch to single-user mode

with no other error messages. The user is root after the program exits.

Any ideas about how to trouble-shoot this, or what the problem might be?

The Ubuntu version is 11.10 and I ran sudo aptitude update && sudo aptitude dist-upgrade before this.

share|improve this question
    
I am experiencing exactly the same issue. – Kouber Saparev Dec 28 '11 at 22:28
    
See if this helps. it forced the shutdown, though the red "failed" didn't disappear. – user113733 Jan 15 '12 at 13:53
    
Does the sudo poweroff make the problem go away? – pbies Dec 5 '13 at 13:43
up vote 36 down vote accepted

I've experienced the same, so I had to use halt which worked

shutdown -h now
share|improve this answer
3  
This may require sudo to run – Simon Sheehan Jan 20 '12 at 1:20
    
Is there any explanation on why this is necessary? I have the above problem on a 13.10 distro and even the "shutdown -h now" variant does not work. The only way I can recover from this -- it seems -- is to reboot -f now but this skips the whole shutdown process and can't be good for the long-term health of the system. – ken Nov 27 '13 at 18:45
    
This works, though not really sure why the other one fails. – Nuno Furtado Dec 2 '13 at 14:04
1  
@user19726 - see other answers for why the simple shutdown "fails" (it is actually not failing, it is simply going to single user mode, rather than straight to halt condition). – condiosluzverde Mar 12 '14 at 15:32

From the man pages of shutdown:

... runlevel 1 is used to put to system into a state where administrative tasks can be per- formed; this is the default if neither the -h or -r flag is given to shutdown."

shutdown shuts the system down from a user perspective, as linux is designed as a multi-user system, hence the system-wide message and optional time delay.

To shutdown the machine, use the -h option.

And I wouldn't worry about some processes that couldn't be killed in time, which is probably the meaning of the [fail] message you got.

share|improve this answer
    
As a total Noob to Linux, and seeking to up my skills, I prefer to be worried about anything that fails. I want to know Linux to the point where I can run in on the open public internet. That said, I voted for this answer: quotes the man page and explains the default behavior. I'm tempted to remove the "And I wouldn't worry..." at the end - what value does that add? – condiosluzverde Mar 12 '14 at 15:27

I encountered this when trying to reboot with sudo reboot now. sudo shutdown now also failed. In both cases, the system switched to single-user mode and stalled.

Halting the system isn't feasible, since it is remote and I don't want to trek to the basement to turn it back on. What worked is sudo shutdown -r 0.

I'm running Ubuntu 13.04 server on an Asus Aspire One netbook.

I know this thread is old, but I'm experiencing this problem with a current distro.

share|improve this answer
1  
Thanks for posting this: Ubuntu 13.04 refused to reboot properly without the shutdown -r 0 command. – ojdo Sep 27 '13 at 22:44
1  
sudo shutdown -h -r worked for me, not sure on the differences. – Tracker1 Nov 19 '13 at 22:01
    
Voted this up for adding perspective for the person running a physical not-nearby machine - not everyone is in a situation to turn the machine off - I am because: using a VM locally and in the cloud - both places where a machine can be turned off and started via locally available keyboard/cloud control panel. – condiosluzverde Mar 12 '14 at 15:30

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .