Use MobileMe to SSH Into Your Remote Mac
It's no secret to Mac users that if you own more than one machine, Apple's MobileMe service is a great way to keep your data synced between all of your machines. And while it's true that there are plenty of methods of doing everything that MobileMe offers for the much lower price of free, I have yet to come across a one-app solution. I stay busy enough with work that researching, installing, testing, and learning the various apps I'd need to recreate all that functionality is not very high on the list of crap I want to have to think about.
That being said, one of the coolest (yet least documented features) of MobileMe is the ability to log in to a remote Mac via SSH. I'd been searching the nets for a way to do this for a while without much luck. Some have claimed to get it to work, but with limited success (none of which made it down to me).
Supposedly, entering the following command (with the hostname and member name replaced) is supposed to do the trick: ssh -p 22 [hostname].[member name].members.mac.com.
However, no matter what, I would always get the following error: ssh: Could not resolve hostname [hostname].[member name].members.mac.com.: nodename nor servname provided, or not known
So after playing around with it for a bit, I seem to have come up with a consistent (if a bit sub-optimal) method:
Enabling Remote Login You will need to make sure that Remote Login is enabled in the Sharing section of System Preferences. Simply click the checkbox in the left column to start or stop it.
Connecting to the remote Mac in Terminal Open up Terminal (located in /Applications/Utilities) and click Shell->New Remote Connection, then click Secure Shell (ssh) in the left column. After a second or two, the hostname of your computer will appear in the right column. Simply double click it to launch a new session and provide the password for the remote Mac when prompted. If your username is different on the remote Mac, you will need to supply it in the "User" field.
Oddities 1) Even though Terminal spits out the bash command for connecting to the machine, I am unable to copy and paste the command into a shell (same error as above). 2) This is probably related to #1, but this trick seems to only work in Apple's Terminal.app, which is unfortunate since I prefer to use iTerm.

Leave a Comment