MySQL Free installation configuration issues

Source: Internet
Author: User
Tags mysql free

Summary:

MySQL is a small relational database management system, MySQL is widely used in small and medium-sized websites on the internet. Because of its small size, fast speed, low total cost of ownership, especially the open source, many small and medium-sized web sites in order to reduce the total cost of ownership of the site chose MySQL as the site database.

First, download the software
MySQL type (recommended to use Thunder download)
32-bit free installation Http://dev.mysql.com/get/Downloads/MySQL-5.6/mysql-5.6.24-win32.zip
64-bit free installation Http://dev.mysql.com/get/Downloads/MySQL-5.6/mysql-5.6.24-winx64.zip

MySQL is divided into 64 and 32-bit versions, which are installed using the 64-bit Win7 system, so this article uses a 64-bit free-install version. 32-bit operating system is similar to the installation, the MySQL version is MySQL5.6.24 version, can be found from the official own download portal, you can directly use the above direct link to download, you can also refer to the "MySQL version of the website"

Second, installation environment

Because this article class write is to use the ZIP compression package, so do not have a graphical installation, similar to the green version of the software, in order to facilitate the management of the root directory to create a new server, as a server-related files installation path, Unzip the Mysql-5.6.24-winx64.zip file, extract the mysql-5.6.24-winx64 file, the mysql-5.6.24-winx64 folder name to MySQL, so that the more concise folder name convenient for later operation, the reader can also be based on their favorite way And then after the decompression, remember the decompression path, so the file is ready.

Iii. Configuration Files

MySQL does not have a My.ini file by default, which requires us to create one manually. How to create it? Do you have a template like php.ini? In fact, in the MySQL5.6.24 with a my-default.ini, can be counted as a template, copy, change the file name My.ini, and then can be used as a MySQL configuration file;

The current installation environment

12 the MySQL installation path is:C:\Server\mysql Data folder path:C:\Server\mysql\data

Open My.ini, here the MySQL installation path is: C:\Server\mysql, the database Data folder is C:\Server\mysql\data, in the configuration file inside the MySQL path and the path of the data to add, and remove the # number;

Original content:

12345 # These is commonly set, remove the # and set as required. # basedir = ... # datadir = ... # port = ... .. # server_id = ...

Modified to:

12345 # These is commonly set, remove the # and set as required. basedir = C:/Server/mysql datadir = C:/Server/mysql/data # port = ... .. # server_id = ...

Note: MySQL installation path is C:\Server\mysql, but the configuration file should be written c:/server/mysql or write C:\\server\\mysql

IV. Environment variables

Add the MySQL Bin folder to the system's environment variable path, here is C:\Server\mysql\bin, added to path;

Then, as an administrator, open cmd, switch to the bin directory, enter: Mysqld-install, after the success of the net start MySQL start MySQL service:

123456 c:\Users\administrator>cd< Span class= "crayon-h" > c:\ server\mysql\< Span class= "Crayon-i" >bin C:\Server\mysql\bin>mysqld -install Service successfully installed. C:\Server\mysql\bin>net start mysql The MySQL service is starting : The MySQL service has started successfully.

Description: Mysqld-install is the installation service, Mysqld-remove is the delete MySQL service. 1067 system error when starting MySQL: My.ini configuration file Error, note that the details of the path is a slash/or \ \, be sure to go to the MySQL bin directory to execute the mysqld-install command.

Enter MYSQL-UROOT-P in the command line, then prompt password, enter directly, then will log in, if prompted that the MySQL service does not exist, the path variable is not added successfully, or the directory is not correct. Login is successful, the MySQL installation is correct and the command window is closed again.

Five, change the password

The default root password is empty, which is dangerous, you must change the password, open the command line as an administrator, enter mysqladmin-uroot-p password < new password > such as new Password 12345678, enter:

123 . mysqladmin -uroot -p password 12345678 .

Then the user because the original password is empty, so the direct return, the hint warning:using a password on the command line interface can be insecure change success;

This time again with the new password to connect MySQL, command line input mysql-uroot-p12345678, note that there is no space after p, the above change password P is a space. Can connect instructions mysql password changed successfully!

Six, service optimization

Enter window service inside can see MySQL is automatically start, if do not need to start automatically can, change it to manual, next time need to use, directly in the service inside start, or in command line input, net start MySQL, can start MySQL service manually.

So far, MySQL installation is complete!

Problem:

Install MySQL under WinDOS cmd

Execute under the bin directory of MySQL: mysqld--install

Error:

The information is as follows:

Install/remove of the Service Denied

Workaround:

When opening the Cmd.exe program, select "Open as Administrator".

Original: http://www.xinsaisai.com/mysql56-zip-deploy.html

MySQL Free installation configuration issues

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.