Mysql Free installation version

Source: Internet
Author: User
Tags mysql free

Read Catalogue

    • Download MySQL free install version
    • Configuring the MySQL Database
    • MySQL Environment variables
    • Installing the MySQL Database

The company server is a Windows development connected database that uses "MySQL"

This essay will show you how to configure the MySQL database free install version on Windows

download mysql free install version
    • First go to MySQL official website www.mysql.com-->downloads (download)--Community (community)--MySQL Community server (MySQL Community server)-- Select Operating system platform (Windows)
    • There are three optional download files below

† The first one is MySQL Installer 5.6 for Windows, download Down is an. msi executable installation file

† The following two are unpacked (Zip version), respectively Windows (x86, 64-bit), Zip Archive and Windows (x86, 32-bit), Zip Archive

    • The author chooses Mysql-5.6.26-winx64.zip, because the author's server version is 64-bit operating system
Configuring the MySQL database
    • Unzip the downloaded Mysql-5.6.26-winx64.zip to the custom directory, where the author will unzip the package to the D:\mysql-5_x64 directory
    • Open this directory, found inside the folder and file with a installed MySQL basically no difference, but this MySQL5.6.26 incredibly has 1 multi-g size, a closer look will find that there is a debug file, the suffix of. Lib or. pdb, in fact, can be deleted! There are also some directories called Debug, can also be deleted, so since the mysql-5_x64 capacity is much smaller
    • Modify the MySQL configuration file, in the mysql-5_x64 directory has a my-default.ini, can be counted as a template to use, the content is not many! You can create your own my.ini as a MySQL profile, open My.ini

[Client]

port=3306

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

Default-character-set=utf8

[Mysqld]
#绑定IPv4和3306端口
Bind-address = 0.0.0.0
Port = 3306

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

Character_set_server=utf8

# set up the MySQL installation directory

Basedir=d:/mysql-5_x64
# Set up a storage directory for MySQL database data
Datadir=d:/mysql-5_x64/data
# Maximum number of connections allowed
max_connections=201

    • The parameters required for such a basic MySQL environment are sufficient.
MySQL Environment variables
    • Right-click on this computer--properties--advanced--environment variables--"User variables" new variable mysql_home value D:\mysql-5_x64, "system variable" to find the variable path edit in the back add;%mysql_home%\ Bin
installing the MySQL database
    • Run cmd (Win8, Win10 with admin allow cmd) and go to D:\mysql-5_x64\bin directory
Microsoft Windows [version 10.0.10240] (c) is Microsoft Corporation. All rights reserved. C:\WINDOWS\SYSTEM32>D:D:\>CD MYSQL-5_X64D:\MYSQL-5_X64>CD bind:\mysql-5_x64\bin>
    • Perform mysqld-install install MySQL
D:\mysql-5_x64\bin>mysqld-installservice successfully installed
    • Execute net start MySQL startup MySQL
D:\mysql-5_x64\bin>net start mysqld:\mysql-5_x64\bin>net Start Mysqlmysql service is starting. MySQL Service has started successfully

Start MySQL service: net start MySQL

Stop MySQL service: net stop MySQL

Move out of MySQL service: mysqld-remove

    • Modify MySQL Password
D:\mysql-5_x64\bin>mysql-u root-p                              //Use root login mysqlenter password:                                         //Password empty, enter can welcome to the MySQL Monit Or.  Commands End With; or \g.your MySQL connection ID is 2Server version:5.6.26 mysql Community Server (GPL) Copyright (c), Oracle and /or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or itsaffiliates. Other names trademarks of their respectiveowners. Type ' help ', ' or ' \h ' for help. Type ' \c ' to clear the current input statement.mysql>
mysql> show databases;                  Show all Databases +--------------------+| Database           |+--------------------+| information_schema | | mysql              | | performance_schema | | Test               |+---------- ----------+4 rows in Set (0.00 sec)
    • Enter ' MySQL ' data, delete empty user
mysql> use mysql;database changedmysql> Delete from user where user= '; Query OK, 1 row Affected (0.00 sec)
    • Update the password and re-swipe the permissions table to memory (you can also use the Mysqladmin tool to set the password)
mysql> Update User Set Password=password (' 123456 ') where user= ' root '; Query OK, 4 rows Affected (0.00 sec) rows Matched:4  changed:4  warnings:0mysql> flush privileges; Query OK, 0 rows Affected (0.00 sec)
    • Try to login
D:\mysql-5_x64\bin>mysql-u root-p                   //log in to the database with root enter password: ******                                       //Enter the updated password 123456Welcome to the MySQL Monitor.  Commands End With; or \g.your MySQL connection ID is 5Server version:5.6.26 mysql Community Server (GPL) Copyright (c), Oracle and /or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or itsaffiliates. Other names trademarks of their respectiveowners. Type ' help ', ' or ' \h ' for help. Type ' \c ' to clear the current input statement.mysql>
    • Turn on remote connections (give full permission to allow 192.168.1.x network segments to connect)
Mysql> Grant all privileges on * * to ' root ' @ ' 192.168.1.% ' identified by ' root ' with GRANT option; Query OK, 0 rows Affected (0.00 sec) mysql> flush privileges; Query OK, 0 rows Affected (0.00 sec) mysql> Select Host,user,password from user;+-------------+------+---------------- ---------------------------+| Host        | user | password                                  |+-------------+------+-------------------------------------------+| 192.168.1.% | Root | *81F5E21E35407D884A6CD4A731AEBFB6AF209E1B |+-------------+------+-------------------------------------------+4 Rows in Set (0.00 sec)

Okay, you're done, Mysql free install is already installed.

Mysql Free installation version

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.