2

I'm trying to set up SSH into my local Mac. I have taken the following steps:

  1. Enabled remote login on the Mac
  2. Verified I can ssh from my local Mac into my local Mac
  3. Verified I can ssh from another computer on the local network into my Mac
  4. Created a custom application forwarding port 22 traffic to my Mac (following the instructions for my 2Wire router found here)
  5. Verified that port 22 is open on the external IP address using an online port scanner
  6. Set up DynDNS to map myusername.dyndns.org to my dynamic IP address and installed the software on the local Mac.

However, when I try to SSH in using the external IP address, I get the following error:

17> ssh XXX.XXX.XXX.XXX -l kevin -v
OpenSSH_5.8p1, OpenSSL 1.0.0d 8 Feb 2011
debug1: Reading configuration data /Users/kevin/.ssh/config
debug1: Reading configuration data /opt/local/etc/ssh/ssh_config
debug1: Connecting to XXX.XXX.XXX.XXX [XXX.XXX.XXX.XXX] port 22.
debug1: connect to address XXX.XXX.XXX.XXX port 22: Operation timed out
ssh: connect to host XXX.XXX.XXX.XXX port 22: Operation timed out 

Can you help me figure out what the problem is or how to debug it? I'm at a loss and I don't know how to log incoming traffic, or figure out where the connection is being dropped.

2 Answers 2

2

I solved the problem. Everything was working fine except I was trying to ssh in from a different computer on the local network, while using the external IP. This attempt was blocked (I am not sure why).

Attempting to SSH in from an external network worked perfectly.

2
  • If you ever figure out why, I would love to know.
    – Andy Swift
    Commented Dec 19, 2011 at 8:37
  • Thank you for writing this very useful information! I logged in to an external server (Amazon EC2) and was able to login!!! I am on a laptop on university network and was trying to login to an Ubuntu virtual machine (running no-ip) running on a Windows Server host. For some reason internal-network->internal-network won't work, however external-network->internal-network does...
    – Eamorr
    Commented Mar 27, 2015 at 9:51
-1

On your vpn connection's in advance settings you have to put the tick to Send all traffic over VPN connection, after that reconnection and the shh command will work perfectly without giving you and connection timeouts.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .