Windows install MySQL database graphics and text tutorial

Source: Internet
Author: User
Tags ini mysql download win32 administrator password mysql command line

MySQL Download address: http://dev.mysql.com/downloads/mysql/


MySQL Database installation steps:


1, first double-click the MySQL installation file, the installation of the Database Wizard interface, click "Next" continue to install, as shown in the picture:

2. In the window where the Select installation type appears, there are "typical (default)", "Complete (Full)", "Custom (user-defined)" Three options, we choose "Custom", through the customization can do some personalized settings, click "Next" to continue the installation, As shown in the figure:


3, in the appearance of the custom installation interface to choose the MySQL database installation path, point Change button, here I set the "E:mysql5", click "Next" continue to install, as shown:

4, the next step into the installation of the interface, first confirm the previous settings, if wrong, press "back" returned, no errors, click the "Install" button to continue the installation, as shown in the picture:

5, click the "Install" button appears following the installation of the interface, after a period of time, MySQL database installation completed, the completion of the MySQL installation interface, as shown in the picture:

This interface clicks the "Next" button.

6, click "Finish" button, the following Configuration Interface Wizard appears, click "Next" to configure, as shown in the figure:

7, in the Open Configuration Type window Select the way to configure, "Detailed Configuration (Manual precise configuration)", "Standard Configuration (Standard configuration)", we choose "Detailed Configuration (Manual exact configuration), click Next to continue, as shown in the figure:


8. In the window that appears, select the type of server, Developer Machine (Development test Class), Server Machine (server type), dedicated MySQL server Machine (Specialized database server), If it is for learning and testing, the default is OK, click "Next" to continue, as shown in the figure:


9, in the appearance of the configuration interface to choose the use of MySQL database, "The Multifunctional Database (Universal multi-function)", "Transactional database only (server type)", " Non-transactional Database only (non-transactional) ", here I select the first item, general installation, click" Next "continue to configure, as shown in the figure:


10, in the next appearance of the interface, for the InnoDB tablespace configuration, is to InnoDB database files to choose a storage space, if modified, to remember the location, when the time to reload to choose the same place, it may cause database damage, of course, Make a backup of the database is no problem, generally do not have to modify, the default line, directly click the Next button, as shown in the picture:

11, in the open page, choose the amount of MySQL access, at the same time the number of connections, "Decision Support (DSS)/olap (20)", "Online Transaction Processing (OLTP) (500 or so)", "Manual Setting (set manually, set to 500) here, select manual Settings and click" Next "to continue, as shown in the figure:


12, in the open page to set whether to enable TCP/IP connections, set the port, if not enabled, you can only access the MySQL database on your own machine, this is the program to connect the database needs to do the configuration, the default port is 3306, and enable strict syntax settings, click "Next" to continue, As shown in the figure:


13, in the Open character code page, set MySQL to use the character encoding, the first is the western code, the second is a multi-byte universal UTF8 encoding, the third is manual, we select Utf-8, next click "Next", continue to configure, as shown:


14, in the open page to choose whether to install MySQL as a Windows service, you can also specify service name (services identity name), whether the MySQL bin directory to add to Windows PATH (after joining, you can directly use the file under Bin), Instead of pointing to the table of contents, the default setting is usually the right line, directly next, as shown in the figure:


15. Set the default root (super Admin) password on the open page, enable root remote access, click "Next" to continue configuration, as shown in the figure:


16. All of the configuration operations here have been completed, and click the Execute button to perform the configuration as shown in the figure:


17, after a few minutes, the following prompts the interface on behalf of the MySQL configuration has ended, and prompted the success of the information, at this point, MySQL installation and configuration complete.

MySQL Installation considerations


One, Wizard install last page, appear cannot create Windows service for mysql.error:0 Error

WORKAROUND: Open the command line to enter SC delete mysql command that
C:>SC Delete MySQL
[SC] DeleteService SUCCESS
Reboot the computer, or reboot and install after unloading, which is fine. I was restarted after the uninstall.

Uninstall reinstall to notice a problem, in the Control Panel uninstall, to the C:/Documents and Settings/all users/application Data directory to delete the MySQL folder. It may record the configuration information you uninstalled, which will affect the next installation.

Second, there is a line of current password in addition to password and Confirm password when the input administrator enters the password.
This means that you did not put the MySQL folder in the directory that I mentioned in article 1th before you installed it. Do not know whether to affect the subsequent use, may remember the password does not matter. In addition, the administrator password is set by itself, and the user name is the default root.

After successful installation, you can test the following: Open the MySQL command line client, enter the password, appear
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!

Third, MySQL server configuration failed.

Viewing the error message in the Configuration Wizard has the following statement:
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 installation failed.

View the installation log to find the following statement:
Mysql-installer information:10:attempting to create firewall rule with Command:netsh.exe Firewall add portopening Pro Tocol=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 Rul E name= "Port 3306" protocol=tcp localport=3306 dir=in Action=allow
Mysql-installer information:10:unexpected response from Netsh: The following command was not found: Advfirewall firewall add Rule name= "Port 3306" Protocol=tcp localport=3306 dir=in Action=allow.

This situation indicates that the MySQL installation is not good for Chinese system, does not recognize the "OK" information returned by Netsh.exe, and then runs the Netsh.exe advfirewall command that can run on other Windows platforms (this command XP does not support Therefore, the report could not find the error of the command.

There are two solutions:

① set the language of your operating system to English, and then reinstall MySQL. Specific can be entered into the Control Panel-> region and language to change; In addition, check that the current user has permission to start the firewall, view the properties of the application Layer Gateway service in the computer service, and see if the user in the Login tab is the current user.
② Check the firewall port, if it has been added successfully, do not process, if not successfully added, you manually add a port in the firewall.


V. Location of configuration file My.ini

The MySQL Configuration Wizard places the My.ini file in the MySQL server installation directory. This will help you associate a configuration file with a specific server instance. To ensure that the MySQL server knows where to look for My.ini files, parameters similar to the following will be passed to the MySQL server as part of the installation of the service:--defaults-file= "C:/Program Files/mysql/mysql Server 5.5/my.ini c:/program Files/mysql/mysql Server 5.5 can be replaced by an installation path that points to the MySQL server.

Edit My.ini: You can use a text editor to open the file and make the necessary edits and modifications. You can also modify the server configuration with the MySQL administrator application. MySQL clients and applications, such as the MySQL command line client and mysqldump, do not determine the location of the My.ini file located in the server installation directory. To configure the client and the application, generate a new file My.ini file under C:/windows or C:/winnt directory, depending on your version of Windows

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.