curl / Mailing Lists / curl-library / Single Mail
Buy commercial curl support from WolfSSL. We help you work out your issues, debug your libcurl applications, use the API, port to new platforms, add new features and more. With a team lead by the curl founder himself.

Re: Connection refused - subdomain problem suspected

From: Richard Elen via curl-library <curl-library_at_cool.haxx.se>
Date: Thu, 5 Sep 2019 20:28:03 +0100

Hi Christopher and thanks for the comments from you and other respondents.

To answer your question:

  * A PHP script on the "admin" server can successfully make a Curl
    connection to all other hosts we've tried.
  * In addition, a PHP script on ANY OTHER machine we've tried can
    successfully make a Curl connection with the "streams" host.

It's solely that we can't get a script on "admin" to make a successful
Curl connection with "streams".

My suspicion at this point is that we have a DNS issue, though I don't
know what it might be. The domain is hosted by a third party and on
their system we have A records for both "streams" and "admin" - but
that's all. "streams" has been running successfully for two years
without any evident DNS issues.

The "admin" host is a cPanel system from our hosting provider - with the
limitations on access that implies. The "streams" host is a dedicated
Linux server.

I am wondering what would happen if I deleted the A record for the
"admin" machine and simply used its default hostname as given by our
service provider. It's not going to be a publicly-accessed machine anyway.

Doing a few searches I see that it is apparently not unknown to get curl
connection failures on two hosts within the same domain, but there
doesn't seem to be a consistent cause. Can anyone shed any light on this?

Thanks!

--Richard E

On 05-Sep-19 18:18, Christopher Head wrote:
> A quick idea for debugging: can a PHP script on the same server make a Curl connection to some other target? If yes, suspect firewall or DNS issues. If no, but a command line curl invocation works, then I would suspect a PHP issue on that particular install. Not sure if safe mode or something similar still exists in PHP; if so, perhaps that is denying outbound connections?

-------------------------------------------------------------------
Unsubscribe: https://cool.haxx.se/list/listinfo/curl-library
Etiquette: https://curl.haxx.se/mail/etiquette.html
Received on 2019-09-05