Php - Your PHP installation appears to be missing the MySQL extension which is required by WordPress

Php - Your PHP installation appears to be missing the MySQL extension which is required by WordPress

  1. Blog
  2. 15 November 2026
  3. 3 min read

Stefan Bogdanescu

Founder & Senior Architect

Decoding the MySQL Extension Error on FFP NAS

When deploying WordPress on a FreeNAS (FFP) environment, specifically version 0.7 running on hardware like the Zyxel NSA310, you might encounter a specific error message: "Your PHP installation appears to be missing the MySQL extension which is required by WordPress." This message often triggers confusion because the database connection itself seems functional—you can run mysqld, access data via phpMyAdmin, and even see the MySQLi module active within your phpinfo() output.

The root cause of this discrepancy lies in how PHP distinguishes between different MySQL drivers and how older distributions like FFP 0.7 managed these dependencies. The error is not necessarily stating that database connectivity is broken, but rather that a specific legacy extension expected by certain WordPress configurations or validation routines is absent.

In your php.ini located at /ffp/etc/php.ini, you have correctly uncommented a comprehensive list of extensions. You included both extension=php_mysql.dll and extension=php_pdo_mysql.so. The confusion arises because modern PHP versions typically prioritize the PDO (PHP Data Objects) driver over the legacy mysql_* functions. However, WordPress checks for the presence of the mysql extension specifically in some contexts, or simply requires that the legacy API be available if your application logic relies on it.

The fact that phpinfo() shows MySQLi activated but not MySQL confirms that the modern driver is loaded, but the legacy one is not. On UNIX-like systems (which FreeNAS is), the file extension for compiled modules should generally be .so, though FFP 0.7 supports both .dll and .so. Your configuration attempts to load multiple variations:

extension=php_mysql.dll
extension=pdo_mysql.so

If php_mysql.dll is missing from your extension path, PHP will skip it without throwing a fatal error during the bootstrap phase, unless explicitly requested. The "missing MySQL extension" warning often appears because WordPress's own validation checks for the mysql module to ensure compatibility with its legacy API functions. If you are using a newer version of WordPress on an older FFP base, this mismatch is common.

To resolve this without switching your entire stack to a modern PHP distribution like Alpine Linux or TrueNAS Core immediately, you need to ensure the correct library path is registered. The comment in your php.ini suggests placing the extension at /ffp/lib/extensions/no-debug-non-zts-20100525/mysql.so. Verify that this file actually exists in that directory. If it does not exist, compiling PHP with FFMCG (FreeNAS Free Edition) often bundles these extensions differently depending on the build flags used during installation.

A persistent issue you mentioned involves the MySQL shortcut disappearing after every reboot. This is a classic symptom of how FFP 0.7 handles service persistence versus network configuration. The service manager likely removes temporary symlinks or network shortcuts upon restart to prevent stale connections, requiring manual reconfiguration of the database path in /ffp/opt/mysql. To fix this permanently, you should ensure your startup scripts explicitly mount or link the database directory before launching the MySQL daemon and PHP services.

If you do not strictly require the legacy mysql API for your specific WordPress instance, the most pragmatic solution is to update the WordPress configuration to utilize PDO exclusively. You can enforce this by ensuring only the PDO extensions are loaded in php.ini and verifying that your wp-config.php does not reference deprecated functions. For developers managing legacy infrastructure, understanding that "missing extension" warnings don't always equate to total failure allows you to pivot toward modernizing the stack or adjusting the validation logic rather than chasing phantom missing DLLs.

For those maintaining similar setups in the future, migrating from FFP 0.7 to a more actively maintained distribution like TrueNAS Scale is often the most robust long-term strategy, as it resolves these legacy extension conflicts and service persistence issues out of the box.

Our network