Results 1 to 5 of 5

Thread: halt / poweroff: symbolic links to reboot?

  1. #1
    Join Date
    Aug 2010
    Beans
    4

    halt / poweroff: symbolic links to reboot?

    Hi, I'm learning about the halt and poweroff commands. What I found out just puzzles me. Here:
    Code:
    $ which halt
    /sbin/halt
    $ file /sbin/halt
    /sbin/halt: symbolic link to `reboot'
    $ which poweroff
    /sbin/poweroff
    $ file /sbin/poweroff
    /sbin/poweroff: symbolic link to `reboot'
    Could anyone explain?
    Thanks,

  2. #2
    Join Date
    Apr 2008
    Location
    Australian in Germany
    Beans
    4,010
    Distro
    Ubuntu 10.10 Maverick Meerkat

    Re: halt / poweroff: symbolic links to reboot?

    What is it exactly that is puzzling you? Is it that those commands are coming up as being symbolic links? If so, I think your answer is that they are all the the same program. Looks like it to me, anyway.

    Do you know about man pages? The manual pages you get with the command
    Code:
    man <command name>
    I just looked, and saw that
    Code:
    man halt
    Code:
    man poweroff
    Code:
    man reboot
    all pull up the same man page. Have a look at it yourself.
    Michael

  3. #3
    Join Date
    Oct 2009
    Beans
    Hidden!
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: halt / poweroff: symbolic links to reboot?

    Basically running halt, poweroff, reboot just calls shutdown with certain flags set.
    Come to #ubuntuforums! We have cookies! | Basic Ubuntu Security Guide

    Tomorrow's an illusion and yesterday's a dream, today is a solution...

  4. #4
    Join Date
    Apr 2008
    Location
    Australian in Germany
    Beans
    4,010
    Distro
    Ubuntu 10.10 Maverick Meerkat

    Re: halt / poweroff: symbolic links to reboot?

    Quote Originally Posted by CharlesA View Post
    Basically running halt, poweroff, reboot just calls shutdown with certain flags set.
    Ah, I had wondered why there was more than just "shutdown". It does seem to do everything a person could need...

    I, when I need to turn the computer off from the terminal, use

    Code:
    shutdown -r now
    to reboot,
    and
    Code:
    shutdown -P now
    to turn off completely.
    Michael

  5. #5
    Join Date
    Aug 2010
    Beans
    4

    Re: halt / poweroff: symbolic links to reboot?

    Thanks, that really cleared it up for me.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •