Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.
If you're using a P2P app and happen to be uploading at your max (easy to happen quickly), it will slow your browser down to a crawl. Make sure you're not doing this :)
 
I used to get the same thing when copying google images (for itune artwork), I would have to run the wifi diagnostic to reset the connection.

I found that with Firefox, the same problem happens but a lot less frequent than with Safari.
 
DNS could be an issue. You can eliminate that by trying this:

In /etc/resolv.conf above your nameserver line put:

order hosts, bind

Then in /etc/hosts put:

69.63.176.11 www.facebook.com facebook.com

Finally:

dscacheutil -flushcache

Go back to Safari and try again. If there's a dramatic difference, DNS could be your problem.

If you see results, take it one step further by replacing the IP address of nameserver in /etc/resolv.conf with a public offering from a list such as this one: http://theos.in/windows-xp/free-fast-public-dns-server-list/

Let us know,

J

PS 0% packet loss proves Layers 1, 2, 3 (which includes wireless). So it shouldn't matter wired/wireless.

why not just change the DNS server through Network preferences?

to the OP, try the DNS fix. Go to network preferences, click on the connection for the internet (ethernet or wifi, or both). Go to Advanced, click on DNS and hit the plus sign. Add 208.67.222.222 to it. OpenDNS. If its DNS, then that ought to fix it.
 
DNS could be an issue. You can eliminate that by trying this:

In /etc/resolv.conf above your nameserver line put:

order hosts, bind

Then in /etc/hosts put:

69.63.176.11 www.facebook.com facebook.com

Finally:

dscacheutil -flushcache

Go back to Safari and try again. If there's a dramatic difference, DNS could be your problem.

If you see results, take it one step further by replacing the IP address of nameserver in /etc/resolv.conf with a public offering from a list such as this one: http://theos.in/windows-xp/free-fast-public-dns-server-list/

Let us know,

J

PS 0% packet loss proves Layers 1, 2, 3 (which includes wireless). So it shouldn't matter wired/wireless.

Hi,

I tired what you said initially on /etc/resolv.conf and then added facebook to /etc/hosts .. facebook worked like a charm.. later i did what you said on adding a public dns to my /etc/resolv.conf but that did not solve my issue.. I even tried setting a custom DNS server on my router still the same issue!! I contacted my ISP in Netherland and they said all seems ok from their side...

Its actually abit odd as I have issues with some wesbites (google.com, gmail.com, orkut.com, youtube.com) and some other website (bbc.co.uk) . so I see it must be a google DNS problem.. but I tried setting th IP of all the mentioned address's above in /etc/hosts but then nothing showed at all.. although a stupid questions but can you provide me with IP addresses of the above websites so I give it a try and see if it helps?

Thanks
 
why not just change the DNS server through Network preferences?

to the OP, try the DNS fix. Go to network preferences, click on the connection for the internet (ethernet or wifi, or both). Go to Advanced, click on DNS and hit the plus sign. Add 208.67.222.222 to it. OpenDNS. If its DNS, then that ought to fix it.


I'm trying with OpenDNS now but I still get the same issue :(
 
Hi,

I tired what you said initially on /etc/resolv.conf and then added facebook to /etc/hosts .. facebook worked like a charm.. later i did what you said on adding a public dns to my /etc/resolv.conf but that did not solve my issue.. I even tried setting a custom DNS server on my router still the same issue!! I contacted my ISP in Netherland and they said all seems ok from their side...

Entering the DNS server in your router only helps your router, it does nothing for your computer.

Its actually abit odd as I have issues with some wesbites (google.com, gmail.com, orkut.com, youtube.com) and some other website (bbc.co.uk) . so I see it must be a google DNS problem.. but I tried setting th IP of all the mentioned address's above in /etc/hosts but then nothing showed at all.. although a stupid questions but can you provide me with IP addresses of the above websites so I give it a try and see if it helps?

Thanks
You have to use individual address to test those sites, so:

74.125.45.100 www.google.com google.com
209.85.171.83 www.gmail.com gmail.com
212.58.224.138 bbc.co.uk

It's not a "google" dns problem, it's probably that the DNS server you're using is loaded up and slow/non-responsive.

You can find individual IP addresses by opening terminal and typing:
host google.com or
host bbs.co.uk
or host <whatever hostname you want>

I would recommend against using host entries as a permanent solution because it will defeat any server load balancing or network load balancing in place out there.

You can generally use any DNS server that will take queries from the public (which is most). So here are a couple of other tricks that you can use:

Use your ISP's domain name and type this in terminal:

host -v <ISP_domain>

You will see a section in the output called AUTHORITY SECTION

That section lists the DNS servers supporting that domain. Try using one of the other nameservers listed in that output as your primary nameserver in /etc/resolv.conf

ie You should see something like:

ns1.somedomain.com
ns2.somedomain.com
ns3.somedomain.com

Figure out which nameserver your ISP assigns by entering:

host ns1.somedomain.com which will yield an IP address. Do this for ns2 and ns3 as well. Compare those IP addresses to the one in /etc/resolv.conf Use the IP address of one of the nameservers that is not the one assigned currently.

If you have to go the public route, do some searching for a local public DNS servers and try them out one at a time until you find one that's quick. The closer to you that DNS resides, the faster resolution occurs. You can update which nameserver you use by entering it's IP address in /etc/resolv.conf and entering in the terminal after each change.

dscacheutil -flushcache

Whatever you do, only use ONE nameserver line at a time until you find one that's suitable. If you find two good ones, you can use two discreet nameserver lines in /etc/resolv.conf so in the event the primary becomes non-responsive, your machine will ask the next one in line.

For me, my firewall is Linux and it runs bind (dns server) in a caching mode. What this means is that my machines all ask my local DNS server for names, if they can't be found, my DNS server goes directly through resolution without relying on the ISP servers. This turns out to be VERY fast.

Good luck,

J
 
Hi Thanks for your extensive reply, note that my /etc/resolv.conf shows the following:

nameserver 192.168.2.1

That is my routers gateway? is this good or bad? Could this be the source of the problem?

I tried the host -v <my ISP domain> and below is the reply:
Code:
Trying "kpn.com"
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 42869
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 0

;; QUESTION SECTION:
;kpn.com.			IN	A

;; ANSWER SECTION:
kpn.com.		1410	IN	A	145.7.192.133

Received 41 bytes from 192.168.2.1#53 in 24 ms
Trying "kpn.com"
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 19832
;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 0

;; QUESTION SECTION:
;kpn.com.			IN	AAAA

;; AUTHORITY SECTION:
kpn.com.		60	IN	SOA	dns.kpn.com. postmaster.kpn.com. 2008121501 3600 1800 172800 3600

Received 76 bytes from 192.168.2.1#53 in 25 ms
Trying "kpn.com"
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 8617
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1

;; QUESTION SECTION:
;kpn.com.			IN	MX

;; ANSWER SECTION:
kpn.com.		1798	IN	MX	50 mx.kpn.com.

;; ADDITIONAL SECTION:
mx.kpn.com.		777	IN	A	145.7.191.6

Received 60 bytes from 192.168.2.1#53 in 22 ms

As you can see there is only dns.kpn.com. for the namesevers? what should I do?

BTW, every-time I change /etc/resolv. con after a restart the setting will become 192.168.2.1 again? what should I do to make the changes permanent?

p.s I'll try editing /etc/hosts as you said and will let you know of the results.

Thanks for your help!!!
 
damn... i just tried setting /etc/resolv.conf for facebook.com and orkut.com.. and the flushcahe and restart safari but I still face the same issue.. the pages loads halfway with some pics missing... and its sats loading... on the status bar.. at them same time I could easy browse macrumors and send this feedback!! I'm really getting frustrated...
 
nameserver 192.168.2.1

That is my routers gateway? is this good or bad? Could this be the source of the problem?

Yes, 192.168.2.1 is a non-routeable address which means you're pointing to a local device for resolution (your router) which will then forward the request off to another server.

I tried the host -v <my ISP domain> and below is the reply:
Code:
Trying "kpn.com"
;; AUTHORITY SECTION:
kpn.com.		60	IN	SOA	dns.kpn.com. postmaster.kpn.com. 2008121501 3600 1800 172800 3600
As you can see there is only dns.kpn.com. for the namesevers? what should I do?
In /etc/resolv.conf change your nameserver line to be:
nameserver 145.7.191.35

Also, ping 145.7.191.35 for a while and see if you get any dropped packets.


Test and report back.

BTW, every-time I change /etc/resolv. con after a restart the setting will become 192.168.2.1 again? what should I do to make the changes permanent?
Yes, but there are ways of dealing with that, we'll get to it. Let's focus on one problem at a time. If this doesn't solve it, then making resolv.conf sticky won't help anything.

p.s I'll try editing /etc/hosts as you said and will let you know of the results.

That's an important step here because it will prove/disprove whether it's DNS related.

Thanks for your help!!!
You're welcome.

damn... i just tried setting /etc/resolv.conf for facebook.com and orkut.com.. and the flushcahe and restart safari but I still face the same issue.. the pages loads halfway with some pics missing... and its sats loading... on the status bar.. at them same time I could easy browse macrumors and send this feedback!! I'm really getting frustrated...

Do you mean you put the host names for facebook in /etc/resolv.conf or /etc/hosts? You need to put them in /etc/hosts not /etc/resolv.conf

J
 
I get this too.

A page will begin loading then all of a sudden in my iStat pro stats at the top my connection will go down to about 1KB/s and nothing else will load on the page. I have to close the page, go to a different website, then try the page again to get it to work. It's a farse and happens all the time on my iMac, at least 6-9 times an hour.
 
This is a difficult problem because there are any number of variables at play.

1) The server you're getting data from
2) The network between you and that server
3) The local network
4) The local machine
5) The local application
6) All the protocols involved in retrieving the data

Generally to get to the bottom of it, you need to follow the OSI model--specifically related to layers 1, 2, 3, and the application layer.

You can prove up-to layer 3 with ICMP--re: Ping and Trace

If you can consistently ping a server with no packet loss, that proves out your IP communications over Layers 1, 2, and 3. If you see packet loss, then you have to sort out if your problem is within Layer 1, 2 or 3 before moving on. In this case so far, we've proven layers 1,2 and 3 because the OP pinged the server in question 1000 times and had 0 loss.

That moves us to the protocols used to retrieve data such as DNS or something at the application layer. Since this user sees the same issue with Firefox, the window of opportunity is closing--ie it's likely not an application issue. This is what leads me to DNS (but frankly, I don't have high hopes for this fixing it either because once your lookup a hostname, it will remain cached for a period of time.) So once a page starts to load, DNS is (mostly) complete. The thing that makes this difficult is that not all web pages use one host for all content--in fact, most don't. So it's probable that during the course of one page load, you could see 5, 10 or 15 DNS queries. No matter what, it's important to verify that DNS is 100% or you will see odd little problems.

One thing you can do to eliminate Layers 1, 2, 3, and protocols is to use another machine with the same IP configuration on the same network to see if it experiences the same issue. If it does, then you likely have some sort of network issue to sort out. If it doesn't, then you likely have an application issue to sort out.

So if you're experiencing the same issues as the OP, I'd recommend starting with another machine on the same network to see if you see the same issue. That'll give you your starting point and you can work from there.

J
 
This is not specific to Macs: I block MANY ad server URLs from my router, which has positive results overall but occasionally it seems there is a page taking a long time to load while its trying to grab content from a blocked URL. Could this also be happening to the OP?
 
Hi,

I can say I've lost hope and dont know what to do next!!

I edited /etc/hosts with the websites I visit the most and I still face the same problem.

I also edit my /etc/resolv.conf with the DNS IP of my ISP which you provided and same issue..

an exmaple was just 5 minutes ago.. was in facebook and about to reply to a wallpost.. I clicked in submit and nothing was happening? I tried opening www.facebook.com with both Opera and Firefox and it was not loading on them too!! I could open some other pages though... so I tried pining www.facebook.com and I got 0% packet loss!!!

Could this be a hardware issue?

Good news is that tomorrow I'll be travelling to Greece and will be able to test my connectivity at the Airport and at my friends house?? what should I do if I still face the same issue??

I'll report back and yet again thanks for your help!

Cheers,
Mohammad
 
If you've put the correct host IP addresses and hostnames in /etc/hosts and see the same issue, then you can probably eliminate DNS as the problem.

So you have Layer 1, 2, 3 and DNS proven. This means you have to move to the transport layer which means you're going to need some advanced troubleshooting skills and tools like tcpdump to sort this out on your current connectivity. Using a different network all together can also prove that your application layer (Safari/Firefox) are/are not having issues.

ie If you get on another network, and everything works fine, you know that your application layer (Safari) and the presentation/session layers are working. That leaves you with Layer 4 or the Network Layer.

If you get on another network and you experience the same issues, you can probably eliminate Layer 4 and start focusing on Layers 5,6,7--which probably means Layer 7. Since you're experiencing the issue on Firefox and Safari, this probably means you're going to need to re-install unless you really can get into tcpdump.

J
 
If you've put the correct host IP addresses and hostnames in /etc/hosts and see the same issue, then you can probably eliminate DNS as the problem.

So you have Layer 1, 2, 3 and DNS proven. This means you have to move to the transport layer which means you're going to need some advanced troubleshooting skills and tools like tcpdump to sort this out on your current connectivity. Using a different network all together can also prove that your application layer (Safari/Firefox) are/are not having issues.

ie If you get on another network, and everything works fine, you know that your application layer (Safari) and the presentation/session layers are working. That leaves you with Layer 4 or the Network Layer.

If you get on another network and you experience the same issues, you can probably eliminate Layer 4 and start focusing on Layers 5,6,7--which probably means Layer 7. Since you're experiencing the issue on Firefox and Safari, this probably means you're going to need to re-install unless you really can get into tcpdump.

J

Well I've used tcpdump sometime ago but cant recall anything now.. can you please provide me with a test script which I can use and analyse myself?

I'll let you know of the results once I test at other sites too.

Thanks again!!
 
I'm not sure a script is what's needed, just some time trapping tcpdump data to see if you can figure out what's going on w/layer 4.
 
I'm not sure a script is what's needed, just some time trapping tcpdump data to see if you can figure out what's going on w/layer 4.

I'm at the airport typing this message and so far I've faced no issues and everything loads perfectly! although I only have 10 mins left to test but it seems OK! So this means my home network (ISP) has some serious issues? right?

Next test will be in Athens!

Cheers,
Mohammad
 
I'm at the airport typing this message and so far I've faced no issues and everything loads perfectly! although I only have 10 mins left to test but it seems OK! So this means my home network (ISP) has some serious issues? right?

Next test will be in Athens!

Cheers,
Mohammad

Looks that way. It's interesting that your pings came back clean while testing at home. You really are narrowed down to something at Layer 3 or Layer 4 that we haven't spotted because you just proved out the entire stack on a different network. ie It's not your machine.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.