[MySQL Notes] SQL optimization tool-explain the output format of the explain command
If you have experience using MySQL, you may encounter slow SQL queries in your project. In some scenarios, you can easily locate the problem (for example, when a single table operation has slow SQL queries, check the SQL statement carefully and it is usually easy to locate the in
the xtraback_checkpoint file in the file added to the backup directory. The lsn is changed.Backup_type = incrementalfrom_lsn = 1291135to_lsn = 1352113
5. Restore Incremental Backup
5.1 restore preparationProcess: -- apply-log is applied to the full backup directory. The first step is to add backup, and the second step is to add backup ...... The N-step Incremental backup is equivalent to a new full backup + all incremental backups after all applications are completed.
Innobackupex -- apply-log
Mysql performance debugging tool profile, mysqlprofile
I have been looking for mysql tools similar to Oracle 10046. I can see the time consumption of SQL Execution. I finally found a profile on the Internet. I think it is good to use it.
Mysql> select version ();+ ----------- +| Version () |+ ----------- +| 5.6.16 |+ -
mysql-5.6.36-linux-glibc2.5-x86_64.tar.gz-c/usr/localCd/usr/localLN-SV mysql-5.6.36-linux-glibc2.5-x86_64 MySQLCD MySQLChown-r root.mysql./*Mkdir/app/data/mydata-pChown-r Mysql.mysql/app/data/mydataMkdir/app/data/binlogsChown-r Mysql.mysql/app/data/binlogsCd/usr/local/mysqlscripts/mysql_install_db--datadir=/app/data/mydata--user=mysqlCopy the service script to the startup itemCP Support-files/mysql.server/
MySQL as a database, is simply a synonym for ease of use, the vast majority of database-driven Web applications choose it as their own database. For this reason, MySQL is used on many Web servers. While it's true that MySQL's command-line tools are useful, it's sometimes hard to get the job done, unless you're ripe for the perfect SQL syntax. It is for this reason that tools such as phpMyAdmin have become s
MySQL database management tool navicat for MySQL, not much like the graphical interface or inconvenient to use SQL. We can use this graphical interface database management tool to manage MySQL, this experience Nithya to briefly explain how to use navicat for
Interface Tools:Msql Workbench http://www.mysql.com/products/workbench sqlyog http://www.webyog.com phpMyAdmin http://sourcefor Ge.net/projects/phpmyadmin [Not recommended] adminer phpMyAdmin better alternatives, http://www.adminer.org[not recommended for public access]command-line toolset:Percona toolkit:mysql Administrator-required toolkit. Includes many tools for similar log analysis, replication integrity detection, data synchronization, schema and index distractions, query sugges
class= "Sh_usertype" >mv phpmyadmin-4.1.2 - all- languages / var/ www/ html/ PMA
[Email protected] ~]# unzip phpmyadmin-4.1.2-all-languages.zip
[[email protected] ~]# MV Phpmyadmin-4.1.2-all-languages/var/www/html/pmaSwitch to the post-deployment PMA program directory, copy the configuration file, and modify the configuration to correctly specify the IP address of the MySQL server.Copytextpop-up
[[email protected] ~]# cd /var/www/htm
Background of the "MySQL" "High Availability" purge_relay_logs tool:? In the MHA high-availability architecture to switch the steps, mainly by the individual instances of the relay log file compared to the old and new, select the latest relay log for the data in the group to append, as far as possible to ensure the security of the data, reduce the number of data loss. This requires relay log can not be auto
First install LNMP environment, require PHP-5.3 or above. Reference: isadba.com? P82 or refer to isadba.com? P572 and then download Anemometergitclonegithub. combox
First install LNMP environment, require PHP-5.3 and above versions. Reference: http://isadba.com /? P = 82 or reference http://isadba.com /? P = 572 and then download Anemometer git clonehttps: // github.com/box
First install LNMP environment, require PHP-5.3 version or above.Reference :? P = 82 or reference? P = 572
Then down
MySQL management tool --- PerconaToolkit bitsCN.com
MySQL management tool --- Percona Toolkit
Percona Toolkit is a group of advanced command line tools used to manage MySQL and system tasks, including:
1. verify the consistency between the master node and the copied data.
MySQL can certainly use its own dual-machine hot backup, but only one server can use dual-machine hot backup. Here we will talk about the hot backup tool xtrabackup
Xtrabackup-1.5http: // download.csdn.net/detail/zzaihl/4104181
Xtrabackup is an open-source project of percona that supports hot backup of InnoDB, xtradb, and MyISAM(Locks the table)
Official Website http://www.percona.com/docs/wiki/percon
The hive Tool that reads and computes data from any hive single table and writes data to any mysql Single table. In the hive-based data warehouse, each dimension has many hierarchical concepts, it is important to configure and Display dimensions and metrics online and offline in mysql. This hive Tool is suitable for an
provides the profiling tool for viewing resource consumption during statement queries. First we use the following command to turn on the profiling feature:Set profiling = 1; Next we execute a query command:Mysql> SELECT * from emp where empno=413345;+--------+--------+----------+-----+------------+---------+--------+- -------+| empno | ename | job | mgr | hiredate | sal | comm | deptno |+--------+--------+----------+----- +-----------
Mydumper is a multi-threaded export and import tool written in C language, and can ensure consistency between multiple tables. Of course, the more threads, the better (this configuration with the server, etc.
Mydumper is a multi-threaded export and import tool written in C language, and can ensure consistency between multiple tables. Of course, the more threads, the better (this configuration with the serve
,-x N: The number of columns in the test table that are automatically generated. The default value is 1.-- Number-int-cols = N,-y N: the number of columns in the automatically generated test table. The default value is 1.-- Number-of-queries = N total number of test queries (number of concurrent customers × number of queries per customer)-- Query = name,-q: Use a custom script to execute the test. For example, you can call a custom stored procedure or SQL statement to execute the test.-- Create-
test data, the recommended benchmark value is set above 100, and in my test environment, it is generally set to 1000.Since the TPCH Initialization Library table script in the source package does not fully apply to MySQL, some code needs to be modified.Mr. Cheng Test SQL script:[[email protected] tpch]#./qgen | Sed-e ' s/\r//' > Queries/tpch_queries.sqlThen use VIM to open the Tpch_queries.sql script and ma
--ssl-crl=file_name--ssl-crlpath=dir_name--ssl-key=file_ Name--ssl-verify-server-cert--user=user_name-u Database user name--verbose-vOutput more information--version-v version information Cases1. Test 100, 200, 400 concurrent execution 10w SQL respectively.mysqlslap-uroot-proot-h192.168.10.43-p3306--create-schema=chenmh--delimiter= ";"--query= "Call Pro_auto_select_ pri Note: The time of the report output is mainly reflected in the time spent executing the query sp
Tags: Windows connect mysqlConnect MySQL tool under Windows navicatformysqlFirst, the introduction of softwareNavicat for MySQL is a powerful MySQL database management and development tool that provides professional developers with a powerful and sophisticated set of tools,
multiple states
# mysqladmin status --sleep 3 --count 5
5) Extended-status: Display state variables
# mysqladmin extended-status | less
6) Variables: Display server variables
# mysqladmin variables | less
7)flush-privileges: Let mysqld reread authorization form, equivalent to reload;
# mysqladmin flush-privileges
8)flush-status, reset most of the server state variables, set some variables to 09) Flush-logs: binary and Trunk log
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.