标签:releases mysq 信息 进程 网址 grep nec get release
mysqld_exporter用来抓取mysql的相关信息:grant replication client,process on . to ‘prom‘@‘localhost‘ identified by ‘xxxx‘;
grant select on performance_schma.* to ‘prom‘@‘localhost‘;
exit
[client]
user=prom
password=xxxx
:wq
prometheus端:
:wq
grafana面板:
显示mysql是否up(up为1):
mysql_up{instance=~"db1:9104"}
显示mysql的uptime时间:
mysql_global_status_uptime{instance=~"db1:9104"}
显示mysql的连接数:
mysql_global_status_threads_connected{instance=~"db1:9104"}
显示正在运行的进程数:
mysql_global_status_threads_running{instance=~"db1:9104"}
显示等待写入的个数:
mysql_global_status_innodb_data_pending_writes{instance=~"imanage-db1:9104"}
标签:releases mysq 信息 进程 网址 grep nec get release
原文地址:http://blog.51cto.com/yangzhiming/2301599