Installation of Mysql Green Edition of Ape Circle Mysql

Keywords: Programming MySQL Database Windows

Back-end personnel will use the database, most people like to use mysql, because MySQL is open source, then how to install mysql? If you do not pay attention to unsuccessful installation, it is likely to lead to deletion is not clean and it is difficult to install successfully again, this article Circle of apes plus plus Introduce in detail the installation process of mysql. Let's take a look at it.

1. Download MySQL 8.0.16, Address: Official Download

2. Unzip to your own disk

3. Configure Path Path Path Path Path: System Attributes=> Advanced=> Advanced=> System Variables=> Add after Path (e.g. D: Tools mysql-8.0.16-winx64 bin)

4. Create my.ini in the mysql root directory. This file is initialization information (the default mysql root directory does not contain this file):

# For advice on how to change settings please see

# http://dev.mysql.com/doc/refman/5.7/en/server-configuration-defaults.html

# *** DO NOT EDIT THIS FILE. It's a template which will be copied to the

# *** default location during install, and will be replaced if you

# *** upgrade to a newer version of MySQL.

[mysqld]

# Remove leading # and set to the amount of RAM for the most important data

# cache in MySQL. Start at 70% of total RAM for dedicated server, else 10%.

# innodb_buffer_pool_size = 128M

# Remove leading # to turn on a very important data integrity option: logging

# changes to the binary log between backups.

# log_bin

# These are commonly set, remove the # and set as required.

basedir = D:\Tools\mysql-8.0.16-winx64

datadir = D:\Tools\mysql-8.0.16-winx64\data

port = 3306

# server_id = .....

# Remove leading # to set options mainly useful for reporting servers.

# The server defaults are faster for transactions and fast SELECTs.

# Adjust sizes as needed, experiment to find the optimal values.

# join_buffer_size = 128M

# sort_buffer_size = 2M

# read_rnd_buffer_size = 2M

sql_mode=NO_ENGINE_SUBSTITUTION,STRICT_TRANS_TABLES

5. Run cmd in system administrator mode and enter the following commands

C:\WINDOWS\system32>d:  //Enter d disk

D:\>cd "Tools\mysql-8.0.16-winx64\bin" //Enter the mysql bin file

D:\Tools\mysql-8.0.16-winx64\bin>mysqld --install //Execute the installation mysql service process

Service successfully installed.  //Successful installation of prompt service

D:\Tools\mysql-8.0.16-winx64\bin>mysqld --initialize --console //Initialize mysql according to the configuration file. Note that there is a temporary password in the output log. C_:qVsvG6Hxa is the temporary password for login.

A temporary password is generated for root@localhost: C_:qVsvG6Hxa

D:\Tools\mysql-8.0.16-winx64\bin>net start mysql  //service mysql start

D:\Tools\mysql-8.0.16-winx64\bin>mysql -uroot -p  //Log on to mysql

Enter password:                      //Enter the temporary password above.

mysql> alter user root@localhost identified by '123456'; //Modify the password, 123456 is the current password for root account login

mysql> flush privileges; // Refresh the system table and apply the new password modified above

Installation is done everywhere!

As long as you follow the above steps, it will not generally lead to the failure of MySQL installation, we must step by step, so as to prevent the unsuccessful installation of mysql, which will be very troublesome later, this article is over, I hope that the friends who see this article can successfully install, after the installation, we can pass the life. To add, delete, modify and check the database. Next article Circle of apes plus plus Can write in detail, you can go first. Ape Circle Preview Let's see you next.

Posted by superjoe30 on Sun, 21 Jul 2019 23:50:52 -0700