Mysql-5.6-win32 Install-free version configuration

Source: Internet
Author: User
Tags win32

Environment:

Windows 2003/2007/2008/2010 X86

method/Step:

1. Download Mysql-5.6.17-win32; official website: http://dev.mysql.com/downloads/

2. Extract to the custom directory, the demo address is D:\tools\mysql\

3. Copy the My-default.ini under the root directory and change the name to My.ini,my.ini replace with the following content

#以下是复制内容, it's not a copy.

[Client]

port=3306

Default-character-set=utf8

#客户端字符类型, consistent with the service side, recommended UTF8

[Mysqld]

port=3306

Character_set_server=utf8

#服务端字符类型, it is recommended that UTF8

Basedir=d:\tools\mysql

#解压根目录

Datadir=d:\tools\mysql\data

#解压根目录 \data

Sql_mode=no_engine_substitution,strict_trans_tables

[Winmysqladmin]

D:\tools\mysql\bin\mysqld.exe

#解压根目录 \bin\mysqld.exe

#以上是复制内容, it's not a copy.

4. Environment variable Configuration

My Computer-Properties-advanced-environment variables-new

Variable Mysql_home value D:\tools\mysql

Find the variable path edit, add it at the back;%mysql_home%\bin

5.MySQL Installation

run the input cmd, or locate the C:\Windows\System32\cmd.exe, and go to the MySQL decompression directory bin subdirectory,

C:\Documents and settings\administrator>cd\

C:\>d:

D:\>CD Tools

D:\TOOLS>CD MySQL

D:\TOOLS\MYSQL>CD bin

D:\tools\mysql\bin>

D:\tools\mysql\bin>mysqld-install

Tip: Service successfully installed. And the installation is successful.

CMD command: cd\ returns the root directory

D: Enter D drive

CD tools into the Tools folder

6. Start, stop, and move out of the MySQL service

Start MySQL service: net start MySQL

Stop MySQL service: net stop MySQL

Move out of MySQL service: mysqld-remove

The service is started here to facilitate next steps.

7. Change the root password:

enter CMD in the run, jump to the installation directory/bin,

D:\tools\mysql\bin>mysql-uroot

Mysql>show databases;

Mysql>use MySQL;

Mysql>delete from User where user= "";

Mysql>update User Set Password=password (' NewPassword ') where user= ' root ';

Mysql>flush privileges;

mysql>quit;

FLUSH privileges: Force MySQL to reload permissions and take effect immediately

At this point you can log in with the following command:

D:\tools\mysql\bin>mysql-uroot-p

Enterpassword:newpassword

8: Common Commands

mysql>show databases; Show All Tables

Mysql>use MySQL; Switch to table MySQL

Mysql>show tables; Show the structure of a table

Precautions
    • CMD to run as Administrator

    • Enter MySQL input command to end with a semicolon






Mysql-5.6-win32 Install-free version configuration

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.