Cloud-Native Monitoring
With Prometheus
Jacopo Nardiello
Founder & DevOps Engineer
@jnardiello
Thanks to our sponsors
KubePrimer Workshop
14/07, Milano
http://kubeprimer.sighup.io
What is Prometheus?
Community Driven Open-source Monitoring and
Alerting toolkit, ships a time series database, an
alerting entity and a number of integration tools to
expose metrics.
A bit of context around Prometheus
Started in 2012 as a SoundCloud
internal project
Second project to join CNCF after
Kubernetes
Focus
Operational systems monitoring
Dynamic cloud environments
Natively integrates with existing
providers/tools and extract
scrape targets
Monitoring Cloud Native Applications with Prometheus
Core features
● A powerful query language - PromQL
● Dimensional Data model
● Optimized to be efficient
● Operational & Architectural simplicity
Pull
/metrics endpoints
Model & typical monitoring scenario
The Architecture behind Prometheus
Let’s go a bit hands-on
Time Series Database
&
Web UI
http://demo.robustperception.io:9090/graph
Alert-Manager
http://demo.robustperception.io:9090/graph
Graphs & Dashboards
http://demo.robustperception.io:3000/dashboard/db/host-stats
PromQL & Label based queries
http_requests_total all time series related to the metric http_requests_total
http_requests_total{code="200",method="get"} time series related to successful request with
method get for the metric http_requests_total
http_requests_total{code="200",method="get"}[5m] returns a range vector
http_requests_total{status!~"^4..$"}
Selecting all errors-related time series using
regexes
sum(rate(http_requests_total[5m])) by (job) Applying functions, in this case we sum over a
range vector and aggregating by job
ACHTUNG!
Labels are transparent to Prometheus
whatever you define when exposing a metric, will be
available to query in the db.
Pulling metrics
● How do you expose those metrics?
● Exporters
● Language specific SDKs
/metrics
# HELP hash_seconds Time taken to create hashes
# TYPE hash_seconds histogram
hash_seconds_bucket{code="200",le="1"} 2
hash_seconds_bucket{code="200",le="2.5"} 2
hash_seconds_bucket{code="200",le="5"} 2
hash_seconds_bucket{code="200",le="10"} 2
hash_seconds_bucket{code="200",le="+Inf"} 2
hash_seconds_sum{code="200"} 9.370800000000002e-05
hash_seconds_count{code="200"} 2
Exporters
The community has contributed
writing exporters for pretty much
everything
https://prometheus.io/docs/instrumenting/exporters/
Alerting, Writing alerts: a simple example
ALERT <alert_name>
IF <condition>
FOR 5m
LABELS { severity="error" }
ANNOTATIONS {
summary = <summary>,
description = <description>,
}
Alert-Manager, Writing alerts: a real-world example
ALERT NODE_DISK_FREE_SPACE_ROOT_PARTITION_80
IF ((node_filesystem_size{fstype="rootfs"}-node_filesystem_avail{fstype="rootfs"})/node_filesystem_size{fstype="rootfs"})*100 > 80
FOR 5m
LABELS { severity="error" }
ANNOTATIONS {
summary = "Current disk usage on root partition is {{ $value }}% on node {{ $labels.instance }}",
description = "Current disk usage on root partition is {{ $value }}% on node {{ $labels.instance }}",
fixes = "Current disk usage on root partition is {{ $value }}% on node {{ $labels.instance }}",
}
Alert Dispatching
Job of the alert-manager is to dispatch
alerts to the right channel according to
their severity
Wrapping up
Thanks, questions?

More Related Content

PDF
End to-end monitoring with the prometheus operator - Max Inden
PPTX
Prometheus for Monitoring Metrics (Fermilab 2018)
PDF
Cloud Monitoring with Prometheus
PDF
Breaking the monolith
PDF
Getting Started Monitoring with Prometheus and Grafana
PDF
Efficient monitoring and alerting
PDF
An Introduction to Prometheus
PPT
Monitoring using Prometheus and Grafana
End to-end monitoring with the prometheus operator - Max Inden
Prometheus for Monitoring Metrics (Fermilab 2018)
Cloud Monitoring with Prometheus
Breaking the monolith
Getting Started Monitoring with Prometheus and Grafana
Efficient monitoring and alerting
An Introduction to Prometheus
Monitoring using Prometheus and Grafana

What's hot (20)

PDF
Better Monitoring for Python: Inclusive Monitoring with Prometheus (Pycon Ire...
PDF
Monitoring Kubernetes with Prometheus
PPTX
MeetUp Monitoring with Prometheus and Grafana (September 2018)
PDF
Prometheus (Microsoft, 2016)
PDF
Infrastructure & System Monitoring using Prometheus
PDF
Prometheus Overview
PDF
What is your application doing right now? An introduction to Prometheus
PDF
The history of Prometheus at SoundCloud
PDF
Prometheus: A Next Generation Monitoring System (FOSDEM 2016)
PDF
Microservices and Prometheus (Microservices NYC 2016)
ODP
Monitoring With Prometheus
PDF
Monitoring Kubernetes with Prometheus
PPTX
Prometheus grafana workshop
PPTX
OpenTelemetry For Operators
PDF
Prometheus + Grafana = Awesome Monitoring
PPTX
Prometheus - Open Source Forum Japan
PDF
Automated monitoring using grafana - DevOpsBKK 2018
PDF
Your data is in Prometheus, now what? (CurrencyFair Engineering Meetup, 2016)
PPTX
Prometheus for Monitoring Metrics (Percona Live Europe 2017)
PDF
Prometheus Introduction (InfraCoders Vienna)
Better Monitoring for Python: Inclusive Monitoring with Prometheus (Pycon Ire...
Monitoring Kubernetes with Prometheus
MeetUp Monitoring with Prometheus and Grafana (September 2018)
Prometheus (Microsoft, 2016)
Infrastructure & System Monitoring using Prometheus
Prometheus Overview
What is your application doing right now? An introduction to Prometheus
The history of Prometheus at SoundCloud
Prometheus: A Next Generation Monitoring System (FOSDEM 2016)
Microservices and Prometheus (Microservices NYC 2016)
Monitoring With Prometheus
Monitoring Kubernetes with Prometheus
Prometheus grafana workshop
OpenTelemetry For Operators
Prometheus + Grafana = Awesome Monitoring
Prometheus - Open Source Forum Japan
Automated monitoring using grafana - DevOpsBKK 2018
Your data is in Prometheus, now what? (CurrencyFair Engineering Meetup, 2016)
Prometheus for Monitoring Metrics (Percona Live Europe 2017)
Prometheus Introduction (InfraCoders Vienna)
Ad

Similar to Monitoring Cloud Native Applications with Prometheus (20)

PDF
Monitoring Kubernetes with Prometheus (Kubernetes Ireland, 2016)
PDF
Red Hat Forum Benelux 2015
PDF
The DevOps Paradigm
PDF
The DevOps paradigm - the evolution of IT professionals and opensource toolkit
PDF
Operator SDK for K8s using Go
PPTX
NuGet beyond Hello World - DotNext Piter 2017
PPTX
Prometheus Training
PDF
Kubernetes One-Click Deployment: Hands-on Workshop (Mainz)
PDF
Accelerate Your Automation Testing Effort using TestProject & Docker | Docker...
PDF
Cloud-native .NET Microservices mit Kubernetes
PPTX
Deploying R for Production - SRUG
PPTX
The Right Tools for IoT Developers – Dan Gross @ Eclipse IoT Day ThingMonk 2016
PPTX
Breaking the 2 Pizza Paradox with your Platform as an Application
PPTX
Spring Boot & Spring Cloud Apps on Pivotal Application Service - Daniel Lavoie
PDF
Red Hat and kubernetes: awesome stuff coming your way
PDF
When to use Serverless? When to use Kubernetes?
PDF
Eclipse Che - A Revolutionary IDE for Distributed & Mainframe Development
DOC
Balaji Resume
DOCX
Kunal bhatia resume mass
PDF
Combining formal and machine learning techniques for the generation of JML sp...
Monitoring Kubernetes with Prometheus (Kubernetes Ireland, 2016)
Red Hat Forum Benelux 2015
The DevOps Paradigm
The DevOps paradigm - the evolution of IT professionals and opensource toolkit
Operator SDK for K8s using Go
NuGet beyond Hello World - DotNext Piter 2017
Prometheus Training
Kubernetes One-Click Deployment: Hands-on Workshop (Mainz)
Accelerate Your Automation Testing Effort using TestProject & Docker | Docker...
Cloud-native .NET Microservices mit Kubernetes
Deploying R for Production - SRUG
The Right Tools for IoT Developers – Dan Gross @ Eclipse IoT Day ThingMonk 2016
Breaking the 2 Pizza Paradox with your Platform as an Application
Spring Boot & Spring Cloud Apps on Pivotal Application Service - Daniel Lavoie
Red Hat and kubernetes: awesome stuff coming your way
When to use Serverless? When to use Kubernetes?
Eclipse Che - A Revolutionary IDE for Distributed & Mainframe Development
Balaji Resume
Kunal bhatia resume mass
Combining formal and machine learning techniques for the generation of JML sp...
Ad

More from Jacopo Nardiello (7)

PDF
The Art of Cloud Native Defense on Kubernetes
PDF
Tales of the mythical cloud-native platform - Container day 2022
PDF
Kubernetes 101
PDF
Becoming a developer
PDF
Eventsourcing with PHP and MongoDB
PDF
Ultimate Introduction To AngularJS
PDF
Testing AngularJS
The Art of Cloud Native Defense on Kubernetes
Tales of the mythical cloud-native platform - Container day 2022
Kubernetes 101
Becoming a developer
Eventsourcing with PHP and MongoDB
Ultimate Introduction To AngularJS
Testing AngularJS

Recently uploaded (20)

PDF
Auditboard EB SOX Playbook 2023 edition.
PDF
CEH Module 2 Footprinting CEH V13, concepts
PDF
4 layer Arch & Reference Arch of IoT.pdf
PDF
Altius execution marketplace concept.pdf
PDF
Aug23rd - Mulesoft Community Workshop - Hyd, India.pdf
PDF
A hybrid framework for wild animal classification using fine-tuned DenseNet12...
PDF
Ensemble model-based arrhythmia classification with local interpretable model...
PDF
CXOs-Are-you-still-doing-manual-DevOps-in-the-age-of-AI.pdf
PPTX
Build automations faster and more reliably with UiPath ScreenPlay
PPTX
Internet of Everything -Basic concepts details
PDF
Advancing precision in air quality forecasting through machine learning integ...
PDF
LMS bot: enhanced learning management systems for improved student learning e...
PDF
Rapid Prototyping: A lecture on prototyping techniques for interface design
PDF
zbrain.ai-Scope Key Metrics Configuration and Best Practices.pdf
PPTX
Module 1 Introduction to Web Programming .pptx
PDF
AI.gov: A Trojan Horse in the Age of Artificial Intelligence
PDF
substrate PowerPoint Presentation basic one
PDF
Connector Corner: Transform Unstructured Documents with Agentic Automation
PDF
Co-training pseudo-labeling for text classification with support vector machi...
PDF
EIS-Webinar-Regulated-Industries-2025-08.pdf
Auditboard EB SOX Playbook 2023 edition.
CEH Module 2 Footprinting CEH V13, concepts
4 layer Arch & Reference Arch of IoT.pdf
Altius execution marketplace concept.pdf
Aug23rd - Mulesoft Community Workshop - Hyd, India.pdf
A hybrid framework for wild animal classification using fine-tuned DenseNet12...
Ensemble model-based arrhythmia classification with local interpretable model...
CXOs-Are-you-still-doing-manual-DevOps-in-the-age-of-AI.pdf
Build automations faster and more reliably with UiPath ScreenPlay
Internet of Everything -Basic concepts details
Advancing precision in air quality forecasting through machine learning integ...
LMS bot: enhanced learning management systems for improved student learning e...
Rapid Prototyping: A lecture on prototyping techniques for interface design
zbrain.ai-Scope Key Metrics Configuration and Best Practices.pdf
Module 1 Introduction to Web Programming .pptx
AI.gov: A Trojan Horse in the Age of Artificial Intelligence
substrate PowerPoint Presentation basic one
Connector Corner: Transform Unstructured Documents with Agentic Automation
Co-training pseudo-labeling for text classification with support vector machi...
EIS-Webinar-Regulated-Industries-2025-08.pdf

Monitoring Cloud Native Applications with Prometheus