Stop the OS for on-site hardware replacement.
Do not automatically restart the machine.
Which command matches the goal?
halt stops the system, while reboot restarts it. Depending on platform behavior, poweroff may be the command required to turn power off completely.
Detailed explanation
rebootIncorrect. reboot starts the system again after stopping it.
Incorrect. reboot starts the system again after stopping it.
haltCorrect. halt transitions the OS to a stopped state without requesting a reboot.
Correct. halt transitions the OS to a stopped state without requesting a reboot.
sshIncorrect. ssh is a remote-login client.
Incorrect. ssh is a remote-login client.
exitIncorrect. exit terminates a shell rather than the operating system.
Incorrect. exit terminates a shell rather than the operating system.
Try it yourself
An example you can run in a temporary verification environment.
halt --helpExpected result
haltの使用法。停止は実行しないKey points
- halt
- Difference from reboot
- Power state
Notes
- Environment: systemd systemctl互換halt
- Command output formatting can vary slightly by distribution or tool version.
- Run the example in a temporary directory or process when possible.
Foundation review
Read the scope first
Check whether the command acts on the current shell, a new process, an existing process, or a file.
Verify the observable result
Use the supplied command and compare the output with the expected result.