Solution to the problem of installing MySQL compressed version zip

Solution to the problem of installing MySQL compressed version zip

There was a problem when installing the compressed version of MySQL today. The service could not be started and I struggled for two or three hours. Later, I couldn't figure it out, so I just deleted the registry entries.

If you have installed mysql before, delete mysql: E:\work\mysql-5.7.23-winx64\bin>sc delete mysql

To delete the registry, refer to this blogger: https://www.jb51.net/article/157590.htm

Because I used a compressed version of MySQL before, there may be some legacy.

Of course you need to download: mysql-5.7.23-winx64.zip

After decompression, you need to add the my.ini file. Note: the data file also needs to be added by yourself

My my.ini file says

[mysql]

# Set the default character set of the mysql client to default-character-set=utf8

[mysqld]
sql_mode="ONLY_FULL_GROUP_BY,STRICT_TRANS_TABLES,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION"

 

#Set port 3306 port = 3306

# Set the installation directory of mysql to basedir=E:\work\mysql-5.7.23-winx64

# Set the storage directory of mysql database data datadir=E:\work\mysql-5.7.23-winx64\data


# The default character set used by the server is the 8-bit latin1 character set character-set-server=utf8

# The default storage engine that will be used when creating a new table default-storage-engine=INNODB


#The maximum number of connections to be processed at the same time is recommended to be set to about 80% of the upper limit max_connections = 200

#Log buffer size. Since the log is refreshed once a second at most, it usually does not need to exceed 16M.
innodb_log_buffer_size = 8M

event_scheduler = ON

explicit_defaults_for_timestamp=true

You can find the specific explanation on Baidu.

Preparation is complete. . . .

First, add the mysql bin directory to the system environment variable path. Note that there is a ; sign at the end. For example, mine

Then enter the mysql bin directory as an administrator, for example: E:\work\mysql-5.7.23-winx64\bin>

Then install mysql:

After the installation is complete, type: mysqld --initialize-insecure --user=mysql, the password is empty

start up

Of course, if you want to set a password, you can do so

Note: The -proot in mysql -u root -proot must not have spaces. Then use Navicat, the MySQL client, to log in directly.

Solving problems = attitude (cherish, selflessness (can’t find me), empty boat) + attribution (not all problems need to be solved, not all problems need to be solved now, not all problems need to be solved by oneself) + solution method (pyramid principle (background, conclusion, elaboration of supporting opinions, binary tree for opinions (background, conclusion, opinions…)) + system cycle method)

You may also be interested in:
  • Can't connect to local MySQL through socket ''/tmp/mysql.sock'' solution
  • A complete list of commonly used MySQL functions (classified and summarized)
  • Use MySQL master-slave configuration to achieve read-write separation and reduce database pressure
  • mysql+spring+mybatis to realize code configuration of database read-write separation
  • How to completely delete the MySQL service (clean the registry)
  • How to operate MySQL in Golang
  • Example of MySQL database operation encapsulated by Yaf framework
  • Several ways to store images in MySQL database
  • How to store text and pictures in MySQL
  • mysql code to implement sequence function

<<:  Detailed steps for implementing timeout status monitoring in Apache FlinkCEP

>>:  Summary of two methods to implement vue printing function

Recommend

Detailed explanation of the usage of setUp and reactive functions in vue3

1. When to execute setUp We all know that vue3 ca...

MySQL 5.7 installation and configuration tutorial

This article shares the MySQL installation and co...

Summary of pitfalls in virtualbox centos7 nat+host-only networking

Table of contents 1. Problem Background 2. What a...

Windows Server 2016 Quick Start Guide to Deploy Remote Desktop Services

Now 2016 server supports multi-site https service...

MySQL 5.7.17 installation and use graphic tutorial

MySQL is a relational database management system ...

Vue and react in detail

Table of contents 1. Panorama II. Background 1. R...

W3C Tutorial (6): W3C CSS Activities

A style sheet describes how a document should be ...

HTML hyperlinks explained in detail

Hyperlink Hyperlinks are the most frequently used ...

Detailed tutorial on how to delete Linux users using userdel command

What is serdel userdel is a low-level tool for de...

Vue+Element realizes paging effect

This article example shares the specific code of ...

Cleverly use CSS3's webkit-box-reflect to achieve various dynamic effects

In an article a long time ago, I talked about the...

Detailed example of MySQL joint table update data

1.MySQL UPDATE JOIN syntax In MySQL, you can use ...

Website front-end performance optimization: JavaScript and CSS

I have read an article written by the Yahoo team ...

Solution to Ubuntu not being able to connect to the Internet

Problem description: I used a desktop computer an...