Remote Access with SSH

Are you a geek? Take this simple test at home: Do you get excited about Mac OS X’s ability to permit SSH access?

If you answered “What’s SSH?” or “I’m already being quiet,” then the following discussion of Unix remote control may not interest you. To be sure, SSH is not a program with a graphic user interface (icons and menus). You operate it from within a program like Terminal by typing commands, exactly as described in Chapter 16.

If you’re willing to overlook that little peccadillo, though, SSH (Secure Shell) is an extremely powerful tool. It lets you connect to your Mac from anywhere—from across the network or across the Internet. And once you’re connected, you can take complete control of it, copying files, running commands, rearranging folders, or even shutting it down, all by remote control.

Getting In

Here’s how you go about using SSH:

  1. Set up your Mac by opening the Sharing panel of System Preferences, and then turning on the Remote Login checkbox.

    You’ve just told the Mac it’s OK for you (or other people with accounts on your machine) to connect from the road. Quit System Preferences.

  2. Go away.

    You can move to another machine on the network, or another computer on the Internet (if you’ve dealt with the port-forwarding issue described on Let the Chat Begin). Once you’re online with that other machine, you can contact your home-base machine from within a program like Terminal.

    Tip

    It doesn’t have to be Terminal, and it doesn’t have to be a Mac. You can get SSH ...

Get Mac OS X Lion: The Missing Manual now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.