/article/2017/10/25/mysql-innotop/

Mysql Innodb分析工具:innotop

  • 【作者】看不见我
  • 【分类】Service
  • 【发布】2017-10-25 22:45
  • 【更新】2017-10-25 22:45

Innotop

innotop is a 'top' clone for MySQL with many features and flexibility.

  • completely customizable; it even has a plugin interface
  • monitors many servers at once and can aggregate across them

Web

google(old) https://code.google.com/archive/p/innotop/

github(new) https://github.com/innotop/innotop

Requirement

# perl-DBD-MySQL
# perl-Time-HiRes
# perl-DBI
# perl-TermReadKey
yum install -y perl-DBD-MySQL perl-Time-HiRes perl-DBI perl-TermReadKey
yum install openssl-devel -y

Install

RPM Install:

wget https://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/innotop/innotop-1.9.1-1.el6.noarch.rpm --no-check-certificate
rpm -ivh innotop-1.9.1-1.el6.noarch.rpm

Source Install:

VERSION=1.11.1
wget -O innotop-${VERSION}.tar.gz https://github.com/innotop/innotop/archive/v${VERSION}.tar.gz
[ $? -eq 0 ] && tar -zxvf innotop-${VERSION}.tar.gz
[ $? -eq 0 ] && cd innotop-${VERSION}
[ $? -eq 0 ] && perl Makefile.PL
[ $? -eq 0 ] && make
[ $? -eq 0 ] && make install
[ $? -eq 0 ] && cp -a innotop /usr/local/bin/

Usage

innotop --help

Usage: innotop <options> <innodb-status-file>

  --askpass          Prompt for a password when connecting to MySQL
  --[no]color   -C   Use terminal coloring (default)
  --config      -c   Config file to read
  --count            Number of updates before exiting
  --delay       -d   Delay between updates in seconds
  --help             Show this help message
  --host        -h   Connect to host
  --[no]inc     -i   Measure incremental differences
  --mode        -m   Operating mode to start in
  --nonint      -n   Non-interactive, output tab-separated fields
  --password    -p   Password to use for connection
  --port        -P   Port number to use for connection
  --skipcentral -s   Skip reading the central configuration file
  --socket      -S   MySQL socket to use for connection
  --spark            Length of status sparkline (default 10)
  --timestamp   -t   Print timestamp in -n mode (1: per iter; 2: per line)
  --user        -u   User for login if not current user
  --version          Output version information and exit
  --write       -w   Write running configuration into home directory if no config files were loaded

innotop is a MySQL and InnoDB transaction/status monitor, like 'top' for
MySQL.  It displays queries, InnoDB transactions, lock waits, deadlocks,
foreign key errors, open tables, replication status, buffer information,
row operations, logs, I/O operations, load graph, and more.  You can
monitor many servers at once with innotop.

Reference

http://www.cnblogs.com/ivictor/p/5101506.html
http://blog.csdn.net/wyzxg/article/details/8609981

Top