Chrome and Safari can browse the internet, but ping and other command-line tools can't

1

I'm using Mac OS X 10.6, and the problem appeared after the latest update.

Chrome and Safari can browse the Internet fine, but I can't ping google.com or apple.com. I have also found that bzr fails, but git works for some reason.

I thought it might be an IPv6 issue, so I tried disabling IPv6 on all the interfaces I could, but the problem continued.

I have no idea what might be causing this. Thanks for any help you can give!

Edit:

ifconfig produces

lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> mtu 16384
    inet6 ::1 prefixlen 128 
    inet6 fe80::1%lo0 prefixlen 64 scopeid 0x1 
    inet 127.0.0.1 netmask 0xff000000 
gif0: flags=8010<POINTOPOINT,MULTICAST> mtu 1280
stf0: flags=0<> mtu 1280
en0: flags=8863<UP,BROADCAST,SMART,RUNNING,SIMPLEX,MULTICAST> mtu 1500
    ether 00:25:00:a9:93:9e 
    inet6 fe80::225:ff:fea9:939e%en0 prefixlen 64 scopeid 0x4 
    inet 165.82.76.128 netmask 0xffffff00 broadcast 165.82.76.255
    media: autoselect (100baseTX <full-duplex>)
    status: active
fw0: flags=8863<UP,BROADCAST,SMART,RUNNING,SIMPLEX,MULTICAST> mtu 4078
    lladdr 00:25:00:ff:fe:a9:93:9e 
    media: autoselect <full-duplex>
    status: inactive
en1: flags=8823<UP,BROADCAST,SMART,SIMPLEX,MULTICAST> mtu 1500
    ether 00:24:36:af:45:d4 
    media: autoselect (<unknown type>)
    status: inactive
en2: flags=8963<UP,BROADCAST,SMART,RUNNING,PROMISC,SIMPLEX,MULTICAST> mtu 1500
    ether 00:1c:42:00:00:08 
    inet6 fe80::21c:42ff:fe00:8%en2 prefixlen 64 scopeid 0x7 
    inet 10.211.55.2 netmask 0xffffff00 broadcast 10.211.55.255
    media: autoselect
    status: active
en3: flags=8963<UP,BROADCAST,SMART,RUNNING,PROMISC,SIMPLEX,MULTICAST> mtu 1500
    ether 00:1c:42:00:00:09 
    inet6 fe80::21c:42ff:fe00:9%en3 prefixlen 64 scopeid 0x8 
    inet 10.37.129.2 netmask 0xffffff00 broadcast 10.37.129.255
    media: autoselect
    status: active

And ipfw list produces

65535 allow ip from any to any

Noah Lavine

Posted 2010-11-29T16:44:49.973

Reputation: 113

3Do you have an outgoing firewall installed? If so check it's not blocking these commands. – ChrisF – 2010-11-29T16:51:40.207

Did you recently change nicks ChrisF? – RobotHumans – 2010-11-29T18:00:25.663

What error do you get when you try to ping google.com? – Gordon Davisson – 2010-11-29T18:31:41.823

When I do ping google.com I don't get an error, I just get a series of lost packets. However, when I do bzr pull in a repository, I get "Connection error: while sending POST ...: [Errno 51] Network is unreachable". – Noah Lavine – 2010-11-29T19:32:27.680

What does the output of ifconfig and ipfw list look like? (you may need to prepend sudo to each) – Zayne S Halsall – 2010-11-29T20:14:02.150

@Zayne - I'll put that in an edit because it's quite long. – Noah Lavine – 2010-11-29T22:22:22.133

Would you mind sharing the output of the ping command that you get? Also, are you able to browse on Firefox, if you have that? I am asking because both Chrome and Safari use the system-wide proxy settings, while Firefox has its own proxy settings configuration utility. – ayaz – 2010-11-30T10:07:10.660

@ChrisF - you're right. I got in touch with the people who manage our LAN, and it looks like ping and bzr are both blocked. Thanks to everyone for your generous help. – Noah Lavine – 2010-11-30T19:37:05.600

Answers

2

Can you ping your Gateway or any PC on the same LAN? May be it's just that your school disable ping going out of school network. Networks with lot of users usually block ICMP traffic from going out/getting into their network for security reason. Same for my university here. (Ping use ICMP protocal).

Ken Ratanachai S.

Posted 2010-11-29T16:44:49.973

Reputation: 1 532

Yes, you're right. That turned out to be the issue. – Noah Lavine – 2010-11-30T19:37:21.573

1

Noah: are you connected to a vpn? What's with the en2 and en3 interfaces?

It looks like you have one outward facing ip address on en0, and 2 private IP addresses on en2 and en3 (i assume en1 is airport and it's set to off).

Try disabling en2 and en3 and see if your command line troubles go away. There's a lot of unanswered questions here, but I wonder if you're using a proxy through a vpn for your web surfing...

Robert S Ciaccio

Posted 2010-11-29T16:44:49.973

Reputation: 1 470

also, you might want to check out apple.stackexchange.com. – Robert S Ciaccio – 2010-11-29T22:42:12.227

I'm not connected to a VPN, but I am on my school's network, which might have a filter on it. I will check on that. – Noah Lavine – 2010-11-30T01:54:34.650

en2 and en3 are from Parallels virtualization software. Making them inactive didn't fix the issue. – Noah Lavine – 2010-11-30T01:55:06.867

if you look in your proxy settings for en0, is there anything there? Got to system preferences --> advanced --> proxies – Robert S Ciaccio – 2010-11-30T02:00:23.023