I couldn't always ssh to my iPhone from my Mac. They're both on the same wifi network but sometimes the connection is established, sometimes it failed. From my Mac:

$ ssh root@192.168.0.102
ssh: connect to host 192.168.0.102 port 22: Operation timed out
$ ping 192.168.0.102 
PING 192.168.0.102 (192.168.0.102): 56 data bytes
ping: sendto: No route to host
ping: sendto: Host is down
ping: sendto: Host is down

I enabled SSH on the phone and am sure it can load webpages. So what might be a reason why they cannot connect?

Thanks

link|improve this question

80% accept rate
Can you check your wifi's client list to see if what the iPhone shows as IP address really is what it actually uses? – Daniel Beck Jan 12 '11 at 18:19
feedback

migrated from serverfault.com Jun 14 '10 at 4:41

This question came from our site for system administrators and desktop support professionals.

1 Answer

Are you sure that your iPhone is still assigned that IP address? You can find the IP for the iPhone by going to:

Settings
    Wi-Fi
        The blue arrow next to the Wi-Fi network you're connected to

This will show you the IP that the phone is assigned. You can also check the DHCP lease tables on your router. If SSH is indeed turned on you should be able to connect via SSH to that IP, ping should work to.

HTH

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.