MySQL installation --windows version

Download
Step one: Open URL, https://www.mysql.com, click after the jump to https://www.mysql.com/downloads downloads

Step two: Go to the URL https://dev.mysql.com/downloads/, select Options Community

Step 3: Click MySQL Community Server enter https://dev.mysql.com/downloads/mysql/ page, then click the 5.6 version of the database

Step four: windows operating system version 5.6 after the click will jump to https://dev.mysql.com/downloads/mysql/5.6.html#downloads URL, the page as shown below, to download the good version and operating system, click Download

Step five: you can not log in or register, simply click No thanks, just start my download can be downloaded.

Unzip
the downloaded zip file unzip the file after decompression folder into any directory, this directory is mysql installation directory.

Configuring
Open Directory, you will see my-default.ini profile, use notepad ++ or pycharm (format ask utf-8) write configuration files can rename my.ini or my.cnf. And then placed in this folder

my.ini reference configuration

[client]
#设置mysql客户端默认字符集
default-character-set=utf8 

[mysql]
# 设置mysql客户端默认字符集
default-character-set=utf8 

[mysqld]
#设置3306端口
port = 3306 
# 设置mysql的安装目录
basedir=E:\mysql-5.6.45-winx64 
# 设置mysql数据库的数据的存放目录
datadir=E:\mysql-5.6.45-winx64\data 
# 允许最大连接数
max_connections=200
# 服务端使用的字符集默认为8比特编码的latin1字符集
character-set-server=utf8
# 创建新表时将使用的默认存储引擎
default-storage-engine=INNODB

Environment variables
behind the PATH system variable to add: the path to your mysql bin folder (eg C: \ Program Files \ mysql- 5.6.41-winx64 \ bin)

Installing MySQL service
after an administrator, open cmd window, change the directory to the bin directory where you extracted the file, enter a carriage return run mysqld install

Start mysql service
as an administrator enter in cmd: net start mysql

After the service starts successfully, you can log in, and input mysql -u root -p (first log on without a password, press the Enter through direct)

Guess you like

Origin www.cnblogs.com/tutougold/p/11431032.html