Repairing the MySQL database
| Article:HOWTO59404 | | | Created: 2011-10-04 | | | Updated: 2011-10-04 | | | Article URL http://www.symantec.com/docs/HOWTO59404 |
Symantec Support may ask you to check the status of the MySQL database. If the check results in an error message, repair the database.
You must know the MySQL password to check or repair the database.
To repair the MySQL database on Windows
At the command prompt, type the following command:
mysqlcheck --user=brightmailuser --host=127.0.0.1 -- password=<password> brightmail --auto-repair > check.txt C:\Program Files\Symantec\SMSSMTP\MySQL\Bin>mysqlcheck -- user=brightmailuser --host=127.0.0.1 --password=PASSWORD brightmail --auto-repair > check.txt
This command repairs the corrupted tables and places the results in the file
check.txt. The amount of time it takes to get results depends on the size of the MySQL database. The larger the database, the longer the time.After the MySQL check finishes, type the following command to see the results:
notepad check.txt
All tables should have the message of OK or Table is already up-to-date next to them. If they do not, you must repair them manually.
To repair a specific table, log on to MySQL with the following command:
mysql --host=127.0.0.1 --user=brightmailuser -- password=<password> brightmail
At the command prompt, type the following command:
repair table <tablename>
where <tablename> is the name of the corrupted table.
After the repair finishes, a table appears. Check and ensure that the status field contains the words "OK."
To repair the MySQL database on Linux
At the prompt, type the following command to change to the MySQL directory:
cd /opt/symantec/sbas/ControlCenter/MySQL/ Mysql-pro-4.0.16 -pc-linux-i686/bin cd /opt/Symantec/SMSSMTP/mysql/bin
If your MySQL installation is in a different location, use that path.
If the status check returns an error, type the following command:
./mysqlcheck --host=127.0.0.1 --user=brightmailuser -- password=<password> brightmail --auto-repair > check.txt
This repairs the corrupted tables and places the results in the file
check.txt. The amount of time it takes to get results depends on the size of the MySQL database. The larger the database, the longer the time.After the MySQL check finishes, type the following command to see the results:
vi check.txt
All tables should display the message OK or Table is already up-to-date next to them. If they do not, you must repair them manually.
To repair a specific table, log onto MySQL with the following command:
./mysql --host=127.0.0.1 --user=brightmailuser -- password=<password> brightmail
At the prompt, type the following:
repair table <tablename>
where <tablename> is the name of the corrupted table.
After the repair of the table finishes, a table appears. Check that the status field contains the word "OK."
To repair the MySQL database on Solaris
At the prompt, type the following command to change to the MySQL directory:
cd /opt/symantec/sbas/ControlCenter/mysql-pro-4.0.16- sun-solaris2.8-sparc/bin cd /opt/Symantec/SMSSMTP/mysql/bin
If your MySQL installation is in a different location, use that path.
If the status check returns an error, type the following command:
./mysqlcheck --host=127.0.0.1 --user=brightmailuser -- password=<password> brightmail --auto-repair > check.txt
This repairs the corrupted tables and places the results in the file
check.txt. The time to put the results in the file depends on the size of the MySQL database. The larger the database, the longer the time.After the MySQL check finishes, type the following command to see the results:
vi check.txt
All tables should have the message of OK or Table is already up-to-date next to them. If they do not, you must repair them manually.
To repair a specific table, log onto MySQL using the following command:
./mysql --host=127.0.0.1 --user=brightmailuser -- password=<password> brightmail
At the prompt, type the following command:
repair table <tablename>
where <tablename> is the name of the corrupted table. After the repair finishes, a table appears. Check that the status field contains the word OK.
|
|
Legacy ID
v41520307_v64406064
Article URL http://www.symantec.com/docs/HOWTO59404
Terms of use for this information are found in Legal Notices









Thank you.