Results 1 to 8 of 8
I'm assuming it was an update that did this, but the halt command no longer does anything. I can't turn the computer off, restart it, etc.
This is what happens ...
- 11-06-2005 #1Linux Enthusiast
- Join Date
- Jun 2005
- Location
- Odessa, FL
- Posts
- 586
The "halt" command no longer works...
I'm assuming it was an update that did this, but the halt command no longer does anything. I can't turn the computer off, restart it, etc.
This is what happens when I try using any of the halt commands....in this example, it's to poweroff:
How do I fix this? Now, when I try turning the computer off it doesn't do anything so I'm left holding the power button down to turn it off (which I'd rather not do)Code:localhost josh # halt -p shutdown: No such file or directory localhost josh #
Thanks in advance
- 11-06-2005 #2
From the error it can't seem to find the shutdown command, so you could try and find it with
orCode:locate shutdown
and see if it's now outside your $PATH, and if it is add it to your $PATH.Code:find / -iname shutdown
Of course you can try to halt the system with thecommand, which will switch you to runlevel 0 which halts the system.Code:init 0
- 11-06-2005 #3Linux Enthusiast
- Join Date
- Jun 2005
- Location
- Odessa, FL
- Posts
- 586
ok...so i did "locate shutdown" and found a couple of scripts that seem like it may be it:
Originally Posted by dylunio
/etc/init.d/shutdown.sh
/sbin/shutdown_script
of course there were more, but the others didn't seem like THE shutdown script
...they just seemed like variations of it (kshutdown for example). what should i do? i'm sorry, i don't know which path the $PATH refers to. is that /usr/sbin/, /usr/bin/,...?
- 11-06-2005 #4
Looking at my system shutdown is in /sbin/shutdown, and when I type
it works since /sbin is in my path as root, as it should be on your system. I find it weird that you seem to have lost yours though.Code:shutdown [options]
Maybe the best way to fix this would be to download a stage3 tarball and copying /sbin/shutdown from it?
In the mean while you can come to a halt withor reboot withCode:init 0
Code:init 6
- 11-06-2005 #5
hmmm i halt still...
Code:halt
~Mike ~~~ Forum Rules
Testing? What's that? If it compiles, it is good, if it boots up, it is perfect. ~ Linus Torvalds
http://loft306.org
- 11-06-2005 #6Aye, but if your is runlevels 1-5 that just invokes shutdown -h, and josolanes doesn't seem to have shtdown for some weird reason
Originally Posted by loft306
- 11-07-2005 #7Linux Enthusiast
- Join Date
- Jun 2005
- Location
- Odessa, FL
- Posts
- 586
well...i renamed the "shutdown_script" to "shutdown" and now shutdown [option] works....but halt [option] still doesn't. i don't know what happend. i have a strong feeling it's because of an update (i'm using the development branch....or have "~x86" in make.conf, so i get all of the unstable packages...maybe that's what caused these problems??)
Originally Posted by dylunio
anyways, now i can atleast use shutdown [option]...i just have to get used to using it rather than halt [option], or maybe i'll just learn to use init [#] as it's even short. i don't know yet....but i'm glad i (kind of) got it fixed
thanks for the help/suggestions
- 11-07-2005 #8
You could always alias halt to shutdown -h now
Put the alias into root's ~/.bashrc file:
Code:alias halt='shutdown -h now'


Reply With Quote
