title: PHP's PDO is ignoring the ATTR_TIMEOUT option for MySQL when server cannot be reached
body: <p>I'm testing scenarios where the mysql server cannot be reached by putting in a random IP to try to connect to. I set PDO's options to time out after one second using <code>PDO::ATTR_TIMEOUT =&gt; 1</code>. However, it still takes 30 seconds to throw an exception. I'm guessing this timeout only applies to the actual mysql connection time, not to the server on which mysql is running.</p>
  
  <p>What PHP options do I need to change to time out the connection to the mysql server?</p>