MySQL Community Server Data installation graphic tutorial

Source: Internet
Author: User
Tags bind mysql client win32 administrator password mysql command line
Open the downloaded installation file and the following page is displayed:
Start the mysql installation wizard and click "next" to continue the next step.
Select the installation type, which has three options: "Typical (default)", "Complete (Complete)", and "Custom (Custom)". Select "Custom ", there are more options to familiarize yourself with the installation process.
Click "Mysql server" and select "This feature, and all subfeatures, will be installed on local hard drive. ", that is," this part and its sub-parts are all installed on the local hard disk ". Click "Change ...", Manually specify the installation directory.
Confirm the previous settings. If there is an error, press "Back" to return the redo. Click "Install" to start installation.
Installing. Please wait until the following interface appears.
 
Click "next" to continue. The following page is displayed.

Considerations for installing Mysql and five reasons for installation failure


Error 1: cannot create Windows service for mysql. error: 0

Solution: Open the command line and enter the SC delete mysql command
C:> SC delete mysql
[SC] DeleteService SUCCESS
Restart the computer, or restart the computer and then install it. I restarted it after uninstalling it.

To uninstall and reinstall Mysql, you must delete the Mysql folder in the c: \ Documents Ents and Settings \ All Users \ Application Data directory after uninstalling Mysql on the control panel. The configuration information you uninstalled may be recorded, which may be affected during the next installation.

Error 2: When the administrator enters the password, there is a row of current password besides password and confirm password.

This indicates that you have not deleted the Mysql folder under the Directory described in Article 1st before installation. I don't know whether it will affect subsequent use. It doesn't matter if I remember the password. In addition, the administrator password is set by himself, and the user name is the default root.

After the installation is successful, you can test the following: open mysql command line client, enter the password, and
Welcome to the MySQL monitor. Commands end with; or \ g.
Your MySQL connection id is 3
Server version: 5.1.33-community MySQL Community Server (GPL)
Type 'help; 'or' \ H' for help. Type '\ C' to clear the buffer.
Mysql>
The installation is successful!

Error 3: mysql server configuration failed.

In the Configuration Wizard, the following statements are displayed:
Mysql-server-5.5-win32: 60-Adding firewall rule for MySQL55 on port 3306.
Mysql-server-5.5-win32: 66-Adding firewall rule failed.
Indicates that the firewall fails to be installed.

View the installation log and find the following statement:
Mysql-installer Information: 10: Attempting to create firewall rule with command: netsh.exe firewall add portopening protocol = TCP port = 3306 profile = ALL name = MySQL55 mode = ENABLE scope = ALL
Mysql-installer Information: 10: Unexpected response from netsh: OK.
Mysql-installer Information: 10: Attempting to create firewall rule with command: netsh.exe advfirewall firewall add rule name = "Port 3306" protocol = TCP localport = 3306 dir = in action = allow
Mysql-installer Information: 10: Unexpected response from netsh: the following command is not found: advfirewall firewall add rule name = "Port 3306" protocol = TCP localport = 3306 dir = in action = allow.

This situation indicates that mysql installation does not support the Chinese system well and does not recognize the exact response information of netsh.exereturned, and runs the netsh.exe advfirewall command that can be run on another Windows platform. (This command is not supported by xp, so an error cannot be found.

There are two solutions:
① Set the language of your operating system to English, and then reinstall mysql. You can go to Control Panel> area and language to change the settings. In addition, check whether the current user has the permission to start the firewall and view the properties of the Application Layer Gateway Service in computer services, check whether the user on the logon tab is the current user.
② Check the firewall Port. If it has been successfully added, it will not be processed. If it is not successfully added, manually add the port to the firewall.

Error 4: After the installation is successful, you can only connect to the mysql server of localhost through mysql 5.5 command line client, instead of remotely connecting to the mysql server through workbench or other client tools.

Keyword: cannot remotely connect to mysql server.

Possible causes:
① No port is opened. See the previous article.
② The user has not authorized remote connection.
③ Mysql server does not allow remote connection.

If the user does not authorize remote connection, you can authorize the user. For example, the default root user can enter the following command in mysql 5.5 command line client:
// Select a database
Mysql> use mysql;
// Authorize the user. Replace the yourpassword field with your password.
Mysql> grant all priileges on *. * to identified by 'yourpassword ';
// Refresh the system permission list
Mysql> flush privileges;

// Check whether the authorization is successful
Mysql> show grants for roots;

If the preceding authorization is displayed, the authorization is successful. If it fails, add another new user. Add the user's command:
Insert into mysql. user (Host, User, Password, ssl_cipher, x509_issuer, x509_subject) values ("%", "newuser", password ("newpassword "),'','','')

③ If mysql server does not allow remote connection, find your own my. ini and add a statement under [mysqld:
Bind-address = 0.0.0.0
It means you do not bind an IP address and restart your Mysql service.


Error 5: location of the configuration file my. ini

The MySQL configuration wizard places the my. Ini file in the installation directory of the MySQL server. This will help associate the configuration file with a specific server instance. To ensure that the MySQL server knows where to find my. ini file. Parameters similar to the following content will be passed to the MySQL server as part of the service installation: -- defaults-file = "C: \ Program Files \ MySQL Server 5.5 \ my. ini C: \ Program Files \ MySQL Server 5.5 can be replaced by the installation path pointing to the MySQL Server.

Edit my. ini file: you can use a text editor to open the file and make necessary edits and modifications. You can also modify the server configuration using the MySQL Administrator application. The MySQL client and application, such as the mysql command line client and mysqldump, cannot determine the location of the my. Ini file in the server installation directory. To configure the client and application, generate a new file my. ini in C: \ Windows or in the C: \ WINNT directory based on your Windows version.

If your MySQL configuration wizard finds an existing my. ini file. You can reconfigure an existing server or delete my. ini file, stop and remove the MySQL service to remove the server instance. To reconfigure an existing server, select the "reconfigure instance" option and select the "next" button. The existing my. ini file is renamed as mytimestamp. ini. bak. The timestamp is the date and time when the existing my. ini file was created. Remove an existing database instance, select the "remove instance" option, and select the "next" button. If the "remove instance" option is selected, the confirmation page is displayed. Click "run". The MySQL configuration wizard stops and begins to remove MySQL services and deletes the my. Ini file. However, the server installation directory is not removed. If you select the "reconfigure instance" option to go to the "configuration type" interface, you can select the installation type you want to configure.

Related Article

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.