11 responses

  1. no way
    August 14, 2017

    This is idiotic, why risk a terminal mistake when you can simply go to Apple upper left of screen and click shut down. If you are connected remotely this works exactly the same.

    I guess OSXDaily is just running out of good advice, and posting bad in it’s place.

    • Fool Factory
      August 14, 2017

      “no way” you personally should definitely stick to novice level material like your little Apple menu trick because this is obviously over your head, which is fine, you’re a novice level user. Everyone starts somewhere.

      If you don’t know why people use the Terminal or would want to shutdown from the command line you should probably not comment about it, it makes you sound even less intelligent than your comments already are.

    • Darren O’Brien
      August 14, 2017

      Actually shutting down a Mac by command is very useful to every sysadmin.

      If you don’t understand a subject but you attack that subject because you don’t understand it yourself, that makes you the idiot. You’re being willfully ignorant. In fact, you would be less of an idiot yourself if you bothered to learn a thing or two.

      • no way
        August 16, 2017

        I understand the subject perfectly well, have been a system admin and senior level repair for Apple for over two decades.

        Instead of whining and trash talk prove me wrong.

        Bottom line doing ANYTHING via terminal remotely is a risk that no experienced tech would ever do when they can do it via the user commands.

  2. Sam
    August 14, 2017

    This advice is just plain wrong and will lead to corruption and lost data if you follow it. DO NOT follow this advice.

    Both commands send programs a UNIX style shutdown command. GUI programs do not expect this and will terminate WITHOUT giving you the chance to save your data or clean themselves up. (Specifically, Cocoa apps do not see applicationShouldTerminate: or the kAEQuitApplication Apple Event)

    The correct way to safely shutdown from the command line is “osascript -e ‘tell app “System Events” to shut down'”

    • Erik
      August 14, 2017

      Sam, you’re wrong. This shuts down a Mac from the command line. Did you even bother read the article? Obviously not. There are multiple warnings that it does not request a data save. There’s a giant paragraph at the beginning of the article.

      How did you manage to get this far without reading the article? Maybe this site needs a system to verify that people read the article before they can comment.

      “An important word of warning: shutting down a Mac through the command line happens instantaneously. There is no confirmation, no warning dialog, no stopping to save documents, no asking to close apps or save anything. Instead, the Mac will instantly terminate any and all activity going on and immediately shut down the computer. This could lead to data loss, so be sure you are ready to turn off a Mac if you issue these commands.”

      Also to say it is “wrong” is itself wrong, because “wrong” is by definition incorrect. The article is correct, even if you don’t agree with it. That makes it TRUE.

      Why don’t you do your own research, type “man shutdown” into the command prompt and you will see that it is REAL and TRUE. Facts matter.

      • Sam
        August 14, 2017

        You are wrong about reading the man page. The man page was never updated for macOS. Read the bottom of the man page. It says “BSD December 11, 1998”. That means Apple never updated the man page for OS X, otherwise it would say DARWIN or macOS (try man diskutil or pmset). Therefore do NOT trust the information.

        There is NO reason to use BSD shutdown unless the system is stuck. There is a perfectly good command line method which I provided, which is safe and does not result in data loss.

        In general, Apple does recommend applications or users work with the BSD interfaces and utilities in macOS. This is a prime example why.

      • Gombo
        August 15, 2017

        Sam if you’re booted into recovery or single user as root and need to shutdown a Mac, how do you propose doing that?

        The answer is the shutdown command.

  3. Dan Uff
    August 14, 2017

    Well, for those of us who use the Terminal this trick is appreciated. Thank you.

  4. mike
    August 18, 2017

    The “reboot” command was not listed, but is sometimes very handy.

  5. Endymion
    August 20, 2017

    Today we have only seven ladder manufacturers in the US, down from >100. Why; not globalization, nor a decline in the market but rather the lawsuits from people who fell off ladders and sued all the small operations. The desire for an idiot-proof world is here again on this thread. CLI and its risk/benefits are not for the foolhardy. People like this are the reason why construction trucks make that beeping noise when backing-up.

Leave a Reply

 

 

 

Back to top