PHP curl "couldn't connect to host"
Disclaimer: I'm a bit rusty with Linux. Used to use Redhat about 10 years ago, but not much experience since then.
I'm running Ubuntu 9.04 64 bit on my Linode.
Typical LAMP install with UFW. I only have port 80 and 22 open.
I'm running a web service that runs every 5 minutes via a cron job and needs to connect to other sites using their APIs. I'm using PHP curl to do this.
I moved from Dreamhost shared hosting (don't laugh!
* name lookup timed out
- couldn't connect to host My first thought is that I must not have any DNS servers setup. But I checked and I'm using DHCP which seems to be getting 2 of Linode's DNS servers.
Here's the DHCP information from Linode Manager Network tab:
****Gateways: 74.207.243.1
Netmask: 255.255.255.0
DNS Servers: 74.207.241.5, 74.207.242.5****
Any ideas? This is very strange indeed. Are the Linode DNS servers faulty or not reliable?
5 Replies
Interesting, because the primary was down, but the secondary was up…surprising that cURL didn't move on the secondary (it should have)…
It seems better now
Yeah, that is strange that it wouldn't try the 2nd DNS…
we are getting "name lookup timed out" in curl. Its Singapore location.
@cozyvision:
Hello,
we are getting "name lookup timed out" in curl. Its Singapore location.
This thread is about to have its 7th birthday. You should start a new thread, and give details about what you're trying to do.
@dwfreed:
@cozyvision:Hello,
we are getting "name lookup timed out" in curl. Its Singapore location.
This thread is about to have its 7th birthday. You should start a new thread, and give details about what you're trying to do.
I wanted to let you know that I laughed, like "Woo - What a good joke" then saw that it was a thread opened in 2009. Man, I can't assume anything on the internet.