You can make a difference in the Apple Support Community!

When you sign up with your Apple Account, you can provide valuable feedback to other community members by upvoting helpful replies and User Tips.

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

No route to host (unreachable from Mac but not from PC)

Hi all,

Short description:

I'm getting a "no route to host" when pinging a server at work (and I'm doing this from home). If I do the same thing with my PC, it returns a response and it can find the server. Both computers are on DHCP, wireless via the Airport Extreme. I'm not using a firewall on any computer and I'm not forwarding any ports on the Airport Extreme. It's all wide open. This USED to work on the Mac and one day it suddenly just would not work! At least that's what I would like to think... 🙂


Long description:

This started a while ago, can't exactly tell when and what I could have done to cause this (or if this was caused by me at all).

One day I was unable to SSH into work like I do quite often from home. Also, VNC did not work (same server). Now the weird thing; I was able to FTP into the server on port 21. The server is also running FTP on another port, however this port was unreachable. I tried doing a ping to the server in the shell but all I got was "no route to host".

Since I am not running a firewall and I'm not using port forwarding (and all of this worked fine using that setup) I was clueless. I booted up my PC and connected it just the same way I do with my Mac; wirelessly and using DHCP through my Airport Extreme.
From the PC I was able to do everything, just like I used to.

I've found out that flushing the DNS cache might do the trick (lookupd -flushcache). This didn't work. I've also tried to do flush the firewall rules (ipfw flush) -- and this did nothing... probably because I'm not even running a firewall.

What should I do?
I hate having to reinstall the whole computer when Leopard is closing in...

Macbook Pro 2.16GHz, 2GB RAM, build 8R2218 Mac OS X (10.4.10)

Posted on Jul 17, 2007 10:26 AM

Reply
6 replies

Jul 17, 2007 4:14 PM in response to Fredrik Averpil

Try opening the file /etc/ssh_config from the terminal (you will need to use sudo) with the editor of your choice... eg:

sudo emacs /etc/ssh_config

Add the following lines to the end:

AddressFamily inet
BindAddress x.x.x.x

where x.x.x.x is the IP address of your computer behind your router (I use static IPs for consistent results).

Save and see if you don't have better luck with ssh.

Jul 19, 2007 12:39 AM in response to Fredrik Averpil

Weird thing is ... I had my computer powered off for like a day and brought it to work. At work I tried pinging the server again ... and now it worked!!

When I got back home VNC, SSH and everything worked fine!

Maybe those flushing commands did the trick but needed the computer to be restarted?
I have not tried any of the suggestions in the thread ...it just started working.

No route to host (unreachable from Mac but not from PC)

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.