Skip to main content

All Questions

Tagged with
48 votes
8 answers
140k views

Unable to shutdown / reboot my Debian 10 server

I'm trying to reboot my Debian 10 server but all I get is command not found. I've tried: shutdown reboot restart poweroff but nothing works. I found this thread but when I try to run any of this with ...
BDevGW's user avatar
  • 635
43 votes
3 answers
38k views

Ubuntu shutdown fail "* Killing all remaining processes..."

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 [...
jtpereyda's user avatar
  • 2,487
37 votes
9 answers
94k views

How to shutdown a computer instantly (1 to 5 secs) without using a physical switch/socket?

Is there any command / program via which I may shutdown my system instantly (1 to 5 secs)? Update (2015): Thank you to those who have suggested to turn off using the power socket. :D Update (2016): @...
Uthman's user avatar
  • 977
26 votes
1 answer
31k views

Shutdown Windows 10 truly for a dual booting system

It seems that "Shut down" in Windows 10 actually means "Shut down and hibernate". This has caused my NTFS partitions cannot be automatically loaded on Linux (Ubuntu 16.04) on my dual-booting laptop. ...
Xiaodong Qi's user avatar
25 votes
2 answers
36k views

How do I run a script before everything else on shutdown with systemd?

Note: Briefly formulated question can be found at the bottom. I have a script which makes a backup of my files onto an external USB drive. Executing it can take a while, depending on the amount of ...
le_me's user avatar
  • 531
22 votes
2 answers
24k views

Have UPS shut down computer automatically in Linux when the power goes out

I'm wondering that I could not find anything useful on Google. I'm using a cheap UPS which actually does keep my computer powered for awhile if there are some electricity issues (they are very common ...
Spaceman's user avatar
  • 373
19 votes
6 answers
46k views

How can I disable the "Chromium didn’t shut down correctly" message when my browser opens?

I am running Chromium 39 on Ubuntu 14.04, on a single-board computer (ODROID U3, though I believe the question is applicable to Chromium on any Ubuntu system and possibly other Linux distros as well). ...
Doktor J's user avatar
  • 2,393
19 votes
1 answer
3k views

Are there any good reasons for halting system without cutting power?

Are there any good reasons to halt a system without switching off power to the hardware? I mean using the halt command without using the -p switch. I haven’t been able to find an answer on the ...
Zafan's user avatar
  • 193
19 votes
1 answer
38k views

What is the difference between the shutdown, halt and reboot commands?

Should I be using one or the other for different things?
loosecannon's user avatar
15 votes
4 answers
53k views

Linux shutdown in 30 seconds?

Simple question: what params can be used to shutdown a computer running Linux/OSX in 30 seconds? I've always run Windows, where I would go shutdown -s -t 30 but the parameters are different. I've ...
icnhzabot's user avatar
  • 253
12 votes
1 answer
6k views

How does systemctl schedule system shutdown?

When I type shutdown -h +30, Linux somehow schedules runlevel's change within 30 minutes. On Debian, /sbin/shutdown is symbolic link to /bin/systemctl. My tests indicate that shutdown does not use ...
patryk.beza's user avatar
  • 1,591
8 votes
10 answers
93k views

How to shut down a computer having a particular IP address?

If we have a collection of Windows and Linux computers on a LAN, is it possible to shutdown a computer having a specific IP address, using the Linux shell? Assume that I do not have ssh or telnet ...
Rohit Banga's user avatar
  • 2,464
8 votes
3 answers
4k views

My computer reboots when I tell it to shutdown

There are about 40 computers at work with this problem. They all have an ASUS P5KPL/1600 motherboard. They are all running SUSE Linux 11.1. When I tell the computer to shutdown either through the UI ...
Stacey Richards's user avatar
6 votes
6 answers
19k views

Shut down computer using ssh

What ways are there to shut down a computer using ssh? I'm running on linux and when I try to shut it down remotely using ssh, it doesn't actually work. I used the command sudo shutdown now. ...
KalSae's user avatar
  • 67
6 votes
4 answers
2k views

Does shutdown/reboot need root privileges under Linux? [closed]

Why do I need to be root to shutdown/reboot my computer from the terminal? Doing so via the GUI menu doesn't require root privileges.
boh's user avatar
  • 213
6 votes
1 answer
4k views

How can I catch or stop a Linux shut down from the terminal?

Is there a way to catch or stop a Linux shut down after a reboot, halt or shutdown command has been entered? sudo shutdown -r +10 I should now have 10 minutes before the computer shuts down. If I ...
nelaaro's user avatar
  • 13.8k
5 votes
3 answers
7k views

What is the proper way to enable a normal user to shutdown, halt or reboot the computer?

My dirty solution is to chmod +s /sbin/shutdown. It works but this is probably not good practice and insecure. Moreover after some system updates the suid bit gets reset. What would be the correct way ...
ccpizza's user avatar
  • 7,883
5 votes
1 answer
341 views

Poweroff , damages hardware?

So i've been using poweroff command to shutdown my computer at a specific hour. Is it okay for the hardware to do this (e.g hard drives)? Or should I use other system call?
Fisher's user avatar
  • 213
5 votes
5 answers
5k views

Execute script before shutting down in Ubuntu

When I shut down my computer I want to show some pending tasks that I have to do before leaving the office. I have a local application to manage those tasks, so basically I just want to run a command,...
juanefren's user avatar
  • 327
5 votes
1 answer
3k views

Run a script on systemd service ONLY at shutdown not restart

[Unit] Description=test Before=shutdown.target [Service] ExecStart=/bin/true ExecStop=/usr/local/bin/test.sh RemainAfterExit=yes [Install] WantedBy=multi-user.target I tried a lots of ...
user avatar
5 votes
1 answer
1k views

Run script before other units stop on shutdown

I need to run a script before a set of other services on my machine stop when shutting the machine down. (In my case, terminating an EC2 instance.) I have tried variations on the answer in this ...
2rs2ts's user avatar
  • 717
4 votes
3 answers
3k views

How do I shutdown a Linux box without running init 0

I want to shutdown my computer as if power was cut off (don't ask me why). How do I do this under Linux?
Alexandru's user avatar
  • 355
4 votes
3 answers
3k views

A keyboard shortcut for the "status menu" in GNOME 3

Is there a keyboard shortcut, or can a keyboard shortcut be defined, to open the GNOME 3 "status menu" (the one in the upper right corner with your name on it that you use to log out, restart or shut ...
Lyubomir's user avatar
4 votes
1 answer
1k views

system-wide crontab vs. user crontab to shutdown pc

I'm trying to shutdwon my pc at 2 am once a week. If I use the user crontab of root (sudo crontab -e) 30 2 * * 3 shutdown -h now the shutdown will not be performed. However, if I place the same ...
Philippe's user avatar
  • 937
4 votes
2 answers
1k views

Shutdown Ubuntu Command

What is the command or application that allows a user to shutdown the computer from gnome. And how does it have privileges while halt requires superuser?
agz's user avatar
  • 8,328
4 votes
2 answers
3k views

Will the linux "shutdown" command allow a parameter to determine the pause between sending SIGTERM and SIGKILL?

The man page seems to indicate no. There is /etc/rc.d/init.d/halt on Fedora. It has a hard coded pause in it, but there's got to be a better way than to change that script. Any help would be ...
s2cuts's user avatar
  • 41
4 votes
2 answers
19k views

Why does net rpc shutdown fail with the right credentials?

The command $ net rpc SHUTDOWN -f -I xxx.xxx.xxx.xxx -U uname%psswd Fails with the following errors: Could not connect to server xxx.xxx.xxx.xxx The username or password was not correct. ...
brice's user avatar
  • 2,377
4 votes
3 answers
3k views

How do I shutdown Slitaz from terminal?

I have Slitaz installed on my home server and the only way of interfacing with it is through and SSH connection. I have tried shutdown -h now But it only tells me shutdown is not a command So I ...
Jonno_FTW's user avatar
  • 1,560
4 votes
0 answers
515 views

Autorun zerofree on boot (or on shutdown)

I have a virtualbox vitual server that keeps growing. To keep its virtual disk small I'm manually shrinking it using VBoxManage modifyhd disk.vdi compart after zeroing unused space on the disk using ...
martin.macko.47's user avatar
3 votes
1 answer
3k views

When I quit xmonad, how can I make it shut down applications nicely?

When I quit xmonad (Shift-Mod-Q), it kills all my running applications. This results in me losing my recent terminal history in gnome-terminal and in Chromium complaining on the next start up that it ...
Jonatan Kallus's user avatar
3 votes
2 answers
1k views

How to restrict use of a computer?

Suppose that some person is insomniac because of a bad habit of chatting on the IRC every night until 3AM. That completely ruins this person's life because he is unable to wake up on time to attend ...
Benoit's user avatar
  • 7,043
3 votes
2 answers
225 views

Shutting down your computer, and bringing it back up

I know a lot of people just leave their desktops on all night (including me) and resume zombi-ness in the morning. However, other than possible memory leaks, what are the pitfalls of this? I've seen ...
nopcorn's user avatar
  • 16.7k
3 votes
2 answers
253 views

Do Linux Live CDs properly shut down USB devices when you power off?

I’ve been using a Live CD with a USB drive that has my KeePassX database on it, when I shut the system down I noticed that the USB light doesn’t shut off before it asks me to remove the media (CD) and ...
pop023490's user avatar
3 votes
1 answer
797 views

How to impede Linux shutting down my computer unless I explicitly want it?

This is a very general question. Let's say that some unwanted process randomly sends the shutdown signal and thus turns my server down. I don't manage to find the offending program, but I badly need ...
Mephisto's user avatar
  • 241
3 votes
1 answer
3k views

How to register shutdown script on Amazon Linux in AWS EC2

I am using Amazon Linux (RH-based distro) in AWS EC2. I followed the structure of /usr/share/doc/initscripts-*/sysvinitfiles to create an init script in /etc/init.d. /etc/init.d/do_something #!/bin/...
vovel's user avatar
  • 31
3 votes
0 answers
284 views

Preventing unused spare hdd from spinning up during suspend and shutdown

I recently replaced my sata hdd with an ssd, and keeping the hdd in as a spare. It's not used, not event mounted to filesystem. Yet, when suspending or shutting down the system, it quickly spins up, ...
altunyurt's user avatar
  • 131
2 votes
2 answers
1k views

how to properly (or alternatively?) shutdown linux from terminal?

I wrote sudo shutdown now on my ubuntu VM terminal and the results were not what i expected. I expected results similar to shutting down through the desktop GUI but instead it shut down rather quickly ...
user avatar
2 votes
1 answer
10k views

how to shut down a server from the webinterface

I want to be able to shutdown my server remotely by clicking on a button on a web page. The server runs Ubuntu 14.04.1 64 Bit and a python web application. I have not decided which yet, but it will be ...
wenzul's user avatar
  • 167
2 votes
4 answers
4k views

How to remote shutdown a win XP machine from linux?

How do you remotely shutdown an XP host from a linux machine? I know that you can use shutdown /s /f /m \IP_GOES_HERE From windows, but how would you do that from linux? (wine does not port the ...
brice's user avatar
  • 2,377
2 votes
1 answer
556 views

Linux - Show unsaved applications before shutting down

When you shut down a macOS system, it asks applications to exit one by one, and the system will not shut down unless all applications agree to exit (aka. there is no unsaved work) or until they are ...
Hykilpikonna's user avatar
2 votes
1 answer
3k views

Linux: How to really execute script at shutdown with systemd (not earlier!)?

I‘m running a host with x86-64 Arch Linux with Plasma with latest updates. Here I contact a NAS with wakeonlan, which works fine, so that I can mount an nfs and a Samba share after successful pinging ...
Auguste Leconte's user avatar
2 votes
2 answers
87 views

How to skip shutdown of public linux (debain based) system?

I am running a program on a public computer and I want to avoid that other people may shut down it. I do have the root password. How to skip the shutdown using some commands? I have zero idea of ...
Love Grover's user avatar
2 votes
1 answer
8k views

Debian cannot reboot nor shutdown

I'm stuck with a simple problem of rebooting with my installation of Debian 7. I got inspired by this issue but it's not working. I tried a lot of combinations but still nothing. I'm not sure ...
brcebn's user avatar
  • 275
2 votes
1 answer
4k views

Shutdown Windows machine remotely without telnet/ssh

I have been trying to shutdown a remote XP machine but cannot get it to budge. I did the following on the Windows box: Ensured no firewall Started Remote Registry Editing service Shared a network ...
hamstar's user avatar
  • 529
2 votes
1 answer
47 views

Encrypted Windows10 starts decrypted when it is rebooted after a system update

I am running fedora and windows 10 in dual boot, both oft which are encrypted separately. Whenever windows 10 updates, while shutting down, the next time I boot up in windows I don't need to enter the ...
besinnungslos's user avatar
2 votes
2 answers
2k views

Ubuntu 16.04 keyboard shortcut Alt+F4 to get the suspend/shutdown/restart menu?

I would like to set a conditional keyboard shortcut (Alt+F4) which shows the suspend/shutdown/restart menu only if it is pressed when the desktop has the focus, otherwise just close the active window. ...
SSQUAD's user avatar
  • 21
2 votes
4 answers
18k views

Kali Linux deletes everything on shutdown

I just downloaded Kali for VirtualBox. And I want to make some changes to it. But i figured out, that when i shut it down, it deletes everything, unless I 'save state'. But when it is in 'saved state' ...
Aslo's user avatar
  • 29
2 votes
1 answer
5k views

My ASUS laptop shuts down unexpectedly when unplugged even when battery charge is over 50%

My ASUS laptop shut down unexpectedly when unplugged. Even with battery charge over 50%. The OS installed is Linux, and it is set to shut-down at a critical percentage of 5%. It doesn't look like an ...
Symb932's user avatar
  • 153
2 votes
1 answer
2k views

linux shutdown hang with wifi cifs mounts

Since fedora 15 (and now with 16) it seems that wireless clients take a long while to shutdown when they have network filesystems mounted at shutdown time. I've pushed out a cifs mount via puppet, ...
Sirex's user avatar
  • 11k
2 votes
0 answers
449 views

systemd: intercepting poweroff, shutdown, reboot and alert us we still have KVM QEMU guest(s) running

I want to interrupt a poweroff or reboot if KVM/QEMU Guests are still running. It should work regardless whether shutdown/reboot is requested from XFCE, or from terminal. I already have a script that ...
Shawn Hughes's user avatar

15 30 50 per page