The key may be in this sentence, "it kills all running processes". In my case, it did NOT! The problem was caused by the redis-server
process which, for some reason, couldn't be stopped normally. Once I killed all redis-server
processes, sudo killall redis-server
, I was able to do shut down normally. Since I don't need redis that often, I stopped it from running at startup with these commands:
sudo update-rc.d -f redis-server remove
sudo update-rc.d -f redis_6379 remove
I will wait for an update that fixes this problem, but for now I will remember to stop the redis process before shutting down.
It may not be redis in your case, but it's likely a buggy process that Ubuntu couldn't kill.
This may help you inspect the problem:
service --status-all
: lists all services registered with the system. Services that start with OS boot will have a [+] symbol before them.
Read the log messages that appear on the screen when you press the power button to manually power off. In my case, I read something about trying to close the redis server. The messages may also appear if you press some random keys.
Review the programs you installed recently, maybe one of them is causing the problem.
Try closing all unnecessary processes and see if you can shut down normally. If you can, repeat the process, narrowing down the candidates, till you reach the buggy app.
sudo poweroff
at a terminal prompt, or if you are unfamiliar with the terminal press "alt-f2" and type "gksudo poweroff" and that may bring your computer to a complete power off.