mycheckpoint 是针对mysql的一个性能监控、指标采集的python写成的工具。

工作原理说明:

mycheckpoint是一段脚本,通过将其设置为crontab定时任务,每几分钟采集一次数据(受限于crontab只能是分钟为基本单位)存储在自己的数据库中,并可以将采集的数据进行统计,以web页面的形式展现出来。

示例效果:

详细请参见:http://code.openark.org/forge/mycheckpoint

使用步骤:

0. 下载:

wget https://mycheckpoint.googlecode.com/files/mycheckpoint-231.tar.gz

1. 为mycheckpoint创建数据库

CREATE DATABASE mycheckpoint;

2. 授权给当前登录mysql的用户

 GRANT ALL PRIVILEGES ON mycheckpoint.* TO 'root'@'localhost' IDENTIFIED BY 'xxxx';

3. 创建mycheckpoint需要的数据库表。

    mycheckpoint --host=127.0.0.1 --port= --user=root --password=xxxx --socket=/mysql/tmp/mysql.sock --database=mycheckpoint

进过这一个步骤之后,会在名为:mycheckpoint数据库中,生成以下数据表。

+------------------------------------+
| Tables_in_mycheckpoint |
+------------------------------------+
| alert |
| alert_condition |
| alert_condition_query_view |
| alert_email_message_items_view |
| alert_pending |
| alert_pending_html_view |
| alert_pending_view |
| alert_view |
| charts_api |
| custom_query |
| custom_query_top_navigation_view |
| custom_query_view |
| html_components |
| metadata |
| numbers |
| status_variables |
| status_variables_aggregated_day |
| status_variables_aggregated_hour |
| sv_custom_chart_day |
| sv_custom_chart_flattened_day |
| sv_custom_chart_flattened_hour |
| sv_custom_chart_flattened_sample |
| sv_custom_chart_hour |
| sv_custom_chart_sample |
| sv_custom_html |
| sv_custom_html_brief |
| sv_day |
| sv_diff |
| sv_hour |
| sv_latest |
| sv_param_change |
| sv_parameter_change_union |
| sv_report_24_7 |
| sv_report_24_7_minmax |
| sv_report_chart_24_7 |
| sv_report_chart_day |
| sv_report_chart_day_labels |
| sv_report_chart_day_timeseries |
| sv_report_chart_hour |
| sv_report_chart_hour_labels |
| sv_report_chart_hour_timeseries |
| sv_report_chart_sample |
| sv_report_chart_sample_labels |
| sv_report_chart_sample_timeseries |
| sv_report_day |
| sv_report_day_recent |
| sv_report_day_recent_minmax |
| sv_report_hour |
| sv_report_hour_recent |
| sv_report_hour_recent_minmax |
| sv_report_html |
| sv_report_html_24_7 |
| sv_report_html_brief |
| sv_report_human_day |
| sv_report_human_hour |
| sv_report_human_sample |
| sv_report_sample |
| sv_report_sample_recent |
| sv_report_sample_recent_aggregated |
| sv_report_sample_recent_minmax |
| sv_sample |
+------------------------------------+

如果意外将你的web app 的DB指定成了log数据库,则会在你的web app DB中加入以上数据表,并将原web app DB中重名的数据表删除。这将是灾难性的!

4. 将mycheckpoint配置成定时任务

* * * * * /usr/local/bin/mycheckpoint  --user=root --password=xxxx --socket=/redmine/mysql/tmp/mysql.sock --database=mycheckpoint

5. http方式查看结果:

   mycheckpoint --host=127.0.0.1 --port= --user=root --password=xxxx --socket=/mysql/tmp/mysql.sock --database=mycheckpoint  http

指定数据库时需注意,切莫使用你的web app 的DB.

一个小时之后就可以打开本地的http://localhost:12306/mycheckpoint 查看报表。

点评:

这个工具的优势是能将数据统计结果以web形式展现,但是由于其依赖crontab,导致数据采集间隔过大,不能很好的描述mysql的运行状况, 另外,此工具已经于2014年4月停止更新

其它的mysql第三方工具还有: percona-toolkit / mysqltuner.pl / tuning-primer.sh 等。

参考:

1. http://code.openark.org/forge/mycheckpoint

2. https://code.google.com/p/mycheckpoint/downloads/list

mysql性能监控工具:mycheckpoint的使用方法的更多相关文章

  1. mysql性能的检查和调优方法

    mysql性能的检查和调优方法 发布时间:2009 年 10 月 4 日 发布者: OurMySQL 来源:sudone.com   才被阅读:3,524 次    才1条评论    我一直是使用my ...

  2. MySQL性能监控工具-Spotlight on MySQL

    原文地址:http://blog.csdn.net/k_scott/article/details/8167018 这是我的第二款用于监控MySQL数据库性能的工具:Spotlight on MySQ ...

  3. mysql性能监控工具Innotop

    mysql监控管理工具--innotop 1.innotop安装参考官网:http://innotop.googlecode.com/svn/html/installing.html # wget h ...

  4. mysql性能监控工具

    参考文档: http://www.linuxidc.com/Linux/2012-09/70459.htm 1.记录慢查询SQL #配置开启 (linux)修改my.cnf: log-slow-que ...

  5. MySQL性能监控工具-MONyog

      1.登录配置界面 2.show processlist 查看当前使用的进程 3.警告建议你应该优化哪些参数. 4.介绍一下慢查询的配置,其它的可以自己配置,都是简单的英文. 该工具,用着还不错.其 ...

  6. Mysql 性能优化2 系统参数配置方法 和 文件系统

    --------------------------------------------目录------------------------------------------------- • 关于 ...

  7. redmine在linux上的mysql性能优化方法与问题排查方案

    iredmine的linux服务器mysql性能优化方法与问题排查方案     问题定位:   客户端工具: 1. 浏览器inspect-tool的network timing工具分析   2. 浏览 ...

  8. MySQL实时性能监控工具doDBA tools

    doDBA tools是什么? doDBA tools是一个基于控制台的远程监控工具,它不需要在本地/远程系统上安装任何软件,它可以实时收集操作系统.MySQL.InnoDB的实时性能状态数据,并可以 ...

  9. <转>MySQL性能调优的10个方法

    文章原地址:http://mp.weixin.qq.com/s/oRXJRz_Y5drmIrcbxSKOcw 1. 选择合适的存储引擎: InnoDB 除非你的数据表使用来做只读或者全文检索 (相信现 ...

随机推荐

  1. 2014 New Year’s First Blog

    新年开篇博客,依旧是流水账. 读到一篇强文,<关于两个世界体系的对话>.common practice 往往是针对某种语言或者特定技术为背景,然而,很多时候,common practice ...

  2. C# 正则表达式测试工具与分享窗体自适应类

    放假刚回来,自己打算写一个正则表达式的测试工具,因为上次在网上用的一个在线正则表示测试工具就 没有很好的服务自己的,所以才有了现在的想法,想写一个C#开发者用的正则表达式测试工具!期间由于最大化时控件 ...

  3. 六款值得推荐的android(安卓)开源框架简介

    1.volley 项目地址 https://github.com/smanikandan14/Volley-demo (1)  JSON,图像等的异步下载: (2)  网络请求的排序(scheduli ...

  4. 用c#开发微信 (9) 微渠道 - 推广渠道管理系统 4 部署测试 (最终效果图)

    我们可以使用微信的“生成带参数二维码接口”和 “用户管理接口”,来实现生成能标识不同推广渠道的二维码,记录分配给不同推广渠道二维码被扫描的信息.这样就可以统计和分析不同推广渠道的推广效果. 本文是微渠 ...

  5. 学习WPF——WPF布局——初识布局容器

    StackPanel堆叠布局 StackPanel是简单布局方式之一,可以很方便的进行纵向布局和横向布局 StackPanel默认是纵向布局的 <Window x:Class="Wpf ...

  6. SQL SERVER 数据库查询表和字段信息语句

    --数据库中所有表的信息(很强悍的)    SELECT    表名               =   CASE   WHEN   A.COLORDER=1   THEN   D.NAME   EL ...

  7. Mac上搭建直播服务器Nginx+rtmp

    简介 nginx是非常优秀的开源服务器,用它来做hls或者rtmp流媒体服务器是非常不错的选择,本人在网上整理了安装流程,分享给大家并且作备忘. 步骤安装 1.安装Homebrow Homebrew简 ...

  8. 浅谈压缩感知(二十九):压缩感知算法之迭代硬阈值(IHT)

    主要内容: 1.IHT的算法流程 2.IHT的MATLAB实现 3.二维信号的实验与结果 4.加速的IHT算法实验与结果 一.IHT的算法流程 文献:T. Blumensath and M. Davi ...

  9. CI框架笔记

    @update 2016-4-2 13:45:35 一.目录结构 ci_demo ├─myapp 应用主目录 │ ├─autoload.php 自定义的自动加载文件(可选) │ ├─myapp.php ...

  10. ASP.NET MVC4+EasyUI+EntityFrameWork5权限管理系统——菜单模块的实现(二)

    ASP.NET MVC4+EasyUI+EntityFrameWork5权限管理系统——数据库的设计(一) 菜单和模块是在同一个表中,采用的是树形结构,模块菜单表结构如下代码: USE [Permis ...