percona: integrate pmm within an existing monitoring platform

23
Integrate Percona Monitoring and Management With a Monitoring system Rachid Zarouali C.I.O SYNOLIA 1

Upload: rachid-zarouali

Post on 14-Apr-2017

125 views

Category:

Data & Analytics


0 download

TRANSCRIPT

Page 1: Percona: Integrate PMM within an existing monitoring platform

IntegratePercona Monitoring and Management

With a Monitoring system

Rachid Zarouali

C.I.OSYNOLIA

1

Page 2: Percona: Integrate PMM within an existing monitoring platform

PERCONA PMMHelps SysAdmin managing DB Server/Clusters Helps Devs optimizing/analyzing queriesWorks perfectly out of the box

2

Page 3: Percona: Integrate PMM within an existing monitoring platform

WHY SHOULD YOUINTEGRATE PMM ?

3

Page 4: Percona: Integrate PMM within an existing monitoring platform

MONITORING INFRASTRUCTURE

GraphiteGrafana

Cabot

4

Page 5: Percona: Integrate PMM within an existing monitoring platform

MYSQL5

Page 6: Percona: Integrate PMM within an existing monitoring platform

6

Page 7: Percona: Integrate PMM within an existing monitoring platform

THE GOOD

integration method

THE BADTHE UGLY

7

Page 8: Percona: Integrate PMM within an existing monitoring platform

PERCONA PMM BUNDLEQAN / Grafana / Prometheus / Orchestrator ( pmm 1.0.5)

used inMonitoring systems

8

Page 9: Percona: Integrate PMM within an existing monitoring platform

MONITORING INFRASTRUCTURE

GraphiteGrafana

Cabot

pmm-server

9

Page 10: Percona: Integrate PMM within an existing monitoring platform

PROS CONS

Duplicated features

Significant overhead

Noisy and untested system

pull metrics (security issue)

Fastest deployment ever

great dashboards

immediate benefits

percona supported since GA

UGLY: WHY

10

Page 11: Percona: Integrate PMM within an existing monitoring platform

BETTER SOLUTION ?Perhaps ......

11

Page 12: Percona: Integrate PMM within an existing monitoring platform

MONITORING INFRASTRUCTURE

Graphite

Cabot

Grafana

12

Page 13: Percona: Integrate PMM within an existing monitoring platform

PROS CONS

Cut from the upstream

Rewrite all dashboards

How about QAN ?

Lowest overhead

No more duplicated system

Unified and simple platform

BAD: WHY

13

Page 14: Percona: Integrate PMM within an existing monitoring platform

BETTER SOLUTION ?

Still not the best :(

Again YES !

14

Page 15: Percona: Integrate PMM within an existing monitoring platform

MONITORING INFRASTRUCTURE

Graphite

Cabot

pmm-server

15

Page 16: Percona: Integrate PMM within an existing monitoring platform

Production server overhead

"locked-in" in prometheus world

New system to use/manage

Pull mecanism for metrics

no docker container for pmm-client

BUT NOT THE BEST: WHY

16

Page 17: Percona: Integrate PMM within an existing monitoring platform

ONE MORE THING!

DON'T PUT PMM IN PRODUCTION

UNLESS YOU KNOW WHAT YOU'RE DOING

BUT .....

I'LL SHOW YOU HOW ANYWAY :)

17

Page 18: Percona: Integrate PMM within an existing monitoring platform

HOW TO ANYWAY ?!Extending Monitoring capabilitiesStaying as close as possible to PMM UpstreamRemoving most of duplicate features

18

Page 19: Percona: Integrate PMM within an existing monitoring platform

HOW ?!Remove everything but the specific (i.e: Apache,Php)Inject in Pmm's Grafana :

dashboardsdatasources

19

Page 20: Percona: Integrate PMM within an existing monitoring platform

HOW ?! HOW ?! HOW ?!

FROM percona/pmm-server:latest

MAINTAINER Rachid Zarouali <[email protected]>

RUN apt-get install wget -qqy

# ############################# ## Add several custom dashboards ## ############################# #

WORKDIR /var/lib/grafana/dashboards

RUN wget https://raw.githubusercontent.com/infinityworksltd/graf-db/master/dashboards/Rancher_Stats.jsonRUN wget https://raw.githubusercontent.com/xinity/graf-db/master/dashboards/Container_Stats.json

# ############################## ## Add specific scrapping options ## ############################## #

COPY conf/tweak-prom.yml /tmpRUN cat /tmp/tweak-prom.yml >> /opt/prometheus/prometheus.yml

# ######################## ## Activate dashboards.json ## ######################## #

COPY conf/grafana-dashs.yml /tmpRUN cat /tmp/grafana-dashs.yml >> /etc/grafana/grafana.ini

DOCKER INSIDE !

20

Page 21: Percona: Integrate PMM within an existing monitoring platform

HOW ?! HOW ?! HOW ?!

[dashboards.json]enabled = truepath = /var/lib/grafana/dashboards

GRAFANA-DASHS.YML

TWEAK-PROM.YML - job_name: 'HostsMetrics' dns_sd_configs: - names: - node-exporter refresh_interval: 15s type: A port: 9100

- job_name: 'ContainerMetrics' dns_sd_configs: - names: - ranch-eye refresh_interval: 15s type: A port: 9104

- job_name: 'rancher-api' dns_sd_configs: - names: - 'prometheus-rancher-exporter' refresh_interval: 15s type: A port: 9010

21

Page 22: Percona: Integrate PMM within an existing monitoring platform

NEXT STEPS ?

22

Page 23: Percona: Integrate PMM within an existing monitoring platform

NEXT STEPSwait for / contribute to prometheus

backup/restoreSeperate TSDB from appsother TSDB interfaces

replace collectd by prometheus exporter

maybe !maybe not !

23