github : https://github.com/major/MySQLTuner-perl

MySQLTuner是一个用Perl编写的脚本,它可以帮助您进行MySQL配置,并提出增强性能和稳定性的建议。

installl:

1,cd /usr/local/bin && curl -O https://raw.githubusercontent.com/major/MySQLTuner-perl/master/mysqltuner.pl

2,chmod +x ./mysqltuner.pl && ./mysqltuner.pl --version && alias mysqltuner='perl /usr/local/bin/mysqltuner.pl' ;

3-

help:

Usage:

Name:
MySQLTuner 1.7.15 - MySQL High Performance Tuning Script

Important Usage Guidelines:
To run the script with the default options, run the script without
arguments Allow MySQL server to run for at least 24-48 hours before
trusting suggestions Some routines may require root level privileges
(script will provide warnings) You must provide the remote server's
total memory when connecting to other servers

Connection and Authentication: 连接和验证
--host <hostname> Connect to a remote host to perform tests (default: localhost)
--socket <socket> Use a different socket for a local connection
--port <port> Port to use for connection (default: 3306)
--user <username> Username to use for authentication
--userenv <envvar> Name of env variable which contains username to use for authentication
--pass <password> Password to use for authentication
--passenv <envvar> Name of env variable which contains password to use for authentication
--ssl-ca <path> Path to public key
--mysqladmin <path> Path to a custom mysqladmin executable
--mysqlcmd <path> Path to a custom mysql executable
--defaults-file <path> Path to a custom .my.cnf

Performance and Reporting Options:   绩效和报告选项
--skipsize Don't enumerate tables and their types/sizes (default: on)
(Recommended for servers with many tables)
--skippassword Don't perform checks on user passwords(default: off)
--checkversion Check for updates to MySQLTuner (default: don't check)
--updateversion Check for updates to MySQLTuner and update when newer version is available (default: don't check)
--forcemem <size> Amount of RAM installed in megabytes
--forceswap <size> Amount of swap memory configured in megabytes
--passwordfile <path> Path to a password file list(one password by line)

Output Options: 输出选项
--silent Don't output anything on screen
--nogood Remove OK responses
--nobad Remove negative/suggestion responses
--noinfo Remove informational responses
--debug Print debug information
--noprocess Consider no other process is running
--dbstat Print database information
--nodbstat Don't Print database information
--tbstat Print table information
--notbstat Don't Print table information
--idxstat Print index information
--noidxstat Don't Print index information
--sysstat Print system information
--nosysstat Don't Print system information
--pfstat Print Performance schema
--nopfstat Don't Print Performance schema
--verbose Prints out all options (default: no verbose, dbstat, idxstat, sysstat, tbstat, pfstat)
--bannedports Ports banned separated by comma(,)
--maxportallowed Number of ports opened allowed on this hosts
--cvefile <path> CVE File for vulnerability checks
--nocolor Don't print output in color
--json Print result as JSON string
--buffers Print global and per-thread buffer values
--outputfile <path> Path to a output txt file
--reportfile <path> Path to a report txt file
--template <path> Path to a template file

  • Log file Recommendations 日志文件建议 -----
  • Storage Engine Statistics 存储引擎统计-----
  • Analysis Performance Metrics 分析性能指标 -----
  • Security Recommendations 安全建议-----
  • CVE Security Recommendations CVE安全建议-----
  • Performance schema 性能架构-----
  • ThreadPool Metrics 线程池度量标准-----
  • MyISAM Metrics-----
  • AriaDB Metrics -----
  • TokuDB Metrics-----
  • XtraDB Metrics -----
  • Galera Metrics -----
  • Replication Metrics 复制指标------
  • Recommendations 建议------

-

使用 mysqltuner 检测 mysql 稳定性的更多相关文章

  1. 写一个简单脚本检测mysql主从是否正常

    这个脚本是在从服务器上执行的 [root@bogon ~]# cat a.sh #!/bin/bash #下面这行目的在于检测mysql端口是否开启,如果没有开启,那说明mysql服务都没有开启,直接 ...

  2. 脚本_检测mysql存活状态

    #!bin/bash#功能:检测mysql服务是否存活#作者:liusingbon# host为你需要检测的mysql主机的IP 地址,user为mysql账户名,passwd为密码; 这些信息需要根 ...

  3. 脚本_检测 MySQL 数据库连接数量

    #!bin/bash#功能:检测 MySQL数据库连接数量,以满足对 MySQL 数据库的监控需求,查看 MySQL 连接是否正常.#作者:liusingbon#本脚本每 2 秒检测一次 MySQL ...

  4. 检测 MySQL 服务是否存活 shell脚本

    #!/bin/bash # 检测 MySQL 服务是否存活 # host 为你需要检测的 MySQL 主机的 IP 地址,user 为 MySQL 账户名,passwd 为密码 # 这些信息需要根据实 ...

  5. 借助 MySQLTuner 优化 MySQL 性能(转载的一篇文章)

    MySQLTuner 是一个 Perl 脚本,可以用来分析您的 MySQL 性能,并且基于收集到的信息给出相应的优化建议.这样子,您就可以调整 my.cnf 从而优化您的 MySQL 设置. 这边只是 ...

  6. 开发检测MySQL主从同步插件

    Nagios的状态码 OK 退出码0,表示正常工作 WARNING  退出码1,表示处于警告阶段 CRITICAL    退出码2,表示处于紧急状态,严重状态 UNKOEN   退出码3,表示无法获取 ...

  7. Zabbix检测Mysql数据库的主从同步

    在高并发网站架构中,MySQL数据库主从同步是不可或缺的,不过经常会发生由于网络原因或者操作错误,MySQL主从经常会出现不同步的情况,那么如何监控MySQL主从同步,也变成检测网站正常运行的重要环节 ...

  8. [zabbix] zabbix检测mysql主从状态

    环境说明: zabbix-proxy 172.16.2.95(zabbix-server同理) zabbix-agent111 172.16.2.111 mysql从机 1.mysql从机添加用户权限 ...

  9. 031_检测 MySQL 服务是否存活

    #!/bin/bash#host 为你需要检测的 MySQL 主机的 IP 地址,user 为 MySQL 账户名,passwd 为密码#这些信息需要根据实际情况修改后方可使用 host=127.0. ...

随机推荐

  1. MySQL 笔记整理(11) --怎么给字符串字段加索引?

    笔记记录自林晓斌(丁奇)老师的<MySQL实战45讲> (本篇内图片均来自丁奇老师的讲解,如有侵权,请联系我删除) 11) --怎么给字符串字段加索引? 日常工作中的登录系统,你很可能会使 ...

  2. 物联网RFID技术之应用ETC系统

    背景 信息物理系统CPS通过集成先进的感知.计算.通 信.控制等信息技术和自动控制技术,构建了物理空间与信息空间中人. 机.物.环境.信息等要素相互映射.适时交互.高效协同的复杂系统, 实现系统内资源 ...

  3. Django之CSRF跨站请求伪造(老掉牙的钓鱼网站模拟)

    首先这是一个测试的代码 请先在setting页面进行下面操作 注释完成后,开始模拟钓鱼网站的跨站请求伪造操作: 前端代码: <!DOCTYPE html> <html lang=&q ...

  4. React-Native学习手册----搭建基于ios平台的开发环境

    首先推荐几个链接: React-Native 官网地址:https://facebook.github.io/react-native/docs/getting-started React-Nativ ...

  5. 瓦片切图工具gdal2tiles.py改写为纯c++版本

    gdal2tiles.py是GDAL库中用于生成TMS瓦片的python代码,支持谷歌墨卡托EPSG:3857与经纬度EPSG:4326两种瓦片,输出png格式图像. gdal2tiles.py Mo ...

  6. 一起学Android之ProgressBar

    本文简述在Android开发中进度条(ProgressBar)的常见应用,仅供学习分享使用. 概述 在Android开发中,进度条的使用场景有很多,如播放电影时可拖动的观看进度条,评分时使用的评分条, ...

  7. Android项目实战(四十五):Zxing二维码切换横屏扫描

    Demo链接 默认是竖屏扫描,但是当我们在清单文件中配置横屏显示的时候: <activity android:name=".CaptureActivity" android: ...

  8. 网页验证码出不来,读取验证码时出错:javax.imageio.IIOException: Can't create cache file!

    版权声明:本文为博主原创文章,仅作为学习交流使用 转载请注明出处 https://www.cnblogs.com/linck/p/10593053.html 今天打开项目时,发现登陆界面的验证码出不来 ...

  9. Linux(CentOS7)压缩和解压缩war包、tar包、tar.gz包命令

    一.Linux版本 二.解压缩.tar.gz包到当前目录 tar -xzvf apache-tomcat-7.0.90.tar.gz 三.将指定文件压缩成.tar.gz包 tar -czf apach ...

  10. [LeetCode] 22. 括号生成

    题目链接:https://leetcode-cn.com/problems/generate-parentheses/ 题目描述: 给出 n 代表生成括号的对数,请你写出一个函数,使其能够生成所有可能 ...