MySQL5.7 single instance self-starting service configuration process

MySQL5.7 single instance self-starting service configuration process

1.MySQL version

[root@clq system]# mysql -v
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 49
Server version: 5.7.33 MySQL Community Server (GPL)

2. Configure the mysqld.service file

[Unit]
Description=mysql server daemon
After=network.target mysql-keygen.target
[Service]
Type=forking
ExecStart=/usr/local/mysql/support-files/mysql.server start
ExecStop=/usr/local/mysql/support-files/mysql.server stop
ExecReload=/bin/kill -HUP $MAINPID
[Install]
WantedBy=multi-user.target
[Install]
WantedBy=multi-user.target

3. Where the mysqld.service file is placed

/usr/lib/systemd/system/mysqld.service

4. Self-start

 systemctl daemon-reload 
systemctl enable --now mysqld
[root@mysql ~]# ss -antl
State Recv-Q Send-Q Local Address:Port Peer Address:Port Process        
LISTEN 0 128 0.0.0.0:111 0.0.0.0:*                          
LISTEN 0 32 192.168.122.1:53 0.0.0.0:*                          
LISTEN 0 128 0.0.0.0:22 0.0.0.0:*                          
LISTEN 0 5 127.0.0.1:631 0.0.0.0:*                          
LISTEN 0 128 [::]:111 [::]:*                          
LISTEN 0 128 [::]:22 [::]:*                          
LISTEN 0 5 [::1]:631 [::]:*                          
LISTEN 0 80 *:3306 *:*  

The above is the detailed content of the MySQL 5.7 single instance self-starting service configuration process. For more information about the MySQL 5.7 single instance self-starting service configuration, please pay attention to other related articles on 123WORDPRESS.COM!

You may also be interested in:
  • Detailed explanation of the installation, configuration, startup and shutdown methods of the Mysql server
  • MySQL multi-instance installation boot auto-start service configuration process
  • MySQL configuration master-slave server (one master and multiple slaves)
  • MySQL in Windows net start mysql Start MySQL service error occurs System error solution
  • 5 MySQL GUI tools recommended to help you with database management
  • 19 MySQL optimization methods in database management
  • Detailed introduction to 5 commonly used MySQL database management tools
  • Summary of Common Commands for MySQL Database Management
  • MySQL service and database management

<<:  Detailed explanation of JavaScript BOM composition and common events

>>:  How to use docker compose to build fastDFS file server

Recommend

Not a Chinese specialty: Web development under cultural differences

Web design and development is hard work, so don&#...

Detailed explanation of 6 ways of js inheritance

Prototype chain inheritance Prototype inheritance...

JavaScript to achieve the effect of clicking on the submenu

This article shares the specific code of JavaScri...

Detailed explanation of how to use the mysql backup script mysqldump

This article shares the MySQL backup script for y...

A brief discussion on how to choose and combine div and table

Page layout has always been my concern since I st...

Two ways to visualize ClickHouse data using Apache Superset

Apache Superset is a powerful BI tool that provid...

Example of using store in vue3 to record scroll position

Table of contents Overall Effect Listen for conta...

XHTML 1.0 Reference

Arrange by functionNN : Indicates which earlier ve...

JS implements Baidu search box

This article example shares the specific code of ...

How to use HTML+CSS to create TG-vision homepage

This time we use HTML+CSS layout to make a prelim...

Zabbix monitoring docker application configuration

The application of containers is becoming more an...

Detailed process of upgrading gcc (version 10.2.0) under CentOS7 environment

Table of contents Short Introduction 1. Check the...