title: curl: Ran on Different Servers Returned Different IP Addresses
body: <p>I've been struggling to figure out why my page which uses <code>curl</code> library in PHP worked on my <em>dev machine</em> but failed on my <em>remote server</em>. One suspicion is that it's related to whether the <code>curl</code> has an SSL support, as indicated in <a href="http://php.net/manual/en/function.curl-exec.php" rel="nofollow">one of the comments here</a>:</p>
  
  <blockquote>
    <p>If your curl installation is not compiled with SSL support you will beat your head against a wall when trying to figure out why curl_exec() is failing to fail or do anything else ...</p>
  </blockquote>
  
  <p>So, I ran <a href="http://www.php.net/manual/en/function.curl-version.php" rel="nofollow">this script</a> to find out whether SSL is supported on both my <em>dev machine</em> and <em>remote server</em>. Both my <em>dev machine</em> and <em>remote server</em> produced the following (looks like both support SSL):</p>
  
  <blockquote>
    <p>CURL_VERSION_IPV6 matches CURL_VERSION_KERBEROS4 does not match CURL_VERSION_SSL matches CURL_VERSION_LIBZ matches</p>
  </blockquote>
  
  <p>However, when I ran <code>curl</code> from the command line on my <em>remote server</em> (the one where my script failed), here's what I got (i.e. <code>curl</code> hang):</p>
  
  <pre><code>curl -v http://&lt;my-domain&gt;/blog/press-release/
  * About to connect() to &lt;my-domain&gt; port 80
  *   Trying 66.201.45.235... 
  </code></pre>
  
  <p>The same <code>curl</code> command line worked fine on my <em>dev machine</em> although it returned a different IP address:</p>
  
  <pre><code>curl -v http://&lt;my-domain&gt;/blog/press-release/
  * About to connect() to &lt;my-domain&gt; port 80 (#0)
  *   Trying 10.3.1.207... connected
  </code></pre>
  
  <p>Please... please help? Any other way to figure out the differences between the installed <code>curl</code> on my <em>dev machine</em> and <em>remote server</em>? <strong>Why did they return different addresses?</strong></p>