title: How to simulate "MYSQL has gone away" error?
body: <p>I'm running lots of cron job and once in a while there is a <em>MYSQL has gone away</em> error.</p>
  
  <p>I've now written some code to handle the error, but how do I simulate the error on my localhost so that the code can be tested thoroughly?</p>