Symptoms
When trying to backup a cPanel account, you may find one of the following errors happening regarding a database:
mysqldump: Couldn't execute 'SHOW FUNCTION STATUS WHERE Db = 'place_holder'': Column count of mysql.proc is wrong. Expected 21, found 20. The table is probably corrupted (1805)
mysqldump: Couldn't execute 'show events': Failed to open mysql.event (1545)
Description
These generally occur when the 'mysql_upgrade' command needs to be run; we can confirm that is the issue by looking for errors similar to this in the MySQL error log:
[2021-11-08 02:13:02 +0200] Cpanel::Exception::ProcessFailed::Error/(XID 5b64j2) “/usr/bin/mysqldump” reported error code “2” when it ended: mysqldump: Couldn't execute 'show events': Failed to open mysql.event (1545)
[2021-11-08 02:13:02 +0200] mysqldump: Couldn't execute 'SHOW FUNCTION STATUS WHERE Db = 'place_holder'': Column count of mysql.proc is wrong. Expected 21, found 20. The table is probably corrupted (1805)
STDERR: mysqldump: Couldn't execute 'show events': Cannot proceed, because event scheduler is disabled (1577)
mysqldump: Couldn't execute 'SHOW FUNCTION STATUS WHERE Db = 'cpdatabase_wp1'': Column count of mysql.proc is wrong. Expected 21, found 20. The table is probably corrupted (1805)
Workaround
To correct this, run the following command via SSH as the root user:
mysql_upgrade
Comments
0 comments
Article is closed for comments.