Articles in this section

Unable to access a website or access Plesk System Updates: Error 500 MySQL server has gone away

Plesk for Linux kb: technical ABT: Group A

Applicable to:

  • Plesk for Linux

Symptoms

  • Unable to access the Drupal website with the error:

    CONFIG_TEXT: 500 error


    CONFIG_TEXT: Additional uncaught exception thrown while handling exception

  • Some database operations via WordPress plugin may fail (for example, backup/restore with plugin WPVIVID)

  • Going to Tools & Settings > System Updates, the Plesk System Updates page might fail to be accessed with the following error:

    CONFIG_TEXT: Server Error
    500 PDOException
    SQLSTATE[HY000]: General error: 2006 MySQL server has gone away

The following error might be found in MySQL logs:

CONFIG_TEXT: 2021-03-10 20:55:43 3249 [Warning] Aborted connection 3249 to db: 'psa' user: 'admin' host: 'localhost' (Got timeout reading communication packets)

The following error might be found in Plesk log:

CONFIG_TEXT: [10-Mar-2021 20:56:43 Europe/Berlin] PHP Warning: Error while sending QUERY packet. PID=25349; File: /opt/psa/admin/plib/vendor/plesk/zf1/library/Zend/Db/Adapter/Pdo/Abstract.php, Line: 307

The following error can be found in website logs:

CONFIG_TEXT: [fcgid:warn] [pid 4997:tid 140222016743168] [client 203.0.113.2:48318] mod_fcgid: stderr: PHP Fatal error: Uncaught exception 'PDOException' with message 'SQLSTATE[HY000]: General error: 2006 MySQL server has gone away' in /var/www/vhosts/example.com/httpdocs/includes/database/database.inc:2227

Cause

Insufficient value for max_allowed_packet or wait_timeout parameters.

Resolution

Increase  max_allowed_packet or wait_timeout parameters according to the article How to set the value of max_allowed_packet or wait_timeout for MySQL on Plesk server?

Was this article helpful?

Comments

0 comments

Please sign in to leave a comment.