I have contributed a script to monitor the MYSQL process. I hope it will be helpful to you.
Function:
Monitors the MYSQL process and restarts upon failure. If the MYSQL process fails to be started, an Email notification is sent.
The Code is as
WIN10 installing the MySQL process && linking process && backing up and importing data &&grant commandsFirst, installationThe latest version 8.0 downloaded at the beginning of the MySQL official website (https://www.mysql.com/downloads/ ), causing
In earlier versions, it is much easier to adjust the Innodb_Buffer_Pool_size to take effect only after the mysql process is restarted. Application scenarios of this function: 1. Increase the memory on the machine. The DBA is careless and forgets to
In earlier versions, it is much easier to adjust the Innodb_Buffer_Pool_size to take effect only after the mysql process is restarted. Application scenarios of this function: 1. Machines
In earlier versions, it is much easier to adjust the
In php, how does one use mysqli connection to obtain the mysql process List, which is similar to showprocesslist? Php version: 5.2.17 & nbsp; mysql version: 5.0.14 uses the connection method of mysqli. to obtain the list of current database
MySQL5.7 online Innodb_Buffer_Pool_size adjustment without restarting the mysql process
In earlier versions, it is much easier to adjust the Innodb_Buffer_Pool_size to take effect only after the mysql process is restarted.
Application scenarios of
1) Process Connection2) interaction3) variables"Process Connection"Mysql> show Processlist; #查看MySQL当前所有进程连接Interactionmysql> system Ls/tmp #MySQL交互下查看tmp目录下内容VariableMysql> Show variables; #查看变量Mysql> Show status; #查看状态Mysql> show global Stat;
Make a note for the convenience of inspection.View the status of the MySQL process through show processlist, which has the following status on the State column:AnalyzingThe thread makes an analysis of the statistics of the MyISAM table (for example,
In php, how does one use mysqli connection to obtain the mysql process List, which is similar to showprocesslist? Php version: 5.2.17 & nbsp; mysql version: 5.0.14 uses the connection method of mysqli. to obtain the list of current database
1. MySQL Process Control Statement
The IF, case, loop, leave, iterate, repeat, and while statements can be used in MySQL for process control.
1.1 If statement
The IF implementation condition is judged to satisfy different
In the previous version, adjust the innodb_buffer_pool_size size must restart the MySQL process to take effect, now in the MySQL5.7, can be directly dynamic settings, convenient a lot.This feature applies to the scenario:First, the machine increased
View the mysql process -- show processlist: Use show processlist to view the current running status. Mysql> show processlist; www.2cto.com, displays the IP address and port number from which the current process is sent. The db column shows which
How does MySQL process the unique primary key duplicate value during the insertion process? mysql primary keyIntroduction
This article describes how to avoid DUPLICATE keys when inserting data into a table. It mainly involves IGNORE, on duplicate
Linux batch kill mysql process, linux batch killmysql
It is often the case that a process needs to be forcibly killed, but if the process starts many sub-processes, it must kill all the processes that come out of ps aux, if one kill is
Under Windows, Apache and MySQL have automated installation programs, and this article focuses on choosing from Apache and PHP versions, PHP thread safety, Apache and MySQL installation startup services, Work environment configuration in these
Function:
Monitor the MySQL process, the failure is restarted, if unable to start the email notification
The code is as follows:
The code is as follows
Copy Code
#!/bin/bash#/usr/bin/nmap localhost | grep 3306#lsof-i:33
Installation stepsBefore installing, we can detect whether the system comes with MySQL installed:rpm -qa | grep mysqlIf you have a system installed, you can choose to uninstall:rpm -e mysql // 普通删除模式rpm -e --nodeps mysql Installation wget https:/
Recently the program is running for a few days, suddenly can't access, check the application process is still there. Only the database process is down. Then find the log file to see the following error .- -- - on: -: - 19934[Note]
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.