一、PMM简介
之前发布过一篇Prometheus+Grafana的文章,连接为:【DB宝36】使用Docker分分钟搭建漂亮的prometheus+grafana监控,今天我们来介绍一下另一个监控工具:PMM。
PMM(Percona Monitoring and Management)是一个免费的开源平台,用于管理和监视数据库性能,在docker环境中即可运行。它可以主动管理和监控MySQL(AWS RDS MySQL、Aurora MySQL、用户自建MySQL实例)、MariaDB、MongoDB、PostgreSQL等数据库,也可以监控ProxySQL中间件,并提供了众多指标与多样告警方式。
Percona Monitoring and Management (PMM)是一款开源的用于管理和监控MySQL和MongoDB性能的开源平台,通过PMM客户端收集到的DB监控数据用第三方软件Grafana画图展示出来。
PMM提供了对MyISAM、InnoDB、TokuDB和PXC/Glarera的监控,另外也提供了Query Analytics的功能,可以检视执行了哪些SQL指令,并对执行效能较差的语法进行优化。另外在新版本还支持了MySQL复制拓扑图结构构造。Demo官网:http://pmmdemo.percona.com
PMM针对操作系统的部份也提供了硬盘、网络、CPU和RAM的监控,特别的是它提供了Context switches、Processes和interrupts的监控,Context Switches可以看到CPU上下切换文的状况,Processes可以方便了解系统有多少程序在等待I/O。
PMM整体来说算是一款不错的监控产品,针对MySQL、PG、Mongo都有很专业的指标统计,而且部署简单整套打包到容器中。2.0之后底层持久化数据库从MySQL更换为PG后,性能更是有很大提升。
PMM的体系结构如下所示:
二、安装使用
https://www.percona.com/software/pmm/quickstart
https://www.percona.com/doc/percona-monitoring-and-management/2.x/
https://hub.docker.com/r/percona/pmm-server/tags
docker pull percona/pmm-server:latest
-- 拉取镜像
docker pull percona/pmm-server:2.14
-- 创建PMM数据容器
docker rm lhr-pmm-data
docker create --name lhr-pmm-data -v /pmmdata percona/pmm-server:2.14 /bin/true
-- 创建PMM服务器容器
docker rm -f lhr-pmm-server
docker run -d --name lhr-pmm-server -h lhr-pmm-server -p 280:80 -p 2443:443 --volumes-from lhr-pmm-data -e SERVER_USER=lhr -e SERVER_PASSWORD=lhr -e ORCHESTRATOR_ENABLED=true -e METRICS_RETENTION=48h --restart always percona/pmm-server:2.14
-- 访问web界面
http://192.168.66.35:280
https://192.168.66.35:2443
admin/admin
-- 进入PMM服务器
docker exec -it lhr-pmm-server bash
-- 连接到PMM服务器
pmm-admin config --server-insecure-tls --server-url=https://admin:admin@127.0.0.1:443
pmm-admin list
可以使用http或https访问,端口号不一样。
登陆之后就可以看到以下信息:
[root@lhr-pmm-server opt]# pmm-admin config --server-insecure-tls --server-url=https://admin:admin@127.0.0.1:443
Checking local pmm-agent status...
pmm-agent is running.
Registering pmm-agent on PMM Server...
Registered.
Configuration file /usr/local/percona/pmm2/config/pmm-agent.yaml updated.
Reloading pmm-agent configuration...
Configuration reloaded.
Checking local pmm-agent status...
pmm-agent is running.
[root@lhr-pmm-server opt]# pmm-admin list
Service type Service name Address and port Service ID
Agent type Status Metrics Mode Agent ID Service ID
pmm_agent Connected /agent_id/57124a26-ea3e-4240-b39d-ec91af80e559
node_exporter Running push /agent_id/fed6ce91-c926-49d1-8bcb-17a8e3225f78
vmagent Running push /agent_id/cbd8515c-d655-4467-a6bd-42c9db580ff2
三、监控MySQL数据库
可以添加多个被监控实例,执行过程:
[root@lhr-pmm-server opt]# pmm-admin add mysql --query-source=perfschema --username=root --password=lhr --host=192.168.66.35 --port=3317 --service-name=mysql-192.168.66.35-3317
MySQL Service added.
Service ID : /service_id/28cd296f-597a-4043-8c87-792308b31d37
Service name: mysql-192.168.66.35-3317
Table statistics collection enabled (the limit is 1000, the actual table count is 535).
[root@lhr-pmm-server opt]# pmm-admin add mysql --query-source=perfschema --username=root --password=lhr --host=192.168.66.35 --port=3318 --service-name=mysql-192.168.66.35-3318
MySQL Service added.
Service ID : /service_id/aceb0ad7-86c6-4ec8-9c45-8fe7f4135721
Service name: mysql-192.168.66.35-3318
Table statistics collection disabled (the limit is 1000, the actual table count is 1042).
[root@lhr-pmm-server opt]# pmm-admin list
Service type Service name Address and port Service ID
MySQL mysql-192.168.66.35-3317 192.168.66.35:3317 /service_id/28cd296f-597a-4043-8c87-792308b31d37
MySQL mysql-192.168.66.35-3318 192.168.66.35:3318 /service_id/aceb0ad7-86c6-4ec8-9c45-8fe7f4135721
Agent type Status Metrics Mode Agent ID Service ID
pmm_agent Connected /agent_id/57124a26-ea3e-4240-b39d-ec91af80e559
node_exporter Running push /agent_id/fed6ce91-c926-49d1-8bcb-17a8e3225f78
mysqld_exporter Running push /agent_id/5a8f8a51-c342-4108-8f94-1779e00ed118 /service_id/aceb0ad7-86c6-4ec8-9c45-8fe7f4135721
mysqld_exporter Running push /agent_id/b8342bd9-0c20-40d6-a666-b6b79903f5e8 /service_id/28cd296f-597a-4043-8c87-792308b31d37
mysql_perfschema_agent Running /agent_id/908ad693-b9a2-43a9-abd2-f0d06ca1ca09 /service_id/28cd296f-597a-4043-8c87-792308b31d37
mysql_perfschema_agent Running /agent_id/f965b782-76eb-49e8-874c-df52d47c7cb7 /service_id/aceb0ad7-86c6-4ec8-9c45-8fe7f4135721
vmagent Running push /agent_id/cbd8515c-d655-4467-a6bd-42c9db580ff2
PMM监控界面:
MySQL慢查询分析
PMM能对慢查询进行监控分析:
四、监控PG数据库
PMM服务器的后端元数据存储用的是PG数据库,所以,我们可以直接监控该库:
[root@lhr-pmm-server opt]# pmm-admin add postgresql --username=pmm-managed --password=pmm-managed --host=127.0.0.1 --port=5432 --service-name=PG-127.0.0.1-5432
PostgreSQL Service added.
Service ID : /service_id/cb3c1b6d-fea0-4a81-9dcb-2c1840fc547b
Service name: PG-127.0.0.1-5432
[root@lhr-pmm-server opt]# pmm-admin list
Service type Service name Address and port Service ID
MySQL mysql-192.168.66.35-3317 192.168.66.35:3317 /service_id/28cd296f-597a-4043-8c87-792308b31d37
MySQL mysql-192.168.66.35-3318 192.168.66.35:3318 /service_id/aceb0ad7-86c6-4ec8-9c45-8fe7f4135721
PostgreSQL PG-127.0.0.1-5432 127.0.0.1:5432 /service_id/cb3c1b6d-fea0-4a81-9dcb-2c1840fc547b
Agent type Status Metrics Mode Agent ID Service ID
pmm_agent Connected /agent_id/57124a26-ea3e-4240-b39d-ec91af80e559
node_exporter Running push /agent_id/fed6ce91-c926-49d1-8bcb-17a8e3225f78
mysqld_exporter Running push /agent_id/5a8f8a51-c342-4108-8f94-1779e00ed118 /service_id/aceb0ad7-86c6-4ec8-9c45-8fe7f4135721
mysqld_exporter Running push /agent_id/b8342bd9-0c20-40d6-a666-b6b79903f5e8 /service_id/28cd296f-597a-4043-8c87-792308b31d37
postgres_exporter Running push /agent_id/28bfba92-4872-4cd9-b3a1-5273670a44a2 /service_id/cb3c1b6d-fea0-4a81-9dcb-2c1840fc547b
mysql_perfschema_agent Running /agent_id/908ad693-b9a2-43a9-abd2-f0d06ca1ca09 /service_id/28cd296f-597a-4043-8c87-792308b31d37
mysql_perfschema_agent Running /agent_id/f965b782-76eb-49e8-874c-df52d47c7cb7 /service_id/aceb0ad7-86c6-4ec8-9c45-8fe7f4135721
postgresql_pgstatements_agent Running /agent_id/5cf99a1b-b474-48a9-94ad-acc6bdc77efb /service_id/cb3c1b6d-fea0-4a81-9dcb-2c1840fc547b
vmagent Running push /agent_id/cbd8515c-d655-4467-a6bd-42c9db580ff2
PMM监控界面:
五、监控MongoDB数据库
使用PMM监视集群时,应使用pmm-admin add命令启用对每个实例的监视,这包括分片集群中的副本集、mongos和所有配置服务器。
-- 无密码
pmm-admin add mongodb --host=192.168.66.35 --port=27017 --service-name=mongodb-192.168.66.35-27017
-- 有密码
pmm-admin add mongodb --username=root --password=lhr mongodb-192.168.66.35-37017 192.168.66.35:37017
pmm-admin add mongodb --username=root --password=lhr --host=192.168.66.35 --port=37017 --service-name=mongodb-192.168.66.35-37017
-- 集群、复制集
pmm-admin add mongodb --cluster lhr-mongo-cluster --replication-set=lhr_rep --username=root --password=lhr --host=192.168.66.35 --port=37020 --service-name=mongodb-192.168.66.35-37020-lhr_rep
pmm-admin add mongodb --cluster lhr-mongo-cluster --replication-set=lhr_rep --username=root --password=lhr --host=192.168.66.35 --port=37021 --service-name=mongodb-192.168.66.35-37021-lhr_rep
pmm-admin add mongodb --cluster lhr-mongo-cluster --replication-set=lhr_rep --username=root --password=lhr --host=192.168.66.35 --port=37022 --service-name=mongodb-192.168.66.35-37022-lhr_rep
pmm-admin add mongodb --cluster lhr-mongo-cluster --replication-set=lhr_rep --username=root --password=lhr --host=192.168.66.35 --port=37023 --service-name=mongodb-192.168.66.35-37023-lhr_rep
pmm-admin add mongodb --cluster lhr-mongo-cluster --replication-set=lhr_rep --username=root --password=lhr --host=192.168.66.35 --port=37024 --service-name=mongodb-192.168.66.35-37024-lhr_rep
-- 查询
pmm-admin list
添加完成后:
[root@lhr-pmm-server opt]# pmm-admin list
Service type Service name Address and port Service ID
MySQL mysql-192.168.66.35-3317 192.168.66.35:3317 /service_id/3d97792c-928c-4475-b5f3-f619d3b976e1
MySQL mysql-192.168.66.35-3316 192.168.66.35:3316 /service_id/4247b3f3-0b7c-48c6-aa72-3545a07d71c9
MySQL mysql-192.168.66.35-3315 192.168.66.35:3315 /service_id/5318af15-e338-4628-a7ba-19e2f510239d
MySQL mysql-192.168.66.35-3318 192.168.66.35:3318 /service_id/e527f5f2-e6f4-4eb9-9c73-86469fbf08e8
MongoDB mongodb-192.168.66.35-37024-lhr_rep 192.168.66.35:37024 /service_id/04e6a8b3-cb60-4a51-ae33-d67190a1da90
MongoDB mongodb-192.168.66.35-27017 192.168.66.35:27017 /service_id/11d684d1-f851-48f7-aec2-809814d073d2
MongoDB mongodb-192.168.66.35-37021-lhr_rep 192.168.66.35:37021 /service_id/178fb790-6e89-478e-b3c3-d50cdb158bcf
MongoDB mongodb-192.168.66.35-37020-lhr_rep 192.168.66.35:37020 /service_id/333c1bfa-6c51-4b57-9002-9bc9cca41880
MongoDB mongodb-192.168.66.35-37022-lhr_rep 192.168.66.35:37022 /service_id/7f8a5062-0e78-4078-80e1-f8a70f2d2b0a
MongoDB mongodb-192.168.66.35-37017 192.168.66.35:37017 /service_id/924ec922-3d7d-4b53-9bfc-aa9345109dda
MongoDB mongodb-192.168.66.35-37023-lhr_rep 192.168.66.35:37023 /service_id/c2ee5791-9d23-41ee-af7d-d21b50c2dd77
PostgreSQL PG-127.0.0.1-5432 127.0.0.1:5432 /service_id/278f216a-c3d5-43fd-9163-e7a30dd459e1
Agent type Status Metrics Mode Agent ID Service ID
pmm_agent Connected /agent_id/f304147a-43a6-484b-9d32-d8f3c721cb63
node_exporter Running push /agent_id/89311eaa-bf62-4730-8f3b-ebddb9ddfe57
mysqld_exporter Running push /agent_id/13bca963-69be-4313-b6b4-ed4234c0abb5 /service_id/3d97792c-928c-4475-b5f3-f619d3b976e1
mysqld_exporter Running push /agent_id/29177549-d624-43dd-ae28-f29e913587d0 /service_id/e527f5f2-e6f4-4eb9-9c73-86469fbf08e8
mysqld_exporter Running push /agent_id/ee281335-8d7b-47fd-91a9-873062beff2d /service_id/4247b3f3-0b7c-48c6-aa72-3545a07d71c9
mysqld_exporter Running push /agent_id/fc3fad17-4dd1-4ae7-aa4e-22cce69dfe02 /service_id/5318af15-e338-4628-a7ba-19e2f510239d
mongodb_exporter Running push /agent_id/690ab339-5838-43c5-978e-73bb188d434a /service_id/7f8a5062-0e78-4078-80e1-f8a70f2d2b0a
mongodb_exporter Running push /agent_id/69905494-247a-41d1-b45f-a8e31639baf9 /service_id/333c1bfa-6c51-4b57-9002-9bc9cca41880
mongodb_exporter Running push /agent_id/7d97045e-afae-4e05-8216-5fbf5f28a74b /service_id/924ec922-3d7d-4b53-9bfc-aa9345109dda
mongodb_exporter Running push /agent_id/860ed641-3599-4fdc-9f57-8137d45f06b8 /service_id/11d684d1-f851-48f7-aec2-809814d073d2
mongodb_exporter Running push /agent_id/87be410e-dd68-4ce2-80fa-05d7827b5300 /service_id/178fb790-6e89-478e-b3c3-d50cdb158bcf
mongodb_exporter Running push /agent_id/c5f4b04a-3520-4355-aca5-7e41646883c5 /service_id/c2ee5791-9d23-41ee-af7d-d21b50c2dd77
mongodb_exporter Running push /agent_id/c78247a4-1a66-410d-bb18-7032f9fa016b /service_id/04e6a8b3-cb60-4a51-ae33-d67190a1da90
postgres_exporter Running push /agent_id/e6f7e9f2-2657-48ac-9fb0-ef7e4bd5a547 /service_id/278f216a-c3d5-43fd-9163-e7a30dd459e1
mysql_perfschema_agent Waiting /agent_id/100d98c1-3b3d-4dee-8bc1-843495ed529a /service_id/5318af15-e338-4628-a7ba-19e2f510239d
mysql_perfschema_agent Running /agent_id/9827db00-7a69-4d05-9295-85c06fb2ebc3 /service_id/3d97792c-928c-4475-b5f3-f619d3b976e1
mysql_perfschema_agent Running /agent_id/e3e3890c-cbbd-4e05-8e23-ba4e624f78a5 /service_id/4247b3f3-0b7c-48c6-aa72-3545a07d71c9
mysql_perfschema_agent Running /agent_id/fa3201ca-b5d8-46aa-9e04-f1b5102e6336 /service_id/e527f5f2-e6f4-4eb9-9c73-86469fbf08e8
mongodb_profiler_agent Running /agent_id/4887dbdf-e603-45d7-af74-a9067cbe56c8 /service_id/11d684d1-f851-48f7-aec2-809814d073d2
mongodb_profiler_agent Running /agent_id/4e51521d-ea16-4dd5-a3e2-940c717a3e53 /service_id/c2ee5791-9d23-41ee-af7d-d21b50c2dd77
mongodb_profiler_agent Running /agent_id/5cd5dee9-e158-43a0-9511-ad4c7b2d9e47 /service_id/7f8a5062-0e78-4078-80e1-f8a70f2d2b0a
mongodb_profiler_agent Running /agent_id/807b4342-735c-4816-b491-e3cbbf4170bd /service_id/178fb790-6e89-478e-b3c3-d50cdb158bcf
mongodb_profiler_agent Running /agent_id/c2737dd5-7ec4-47fe-aa66-68209d4f3225 /service_id/924ec922-3d7d-4b53-9bfc-aa9345109dda
mongodb_profiler_agent Running /agent_id/c8511980-db30-476a-8776-7aa14a32eebf /service_id/04e6a8b3-cb60-4a51-ae33-d67190a1da90
mongodb_profiler_agent Running /agent_id/fc4a0fa5-9fb4-4ba3-99d9-3d9c30d443e3 /service_id/333c1bfa-6c51-4b57-9002-9bc9cca41880
postgresql_pgstatements_agent Running /agent_id/e00bddb3-ef8e-4f74-9c9b-98e6b274769d /service_id/278f216a-c3d5-43fd-9163-e7a30dd459e1
vmagent Running push /agent_id/4b564af7-7775-4337-86cf-950daeabb354
PMM监控界面:
监控内容较多,可以自行点击查看:
六、监控ProxySQL中间件
[root@lhr-pmm-server opt]# pmm-admin add proxysql --username=root --password=lhr --host=192.168.66.35 --port=16032 --service-name=proxysql-192.168.66.35-16032
ProxySQL Service added.
Service ID : /service_id/84d87f04-e701-4480-abc9-bde170bfd478
Service name: proxysql-192.168.66.35-16032
[root@lhr-pmm-server opt]# pmm-admin list
Service type Service name Address and port Service ID
MySQL mysql-192.168.66.35-3317 192.168.66.35:3317 /service_id/3d97792c-928c-4475-b5f3-f619d3b976e1
MySQL mysql-192.168.66.35-3316 192.168.66.35:3316 /service_id/4247b3f3-0b7c-48c6-aa72-3545a07d71c9
MySQL mysql-192.168.66.35-3315 192.168.66.35:3315 /service_id/5318af15-e338-4628-a7ba-19e2f510239d
MySQL mysql-192.168.66.35-3318 192.168.66.35:3318 /service_id/e527f5f2-e6f4-4eb9-9c73-86469fbf08e8
MongoDB mongodb-192.168.66.35-37024-lhr_rep 192.168.66.35:37024 /service_id/04e6a8b3-cb60-4a51-ae33-d67190a1da90
MongoDB mongodb-192.168.66.35-27017 192.168.66.35:27017 /service_id/11d684d1-f851-48f7-aec2-809814d073d2
MongoDB mongodb-192.168.66.35-37021-lhr_rep 192.168.66.35:37021 /service_id/178fb790-6e89-478e-b3c3-d50cdb158bcf
MongoDB mongodb-192.168.66.35-37020-lhr_rep 192.168.66.35:37020 /service_id/333c1bfa-6c51-4b57-9002-9bc9cca41880
MongoDB mongodb-192.168.66.35-37022-lhr_rep 192.168.66.35:37022 /service_id/7f8a5062-0e78-4078-80e1-f8a70f2d2b0a
MongoDB mongodb-192.168.66.35-37017 192.168.66.35:37017 /service_id/924ec922-3d7d-4b53-9bfc-aa9345109dda
MongoDB mongodb-192.168.66.35-37023-lhr_rep 192.168.66.35:37023 /service_id/c2ee5791-9d23-41ee-af7d-d21b50c2dd77
PostgreSQL PG-127.0.0.1-5432 127.0.0.1:5432 /service_id/278f216a-c3d5-43fd-9163-e7a30dd459e1
ProxySQL proxysql-192.168.66.35-16032 192.168.66.35:16032 /service_id/f43ada33-f77d-4cbf-9c98-331b7ba2310e
Agent type Status Metrics Mode Agent ID Service ID
pmm_agent Connected /agent_id/f304147a-43a6-484b-9d32-d8f3c721cb63
node_exporter Running push /agent_id/89311eaa-bf62-4730-8f3b-ebddb9ddfe57
mysqld_exporter Running push /agent_id/13bca963-69be-4313-b6b4-ed4234c0abb5 /service_id/3d97792c-928c-4475-b5f3-f619d3b976e1
mysqld_exporter Running push /agent_id/29177549-d624-43dd-ae28-f29e913587d0 /service_id/e527f5f2-e6f4-4eb9-9c73-86469fbf08e8
mysqld_exporter Running push /agent_id/ee281335-8d7b-47fd-91a9-873062beff2d /service_id/4247b3f3-0b7c-48c6-aa72-3545a07d71c9
mysqld_exporter Running push /agent_id/fc3fad17-4dd1-4ae7-aa4e-22cce69dfe02 /service_id/5318af15-e338-4628-a7ba-19e2f510239d
mongodb_exporter Running push /agent_id/690ab339-5838-43c5-978e-73bb188d434a /service_id/7f8a5062-0e78-4078-80e1-f8a70f2d2b0a
mongodb_exporter Running push /agent_id/69905494-247a-41d1-b45f-a8e31639baf9 /service_id/333c1bfa-6c51-4b57-9002-9bc9cca41880
mongodb_exporter Running push /agent_id/7d97045e-afae-4e05-8216-5fbf5f28a74b /service_id/924ec922-3d7d-4b53-9bfc-aa9345109dda
mongodb_exporter Running push /agent_id/860ed641-3599-4fdc-9f57-8137d45f06b8 /service_id/11d684d1-f851-48f7-aec2-809814d073d2
mongodb_exporter Running push /agent_id/87be410e-dd68-4ce2-80fa-05d7827b5300 /service_id/178fb790-6e89-478e-b3c3-d50cdb158bcf
mongodb_exporter Running push /agent_id/c5f4b04a-3520-4355-aca5-7e41646883c5 /service_id/c2ee5791-9d23-41ee-af7d-d21b50c2dd77
mongodb_exporter Running push /agent_id/c78247a4-1a66-410d-bb18-7032f9fa016b /service_id/04e6a8b3-cb60-4a51-ae33-d67190a1da90
postgres_exporter Running push /agent_id/e6f7e9f2-2657-48ac-9fb0-ef7e4bd5a547 /service_id/278f216a-c3d5-43fd-9163-e7a30dd459e1
proxysql_exporter Running push /agent_id/86664e69-156a-487d-aaa0-9ab585befb99 /service_id/f43ada33-f77d-4cbf-9c98-331b7ba2310e
mysql_perfschema_agent Waiting /agent_id/100d98c1-3b3d-4dee-8bc1-843495ed529a /service_id/5318af15-e338-4628-a7ba-19e2f510239d
mysql_perfschema_agent Running /agent_id/9827db00-7a69-4d05-9295-85c06fb2ebc3 /service_id/3d97792c-928c-4475-b5f3-f619d3b976e1
mysql_perfschema_agent Running /agent_id/e3e3890c-cbbd-4e05-8e23-ba4e624f78a5 /service_id/4247b3f3-0b7c-48c6-aa72-3545a07d71c9
mysql_perfschema_agent Running /agent_id/fa3201ca-b5d8-46aa-9e04-f1b5102e6336 /service_id/e527f5f2-e6f4-4eb9-9c73-86469fbf08e8
mongodb_profiler_agent Running /agent_id/4887dbdf-e603-45d7-af74-a9067cbe56c8 /service_id/11d684d1-f851-48f7-aec2-809814d073d2
mongodb_profiler_agent Running /agent_id/4e51521d-ea16-4dd5-a3e2-940c717a3e53 /service_id/c2ee5791-9d23-41ee-af7d-d21b50c2dd77
mongodb_profiler_agent Running /agent_id/5cd5dee9-e158-43a0-9511-ad4c7b2d9e47 /service_id/7f8a5062-0e78-4078-80e1-f8a70f2d2b0a
mongodb_profiler_agent Running /agent_id/807b4342-735c-4816-b491-e3cbbf4170bd /service_id/178fb790-6e89-478e-b3c3-d50cdb158bcf
mongodb_profiler_agent Running /agent_id/c2737dd5-7ec4-47fe-aa66-68209d4f3225 /service_id/924ec922-3d7d-4b53-9bfc-aa9345109dda
mongodb_profiler_agent Running /agent_id/c8511980-db30-476a-8776-7aa14a32eebf /service_id/04e6a8b3-cb60-4a51-ae33-d67190a1da90
mongodb_profiler_agent Running /agent_id/fc4a0fa5-9fb4-4ba3-99d9-3d9c30d443e3 /service_id/333c1bfa-6c51-4b57-9002-9bc9cca41880
postgresql_pgstatements_agent Running /agent_id/e00bddb3-ef8e-4f74-9c9b-98e6b274769d /service_id/278f216a-c3d5-43fd-9163-e7a30dd459e1
vmagent Running push /agent_id/4b564af7-7775-4337-86cf-950daeabb354
PMM默认没有ProxySQL的监控模板,需要我们自行下载:https://github.com/percona/grafana-dashboards/blob/master/dashboards/ProxySQL_Overview.json
下载后上传到PMM的监控界面中就可以了。
监控后的界面:
About Me
● 本文作者:小麦苗,部分内容整理自网络,若有侵权请联系小麦苗删除
● 本文在个人微 信公众号(DB宝)上有同步更新
● QQ群号: 230161599 、618766405,微信群私聊
● 个人QQ号(646634621),微 信号(db_bao),注明添加缘由
● 于 2021年3月 在西安完成
● 最新修改时间:2021年3月
● 版权所有,欢迎分享本文,转载请保留出处
●小麦苗的微店: https://weidian.com/?userid=793741433
●小麦苗出版的数据库类丛书: http://blog.itpub.net/26736162/viewspace-2142121/
●小麦苗OCP、OCM、高可用、DBA学习班(Oracle、MySQL、NoSQL): http://blog.itpub.net/26736162/viewspace-2148098/
●数据库笔试面试题库及解答: https://mp.weixin.qq.com/s/Vm5PqNcDcITkOr9cQg6T7w
使用微信客户端扫描下面的二维码来关注小麦苗的微信公众号(DB宝)及QQ群(DBA宝典)、添加小麦苗微信, 学习最实用的数据库技术。