MySQL running condition Query Method

Source: Internet
Author: User

MySQL running STATUS query method: run show status directly in the command line to log on to MySQL and run show status. query statements, such as show variables in the same statement. show status is used to view the running STATUS of MySQL, it is similar to the above information viewed through pma. Show variablesshow variables is used to view MySQL configuration parameters. You can also use show variables like 'key % 'show processlistshow processlist to view ongoing processes, it is useful to troubleshoot situations such as locked tables. In general, enabling MySQL slow query records is also helpful for troubleshooting. Show open tablesshow open tables displays the list of opened TABLES. Mysqladmin status: Use the mysqladmin tool that comes with MySQL to view the status. Use the following command mysqladmin-uroot -- password = 'Password' status to display the following results: Uptime: 87117 Threads: 1 Questions: 5481626 Slow queries: 16 Opens: 2211 Flush tables: 1 Open tables: 512 Queries per second avg: 62.923 You can also add the-I 5 parameter so that it will be automatically refreshed every five seconds. Mysqladmin-uroot -- password = 'Password' status-I 5 mysqladmin extended-status Similarly, you can use mysqladmin-uroot -- password = 'Password' extended-status to view more MySQL operations information, this method is basically the same as that of the first method.

Related Article

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.