title: PHP 7.0 and MySQL start-up error "undefined symbol: mysqlnd_allocator in Unknown"
body: <p>Getting this warning on a custom-compiled version of PHP7, even when running <code>php -v</code>.</p>
  
  <p>Tried all solutions posted.  What could cause this?</p>
  
  <blockquote>
    <p>PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/lib/php/20151012/pdo_mysql.so' - /usr/lib/php/20151012/pdo_mysql.so: undefined symbol: mysqlnd_allocator in Unknown on line 0</p>
  </blockquote>
  
  <p>There are similar questions to this, but they are not quite the same problem - they generally relate to a missing <code>mcrypt</code> library. I confirmed that mycrypt is in fact loaded, as well as pdo_mysql when printing out phpinfo().</p>
  
  <p>Is there something wrong with the order? Also, this is for PHP 7, which I believe has different formats for ini files.</p>
  
  <hr>
  
  <p>Edit: Following instructions here for recompile.  Not too experienced in this: <a href="http://www.hashbangcode.com/blog/compiling-and-installing-php7-ubuntu" rel="noreferrer">http://www.hashbangcode.com/blog/compiling-and-installing-php7-ubuntu</a></p>
  
  <p>Also, removed MySQL completely with <code>apt-get purge</code>.  No luck with anything.</p>