Get the App
SLTechnology News&Howtos  ›  Database  › 

How to install mysql5.7.24 unzipped version

Shulou Source: shulou.com Published: 2022-05-31 20:34:08 10月05日 Update

This article is about how to install the unzipped version of mysql5.7.24. The editor thinks it is very practical, so share it with you as a reference and follow the editor to have a look.

1. Download

Https://dev.mysql.com/downloads/mysql/

2. Extract to a fixed location, such as D:\ MySQL\ mysql-5.7.24

3. Add my.ini file

At the same level as bin

[mysql]

Set the mysql client default character set

Default-character-set=utf8 [mysqld]

Set port 3306

Port = 3306

Set the installation directory for mysql

Basedir=D:\ MySQL\ mysql-5.7.24

Set the directory where the data in the mysql database is stored

Datadir=D:\ MySQL\ mysql-5.7.24\ data

Maximum number of connections allowed

Max_connections=200

The character set used by the server defaults to the 8-bit coded latin1 character set

Character-set-server=utf8

The default storage engine that will be used when creating new tables

Default-storage-engine=INNODBmax_connect_errors=100 explicit_defaults_for_timestamp=true

4. Initialize

Mysqld-- install mysql--defaults-file=D:\ MySQL\ mysql-5.7.24\ my.ini

5. Install the service

Mysqld-install mysql

6. Start

Net start mysql

Complete

Problems encountered

1. The MySQL service on the local computer starts and stops. Some services stop automatically when they are not used by other services or programs

Or the console reported an error.

The mysql service could not be started

The service did not report any errors

You can reinitialize, restart, and empty the data folder (at the same level as bin) before initialization.

You can also delete services and re-register

Mysqld-remove mysql

2. Re-registration will find that there may be other errors such as: TIMESTAMP with implicit DEFAULT value is deprecated

Solution:

Add a line of explicit_defaults_for_timestamp=true under [mysqld] in the my.ini file. That's it.

The meaning of this statement is # to turn on query caching, which is also one of the web caches, which can only be read in the cache for duplicate queries, reducing access to the database.

3. Log in and change your password according to what is said on the Internet:

Mysqladmin-uroot-p password new password

If you find out, you will report an error.

Mysql Access denied for user root@localhost error

Skip password login and change table user

Update user set password=password ("new password") where user= "root"; password column name may also be authentication_string

Then refresh the flush privileges

4. The method of skipping password login

In the MySQL configuration file my.ini, add skip-grant-tables under [mysqld], shut down the MySQL service and restart it.

Enter the command: mysql-u root-p

Enter after entering the password, enter directly to skip, then directly enter the MySQL.

Once this is set, you can directly double-click mysql.exe under D:\ MySQL5.7.10\ bin to start without entering a command.

Thank you for reading! This is the end of the article on "how to install the unzipped version of mysql5.7.24". I hope the above content can be of some help to you, so that you can learn more knowledge. if you think the article is good, you can share it for more people to see!

Tags: Services passwords files characters character sets data caches errors logins inputs content siblings commands databases methods more directories articles new secrets queries Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Linux Apple macOS Redmi OPPO Reno