0

I am using cURL to catch a remote server response. I've noticed that this method takes me 20 seconds eveytime. I've googled and found that something with the DNS lookup is misconfigured on my server (apache).

When i'm writing the exact i.p of the host it takes less than a second.

Any idea where to change this? I think it called reversed dns lookup but I can't figure out if I can enable/disable this.

Thanks

user31279
  • 3
  • 2

2 Answers2

0

to disable reverse lookups, disbale HostnameLookup.

when this does not help, be sure to not use hostnames in RewriteRule, RewriteCond, deny/allow rules and %h in LogFormat.

Christian
  • 4,703
  • 2
  • 24
  • 27
0

What's set in your /etc/resolv.conf file? Sounds like your DNS servers are slowing you down, so it's worth checking what your using.

I'd recommened OpenDNS unless you have specific local requirements. To try them just put in the /etc/resolv.conf file:

nameserver 208.67.222.222
nameserver 208.67.220.220
Coops
  • 6,055
  • 1
  • 34
  • 54
  • Beutiful ! it worked like magic. I think my server "dialed up" to mars before that change. Thanks again ! – user31279 Jan 25 '10 at 14:43