So I've been using the command "poweroff" to shut down my Linux system, tried searching only if this is safe or not, mostly people just speak of "shutdown -h now" or something like that. So my question is: Is it safe to shut down Linux using the "poweroff" command?
Asked
Active
Viewed 2,107 times
4
-
`man halt` or `man poweroff`... – jasonwryan Aug 24 '17 at 22:29
-
A related question is https://unix.stackexchange.com/questions/387861/ . – JdeBP Aug 25 '17 at 03:45
-
I've always used `halt` instead, way shorter! – cylgalad Aug 25 '17 at 07:10
1 Answers
10
From poweroff man page:
When called with --force or when in runlevel 0 or 6, this tool invokes the reboot(2) system call itself and directly reboots the system. Otherwise this simply invokes the shutdown(8) tool with the appropriate arguments.
and shutdown
shutdown arranges for the system to be brought down in a safe way.
what this says is simply that... usually poweroff calls shutdown, so it is pretty much as safe as shutdown -h now
Christopher Díaz Riveros
- 1,602
- 10
- 16