After reloading the system MySQL

Source: Internet
Author: User

Yesterday Win7 suddenly started to, helpless, can only re-install the system.

Prior to installing MySQL is the Windows Installer, and installed on the D disk, the database is stored in the D-disk programdata. Now, after the reload is complete, how to restore the normal use of MySQL. Because the general open source program uses the WINDWS COM component basically does not have, therefore basically only then re-registers the service to be possible. Open CMD,CD to MySQLServer in the bin directory, my is: D:\MySQL\MySQL Server 5.6\bin directory. Input: mysqld install MySQL--defaults-file= "D:\ProgramData\MySQL\MySQL Server 5.6\my.ini" This command means registering the MySQL service with My.ini configuration. My.ini has all of our previous SQL configurations saved. After the carriage return, you will be prompted: Service successfully installed. Then enter: net start mysql This command means to start the MySQL service. After you enter, you will be prompted: The MySQL service is starting. The MySQL service has started successfully. Ok,mysql has been repaired, in other clients have been able to use the database, account password and so on have not changed. Note The MySQL Workbench interface program connects to the database and requires a new connection. But the root account password has not changed. In the middle if the service is registered with the wrong my.ini, you can use: mysqld Remove to remove the service, and then repeat the steps above.

After reloading the system MySQL

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.