Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How does one reboot from an ash shell? [closed]

Tags:

ash

busybox

How does one reboot from an ash shell?

I have an Ubuntu system that is currently bricked for some reason (not pertinent for this question), which means I boot into a BusyBox ash shell. But the exit command does squat, and reset is irrelevant. There must be a better way to reboot than the power button, right?

like image 245
Urhixidur Avatar asked May 07 '12 13:05

Urhixidur


People also ask

How do I reboot shell?

To reboot Linux using the command line: To reboot the Linux system from a terminal session, sign in or “su”/”sudo” to the “root” account. Then type “ sudo reboot ” to reboot the box.


2 Answers

I was looking for the same, and my BusyBox installation doesn't have shutdown, restart or reboot commands.

I used poweroff -f because poweroff with no parameters doesn't do anything.

If the previous command doesn't work, try to do a ls -la /bin or a ls -la /sbin to see which commands are available on your BusyBox installation.

As user6214440 stated, if your installation doesn't has a good path environment you should need to execute the command with full path like /sbin/reboot or /sbin/poweroff

like image 66
NetVicious Avatar answered Oct 02 '22 02:10

NetVicious


Do you not have the reboot or shutdown commands? reboot without arguments should reboot your box, or 'shutdown -r now' should also do it.

like image 34
falcojr Avatar answered Oct 02 '22 02:10

falcojr