LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Hardware (https://www.linuxquestions.org/questions/linux-hardware-18/)
-   -   Computer wont shutdown (https://www.linuxquestions.org/questions/linux-hardware-18/computer-wont-shutdown-940051/)

bteeuwen170 04-16-2012 09:06 AM

Computer wont shutdown
 
Hi guys,

I have a problem with my 4 jears old Packerd Bell computer. It's a dual-boot with Windows XP, Ubuntu 11.04 and Pinguy. When i boot into Ubuntu or Pinguy and then shutdown the computer the system simply reboots. Ive tried to enter poweroff or shutdown -f or halt shutdown -h but the system only reboot. But if i use Windows XP and then shutdown the computer the system normally shutdown. This is a very annoying problem! Can anyone please help me???

Sorry for my bad english... I live in the Netherlands

teckk 04-16-2012 01:04 PM

How about
Code:

#shutdown -h now
http://unixhelp.ed.ac.uk/CGI/man-cgi?shutdown+8

Kenarkies 04-16-2012 08:42 PM

Quote:

Originally Posted by bteeuwen170 (Post 4654124)
Hi guys,

I have a problem with my 4 jears old Packerd Bell computer. It's a dual-boot with Windows XP, Ubuntu 11.04 and Pinguy. When i boot into Ubuntu or Pinguy and then shutdown the computer the system simply reboots. Ive tried to enter poweroff or shutdown -f or halt shutdown -h but the system only reboot. But if i use Windows XP and then shutdown the computer the system normally shutdown. This is a very annoying problem! Can anyone please help me???

Sorry for my bad english... I live in the Netherlands

shutdown -h should have done it, although I assume you are using a time specification as the man page seems to require it (normally using now for desktops). There is an option shutdown -P to force poweroff. Still I wonder if there is some BIOS setting causing this behaviour.

Ken

JZL240I-U 04-17-2012 02:40 AM

Shutdown -P is for *BSD systems AFAIK. On many Linux installs shutdown is only for root. You have to enable it in the system settings (sorry, I use KDE, I don't know where to switch it on in your systems).

ronlau9 04-17-2012 07:22 AM

In most linux distro only root can shutdown the system .
The command is
sudo shutdown -h now
It will ask for root password.

JZL240I-U 04-17-2012 07:25 AM

Quote:

Originally Posted by ronlau9 (Post 4654986)
...
sudo shutdown -h now
It will ask for root password.

The OP has Ubuntu as his system. As I understand it, Ubuntu sudo asks for the user's password?!?

jefro 04-17-2012 03:58 PM

Might try to log off from the gui and then use the welcome screen to do shutdown. (if you have it)

Kenarkies 04-17-2012 07:18 PM

Quote:

Originally Posted by JZL240I-U (Post 4654993)
The OP has Ubuntu as his system. As I understand it, Ubuntu sudo asks for the user's password?!?

Just a clarification.
Code:

sudo shutdown -P now
works fine on Ubuntu. Also sudo does ask for the current user's password but if you are doing lots of sudo's, and aren't overly worried about security, you can avoid that by adding in the /etc/sudoers file (using visudo)
Code:

username ALL=NOPASSWD: ALL
where "username" is your normal username (if desired replace the second ALL with specific applications, eg /sbin/shutdown).

In any case this is not the best way to shutdown if you are using a desktop. It should work naturally from the GUI.

Ken

bteeuwen170 04-18-2012 07:36 AM

sudo shutdown -P now works! Thank you very much!!!


All times are GMT -5. The time now is 08:25 AM.