Today in class, the teacher asked us to say different ways to shutdown/reboot,etc. the system. I said "poweroff" and I though that it was probably actually a symbolic link to "shutdown" or "halt".
We are using Ubuntu 12.04 and when I checked it turned out to be a link to "reboot" which kind of surprised me. How does that make sense?
In my Raspberry Pi running Debian I get: /sbin/poweroff: symbolic link to 'halt'
EDIT: I don't see how my question is answered there.It mentions that when forcing shutdown poweroff invokes the reboot syscall, but doesn't answer why it is linked to reboot(1)
reboot,poweroffandhaltare all the same command. I suspect it's just the developer's whim thatrebootis the main binary. In particular, this set of links is from Upstart, the case where the links point tohaltis fromsysvinit. I'd guess if you install Upstart in Debian you'd see the same behaviour there as well. – muru Mar 23 '15 at 19:16rebootwas the main binary.I guess @muru answered it. – user2859982 Mar 24 '15 at 10:02