MySQL 5.7 Zip installation (win7), mysqlwin7
Refer to official documentation
Http://dev.mysql.com/doc/refman/5.7/en/windows-install-archive.html
2.3.5.1 Extracting the Install Archive
Http://dev.mysql.com/downloads/mysql/ download path
Decompress to a custom path such as D: \ Program Files \ mysql-5.7.12-winx64
2.3.5.2 Creating an Option File
Create a new data folder, path: D: \ Program Files \ mysql-5.7.12-winx64 \ data (if you do not want to use data but mydata see the official documentation)
D: \ Program Files \ new my. ini file under the mysql-5.7.12-winx64 directory (or directly modify the my-default.ini ):
[Mysqld]
Basedir = D: \ Program Files \ mysql-5.7.12-winx64
Datadir = D: \ Program Files \ mysql-5.7.12-winx64 \ data
Port = 3306
Configure in System Variables
MYSQL_HOME = D :\program Files \ mysql-5.7.12-winx64;
Path added % MYSQL_HOME % \ bin;
Run cmd as an administrator (Be sure to run it as an administrator, otherwise the permissions are insufficient ),
Enter cd C: \ Program Files \ MySQL Server 5.6 \ bin to enter the mysql bin folder (whether or not environment variables are configured, enter the bin folder, otherwise, an error will still be reported when the service is started. 2)
Enter mysqld-install (if you do not need to run it as an administrator, the following error will occur due to insufficient permissions: Install/Remove of the Service Denied !)
2.3.5.3 Selecting a MySQL Server Type
Skipped)
2.3.5.4 Initializing the Data Directory
On Windows, use one of these commands:
C: \>Bin \ mysqld -- initialize (generate a random password, save the random password and modify it by yourself)
C: \>Bin \ mysqld -- initialize-insecure (no password is generated)
First reference: http://www.cnblogs.com/leeyes999/p/5476504.html
This article mainly introduces the second
2.3.5.5 Starting the Server for the First Time
Mysqld -- console can print related console logs
Start database input net start mysql
Connect to the database:
If you used--initialize-insecure
To initialize the data directory, connect to the serverroot
Without a password:
mysql -u root --skip-password
After the connection, change the password:
Alter user 'root' @ 'localhost' identified'New_password (custom )'
;
2.3.5.6 Starting MySQL from the Windows Command Line
2.3.5.7 Customizing the PATH for MySQL Tools
2.3.5.8 Starting MySQL as a Windows Service
2.3.5.9 Testing The MySQL Installation