Skip to main content
Topic: Unable to shutdown (with shutdown command, not power button) (Read 2869 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Unable to shutdown (with shutdown command, not power button)

I was unable to shutdown with
Code: [Select]
shutdown now
. Nothing happens after a while when it attempted to shutdown (The system isn't freezed or anything, prompt still works)

I cycled through my tty and tty7 still responding, although it told me that the system is shutting down.

I managed to dump some logs with dmesg:
pastebin here

and shutdown just tells me this:
Code: [Select]
runsvchdir: single: current.
Seems like normal stuff.


Anyone has clues?

and I just noticed dmesg doesn't help that much, here is a photo of tty0
You shouldn't listen to my advice anyways

Re: Unable to shutdown (with shutdown command, not power button)

Reply #1
Does runit even have shutdown command like this? I thought it can only work via poweroff or runit-init 0
ARMtix

Re: Unable to shutdown (with shutdown command, not power button)

Reply #2
interesting... Now I will need to find where the heck this executable comes from.
You shouldn't listen to my advice anyways

Re: Unable to shutdown (with shutdown command, not power button)

Reply #3
Code: [Select]
pacman -F shutdown
system/mkinitcpio 27-3 [installed]
    usr/lib/initcpio/hooks/shutdown
    usr/lib/initcpio/install/shutdown
    usr/lib/initcpio/shutdown
system/openrc 0.42.1-13
    usr/bin/shutdown
    usr/lib/openrc/bin/shutdown
system/runit 2.1.2-19 [installed]
    usr/bin/shutdown
system/s6-linux-init 1.0.4.0-2
    etc/s6/current/bin/shutdown
    usr/bin/shutdown
archlinuxcn/systemd-sysvcompat-git 245.1099-1
    usr/bin/shutdown

It was installed with runit.
You shouldn't listen to my advice anyways

Re: Unable to shutdown (with shutdown command, not power button)

Reply #4
After some investigation, I suspect that runit isn't exiting stage 3 properly. Maybe one of the service file is to blamed.
You shouldn't listen to my advice anyways


Re: Unable to shutdown (with shutdown command, not power button)

Reply #6
Both these work too.

sudo halt
sudo reboot
antiX-19 i3 runit & ArtiX-i3 runit

 

Re: Unable to shutdown (with shutdown command, not power button)

Reply #7
Not sure if necro-bumbing is allowed, but this is an issue for me as well.  Question:  Why isn't the contents of /usr/bin/shutdown installed by runit a file containing simply: 

Code: [Select]
#! /bin/sh
runit-init 0

I had that as the contents of my shutdown executable for a while but the next time  runit updated via pacman -Syu it reverted to the broken non-system-shutdowning monstrosity.

Any chance this can be the default behavior of runit's shutdown file?

Thanks

Re: Unable to shutdown (with shutdown command, not power button)

Reply #8
Not sure if necro-bumbing is allowed, but this is an issue for me as well.  Question:  Why isn't the contents of /usr/bin/shutdown installed by runit a file containing simply: 

Code: [Select]
#! /bin/sh
runit-init 0

I had that as the contents of my shutdown executable for a while but the next time  runit updated via pacman -Syu it reverted to the broken non-system-shutdowning monstrosity.

Any chance this can be the default behavior of runit's shutdown file?

Thanks

Unfortunately, no. Since the sysvinit days, shutdown without option will bring us to a single-user login, and I think Artix should keep it consistent.

From Debian manpage for sysvinit:

Quote
runlevel 1 is used to put to system into a state where administrative tasks can be performed; this is the default if neither the -h or -r flag is given to shutdown.
now only the dinit guy in artix

Re: Unable to shutdown (with shutdown command, not power button)

Reply #9
You can make your personal default though:
man pacman.conf
       NoUpgrade = file ...
           All files listed with a NoUpgrade directive will never be touched during a package install/upgrade, and the new files will be installed with a .pacnew extension.
           These files refer to files in the package archive, so do not include the leading slash (the RootDir) when specifying them. Shell-style glob patterns are allowed.
           It is possible to invert matches by prepending a file with an exclamation mark. Inverted files will result in previously blacklisted files being whitelisted
           again. Subsequent matches will override previous ones. A leading literal exclamation mark or backslash needs to be escaped.

e.g. in /etc/pacman.conf (remember no / prefix )
NoUpgrade   = etc/path/to/file

Re: Unable to shutdown (with shutdown command, not power button)

Reply #10
Try
Code: [Select]
loginctl poweroff