If you choose mysql database as a data persistence tool, you need a reasonable log configuration, which will help you to troubleshoot and back up and recover data!First, we can use the following MySQL SQL to query the log configuration in
In this chapter, we will learn how to do user authorization and master-slave replication in MysqlHere's a look at the benefits of Mysql master-slave replication:1. If there is a problem with the primary server, you can quickly switch to the service
1, the role of MySQL cluster:- resolves a single point of failure for access nodes- single point of failure for data storage nodes- Troubleshoot data storage node data backup issues2. Cluster:Use a group of servers to provide the same service3,
Mysql master-slave and master-slave ReplicationMysql master-slave and master-slave ReplicationI. Introduction to replicationMySQL supports one-way and asynchronous replication. One server acts as the master server during the replication process, and
(1) ERRLOG contains information related to mysqd startup and shutdown, and any serious errors occurring on the server during running; you can use the-log-error [file_name] option to specify the location where mysqld saves the error log file. If the
Mysql data backup and recovery, mysql backup and recoveryBackup/recovery policies:1. Regular mysql backup and recovery time that the system can afford should be taken into consideration.2. Make sure that mysql opens log-bin. With binarylog, mysql
After the project is configured, Apache,mysql and so on will generate a log, in order to facilitate management, it is at a certain interval of time to dump1.Apache logAdd the following two sentences to the configuration file:Customlog
Restore the MySQL database tutorial log files
If the MySQL server has binary logs enabled, you can use the MySQL tutorial Binlog tool to recover data starting at a specified point in time (for example, from your last backup) until now or another
Mysqldump is often used in MySQL database logical backups.
1. Various usage instructions
A. The simplest use:
Mysqldump-uroot-ppassword [database name]
> [dump file]
The above command backs up the specified database to a dump file
MySQL uses binary logs to recover data two ways
If the MySQL server has binary logs enabled, you can use the MySQL tutorial Binlog tool to recover data starting at a specified point in time (for example, from your last backup) until now or another
When the development and production environment on the same machine, or need to deploy more than one set of test environment on a machine, often need to start multiple mysqld processes, and recently to help test the environment encountered this
If the MySQL server has binary logging enabled, you can use the Mysqlbinlog tool to recover data starting at a specified point in time (for example, from your last backup) until now or another specified point in time. "Mysqlbinlog: Utility for
If the MySQL server has binary logging enabled, you can use the Mysqlbinlog tool to recover data starting at a specified point in time (for example, from your last backup) until now or another specified point in time. "Mysqlbinlog: Utility for
1. Various usage instructions
A. The simplest use:
Copy Code code as follows:
Mysqldump-uroot-ppassword [Database name]
> [Dump file]
The above command backs up the specified database to a dump file (dump file), for
If the MySQL server has binary logging enabled, you can use the Mysqlbinlog tool to recover data starting at a specified point in time (for example, from your last backup) until now or another specified point in time. "Mysqlbinlog: Utility for
Backup/Restore Policy:1. Do a regular MySQL backup and consider the recovery time that the system can afford.2. Make sure that MySQL opens Log-bin, with Binarylog,mysql to do full recovery when necessary, or point-in-time recovery, or location-based
MySQL Data backup and recoveryBackup/Restore Policy:1. Do a regular MySQL backup and consider the recovery time that the system can afford.2. Make sure that MySQL opens Log-bin, with Binarylog,mysql to do full recovery when necessary, or
Original link: http://blog.csdn.net/xiaoxu0123/article/details/62585381. Set the directory to be stored:[Email protected] etc]# MORE/ETC/MY.CNF[Mysqld]# # #此处省略N个字Log-error=/var/log/mysql/mysql_error.log #错误日志Log=/var/log/mysql/mysql.log # # #最好注释掉,
But how do you find out which SQL statement is executing too long? Can be found through the MySQL slow log, detailed below.
First find MySQL configuration file my.cnf, according to different versions of MySQL open slow query configuration is not
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.