Ask Ubuntu is a question and answer site for Ubuntu users and developers. 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 am using Lubuntu 11.10, and the commands:

sudo shutdown


sudo halt

do not shutdown my system. Instead the computer hangs at the shutdown screen that appears just before powering off. From that point on it just does nothing. Any ideas on why this happens?

share|improve this question
What version of Lubuntu are you running? Does shutting down from the power menu on the upper-right corner of the screen also not work? – Eliah Kagan Apr 22 '12 at 4:09

Check the file /etc/default/halt This file contains a variable setting that tells halt how it should behave.


   The following variables can be set.

   HALT   If set to poweroff the system will be powered down after it  has
          been brought down. This is the default.
          If  set to halt the system will only be halted after it has been
          brought down. What exactly this means depends on your hardware.

          Setting this to no prevents  shutdown  from  shutting  down  the
          network  intefaces.   This  is  necessary  to  use  Wake-On-Lan.
          Setting it to yes causes shutdown to also bring down the network
          interfaces  (and  thus  prevent  the machine from being woken up

HALT is probably set to halt instead of poweroff.

From my system: more /etc/default/halt

# Default behaviour of shutdown -h / halt. Set to "halt" or "poweroff".
share|improve this answer

My understanding that "halt" means exactly the behavior you're observing - all the processes are terminated and the machine is halted (i.e. "stays stuck ... just before shutting down") - which was the only possible behaviour in old days when machines had no ACPI capabilities - first you halt the machine and then flip the power switch manually.

A related command called poweroff gracefully terminates all processes and then issues an ACPI call which powers the machine off.

However, as Rinzwind points out, the exact behaviour of halt command can be changed by editing /etc/default/halt, so it is possible to make it to behave like poweroff.


sudo poweroff


sudo shutdown -P now
share|improve this answer
well, I've been using halt for many years, and it turns off the PC here. – Janus Troelsen Apr 22 '12 at 8:02
@Ysangkok: Check out answers to this question:… - also, man shutdown clearly implies that there's a difference between poweroff and halt although it's not very clear what the difference is, and also for shutdown -h now it says "Requests that the system be either halted or powered off after it has been brought down, with the choice as to which left up to the system". So, I suppose, halt command may or may not power the system off, depending on the phase of the moon. – Sergey Apr 22 '12 at 10:53

I always use shutdown -h now.

share|improve this answer

Halt and poweroff

sudo shutdown -hP now
share|improve this answer
Why not just sudo shutdown -P now ? – belacqua Apr 29 '12 at 2:32

The simple thing to do is follow the directions below. This is what I have done and everything started working okay now for me and some of my co-workers' workstation/Laptop.

If you are using Ubuntu 11.04, 11.10, and 12.04, open command line and run the following command:

$ gksudo gedit /etc/default/halt

Now that you have your Vi or Gedit - Editor open, add this below in your file as shown INIT_HALT = POWEROFF. Hope this helps you as it has for me.

Halt Script:

# Default behaviour of shutdown -h / halt. Set to "halt" or "poweroff".
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.