Hie guys out there. I am running linux ubuntu server for my website. My website database crashed with this error messages: DB function failed with error number 145 Table './cmsmycompany/l2m_session' is marked as crashed and should be repaired SQL=SELECT session_id FROM l2m_session WHERE session_id=MD5('7fbe5d447d34103616a0c38c3212183f') SQL = SELECT session_id FROM l2m_session WHERE session_id=MD5('7fbe5d447d34103616a0c38c3212183f') How do i repair the database.
thanks! i failed to hightlight that i am still in the learning curve. How exactly should l repair the table. Is the command i should issue are they. thanks
log into your mysql console and execute this command. this is an SQL command. you can also choose to check all databases and all tables, but this id done with a command line program called "mysqlrepair" run: mysqlrepair -A -p -u root enter your root password and it'll repair all your tables that need to.
mysqlrepair -A -p -u root could not be executed not recognised command. When I run myisamchk fixsudo myisamchk --safe-recover /var/lib/mysql/databasename/tablename.MYI I am getting an error message that '/var/lib/mysql/databasename/tablename.MYI does not exist. When i restart the mysql I am getting not cleanly closed as follows: sudo /etc/init.d/mysql start * Starting MySQL database server mysqld [ OK ] * Checking for corrupt, not cleanly closed and upgrade needing tables. an assistance.
Code: which mysqlrepair or just do: mysql[tab][tab] to see all available commands. there should be about 20+ commands starting with mysql .. if not then you might miss a mysql package
yes. mysql command are there but no mysrepair only mysql_fix extensions and mysql_fix privilages _tables and a lotmore
mysqlrepqir is in the mysql-client-5.1 package (5.1 for lucid release) just: aptitude search mysql-client- and see if the version your repository has is installed, probably not. so you do apt-get install mysql-client