Container monitoring tools can help developers and DevOps teams monitor activity of running containers, collect logs from containers, and analyze data to provide observability and insight into container performance.
A critical element of container monitoring is that containers are transient resources. In other words, they are destroyed when the operation is complete or the application needs to scale down. Therefore, log data must be continuously collected and moved to a central location to prevent data loss. Container monitoring solutions provide visibility and real-time insight into these highly dynamic container environments.
This is part of a series of articles about container monitoring.
In this article:
In this article
Lumigo is a cloud native observability tool, purpose-built to navigate the complexities of microservices. Through automated distributed tracing, Lumigo stitches together the many components of a containerized application and tracks every service in a request. When an error or failure occurs, users will see not only the impacted service, but the entire request in one visual map so you can easily understand the root cause, limit impact and prevent future failures.
With deep debugging data in to applications and infrastructure, developers have all the information they need to monitor and troubleshoot their containers with out any of the manual work:
Get started with a free trial of Lumigo for your microservice applications
License: Apache
GitHub: https://github.com/prometheus/prometheus
Prometheus is a mature and very popular open source tool that performs monitoring for dynamic containerized environments. It is one of only a few projects that received Graduated status from the Cloud Native Computing Foundation (CNCF) program. Prometheus was originally created and open sourced by SoundCloud to simplify the process of retrieving numerical metrics from a given metric endpoint and organize them into a time series.
Prometheus has three main components:
Prometheus has become the industry standard for monitoring cloud-native architectures. It is known for its simple service discovery, ease of use, powerful alerting capabilities, and strong integration with Kubernetes.
However, many in the industry find the Prometheus polling architecture to be problematic. Every metric endpoint must be accessible from the Prometheus server. However, Prometheus does provide a push gateway for pushing metrics to the server instead of polling them.
License: Apache
GitHub: https://github.com/google/cadvisor
Google’s Container Advisor (cAdvisor) is an open source tool for monitoring Docker containers. It is a runtime daemon that collects, aggregates, and exports resource usage and performance data for target containers.
cAdvisor is useful for monitoring resource isolation parameters, historical resource usage, and generating historical data histograms. This data is stored globally for each container for easy analysis of historical performance.
The cAdvisor build is provided as an image that can be installed on a Docker host. cAdvisor provides two interfaces:
License: GNU 3
GitHub: https://github.com/grafana/grafana
Grafana is an open source metric analysis and visualization suite. It lets you build custom dashboards with data from multiple sources, including Prometheus, Elasticsearch, MySQL, Postgres, and Redis. Grafana also has its own alert system and role-based software access control (RBAC) system.
Grafana is well known to Prometheus users, due to its ability to effectively visualize metrics stored in Prometheus. Grafana has dozens of custom dashboards, some official and many created by the community, built for many types of data sources. This makes it easy for users to set up dashboards and start monitoring a variety of metrics.
License: Apache
GitHub: https://github.com/elastic/elasticsearch
Elasticsearch is an open source search engine based on the Lucene library. It provides a distributed, multi-tenant full-text search engine with an HTTP web interface and schemaless JSON documents. Elasticsearch was written in Java, and makes it easy to store, search, and analyze data at scale.
Kibana is a free, open user interface for visualizing Elasticsearch data and exploring the Elastic Stack. It does everything from tracking query load to understanding how requests flow through an application.
Kibana’s core comes with basic visualizations like histogram, line, pie and sunburst, and lets you search any document.
Put together, Elasticsearch and Kibana provide a flexible backend for monitoring Docker container logs. However, like Prometheus and Grafana, they require initial setup and configuration steps, as well as ongoing upgrades and maintenance. This can be time consuming, especially if you are not familiar with these tools.
License: Apache
GitHub: https://github.com/jaegertracing/jaeger
Jaeger is an end-to-end distributed tracing solution, open sourced by Uber Engineering, and currently in Incubation status in the CNCF. It allows you to monitor and troubleshoot transactions in complex distributed systems.
The main challenge addressed by Jaeger is the difficulty of observability in modern microservices architectures. For example, when a service fails, it is not known how requests travel between services over the network to complete a single business transaction—this makes debugging very difficult.
Jaeger uses tracing to enable root cause analysis, performance and latency optimization, and distributed transaction monitoring. It comes with Istio, a popular open source service mesh solution, out of the box.
There are several open source and commercial container observability tools available. Most of them can effectively log, monitor, and trace containerized environments. The main difference between them is the level of effort required to set up, configure, and maintain the solution.
Here are key considerations for choosing the right monitoring tool:
Get started with a free trial of Lumigo for your microservice applications