• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Issue Problemas con mysql

Inma

Regular Pleskian
mysqlcheck --all-databases -u admin -p`cat /etc/psa/.psa.shadow` --auto-repair

---
mysqlcheck: Got error: 2013: Lost connection to MySQL server during query when executing 'CHECK TABLE ... '

---
it does not repair, it seems to repair but at the end it gives an error of lost connection

this server is constantly down for mysql... I have repaired it a thousand times with the plesk repair... it is, super updated in the log, only broken bd that should be repaired.

I do not know where to look more



1694431582697.png
 
The reason is very likely a corrupt table, but this does not necessarily have to be a table from the psa database. The table name that is affected (or the table names) are mentioned in the log. Plesk "repair" can also not repair user databases. Whenever such a corrupt table is addressed by the database, the database can crash. To fix the issue, you'll need to first identify the affected tables and replace them by correctly configured tables. This means: Remove them and restore them from a dump (or other type of backup).
 
Is there any way to see all the corrupted tables on a server?

And I can repair it from phpmyadmin, once repaired.. how do I know if it has really done it.. thanks
 
should I look at the "broken" results and fix them one by one?

cat /var/log/mysql/error.log | grep "crash"
--

all the table's I get to see this right?
 
You'll have to check each table. If MySQL cannot repair them itself (e.g. using the repair tool - not the Plesk repair, but the MySQL repair), chances are they need to be restored from a backup.
 
what is the mysql repair tool?
because this one does not repair it and it gives error
mysqlcheck --all-databases -u admin -p`cat /etc/psa/.psa.shadow` --auto-repair

-----

and with phpmyadmin it doesn't do anything but give me a ok
 
mysqlcheck is the correct tool.
Well, as said before, you'll need to restore tables (or databases) from a backup if repair cannot fix them.
 
mysqlcheck --all-databases -u admin -p`cat /etc/psa/.psa.shadow` --auto-repair

---
in this command ends up giving an error...

is it possible to try to repair using the command little by little because there are so many to repair that it crashes?
1694516849839.png
 
The offending table should be logged to /var/log/messages. If not for the mysqlcheck tool, that at least immediately before the database server crashes. You can find the table by checking that log entry.
 
It does not finish repairing with the error that I detail and this is displayed

thanks
---

1694532420526.png


kernel: [8565625.452262] oom_reaper: reaped process 27778 (mysqld), now anon-rss:0kB, file-rss:0kB, shmem-rss:0kB
 
Back
Top