In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)05/31 Report--
This article focuses on "how to deal with Kubernetes monitoring", interested friends may wish to take a look. The method introduced in this paper is simple, fast and practical. Let's let the editor take you to learn "how to handle Kubernetes monitoring"!
If you are on the front line of DevOps, Kubernetes is rapidly becoming an important part of your production cloud environment. Because container choreography is critical to deploying, scaling, and managing containerized applications, monitoring Kubernetes needs to be an important part of the monitoring strategy.
The operation of the container environment is different from the traditional environment. Therefore, if you are monitoring applications and infrastructure, you need to consider how to monitor the container environment in which they are running. Here are 5 best practices for reference:
1. Centralize logs and metrics. Orchestrating your containerized services and workloads through Kubernetes will bring order, but keep in mind that your environment is still fragmented. If you centralize your logs and metrics, it will be much easier to deal with.
two。 Consider the ephemeral container. The beauty of container choreography is that it can easily start, stop, kill, and clean the container in a short time. However, monitoring them may not be easy. Even if the service is in progress, you still need to debug the problem and monitor cluster activity. The trick is to get it before the logs and metrics disappear. If you don't, your indicator looks more like the one on the left than the one on the right.
3. Simplify, simplify, simplify. For all mobile parts of the container environment (services, API, containers, orchestration tools), you need to monitor without introducing unnecessary complexity. Instead of using various monitoring agents to extend the container, you need to abstract monitoring and management tools from the content you monitor and manage. This will also help your engineers focus on building and delivering software rather than on the operation and maintenance delivery platform.
4. Clearly monitor each floor. You need to collect logs and monitor the various layers of the environment for errors, failures, and performance problems (pod\ container and controller manager). For example, you need to be able to troubleshoot pod, make sure the container is running properly, and collect runtime metrics in the controller manager.
5. Ensure data consistency across tiers. In order to debug quickly and accurately, you need to ensure data consistency across all layers in the container environment. Such as accurate timestamps, consistent units of measurement (such as milliseconds and seconds), and collecting a common set of metrics and logs in applications and components will help you troubleshoot and debug all layers quickly and accurately.
The best practice to accomplish these to-dos in a simple and straightforward way is to monitor the containers in the Kubernetes environment without touching the application containers. This can be achieved by introducing DaemonSet or sidecar into a Kubernetes environment that is juxtaposed with containerized services and includes logging and metrics collection agents. Deployment using this approach ensures consistency in data collection, minimizes changes required by the application container, and most importantly, eliminates the possibility of blind selection in a production environment.
Several implementation methods include:
1. Use DaemonSet with Fluentd logging agent (this will provide you with logging rather than metrics). If you already have a configured ELK cluster, this is an option.
two。 Use DaemonSet or sidecar with Prometheus metrics agents (CoreOS does a great job of integrating Prometheus and Kubernetes). Running Prometheus on your Kubernetes cluster will provide you with metrics detection, queries, and alerts.
3. Many metrics and performance monitoring tools, including Heapster, DataDog, cAdvisor, New Relic, Weave / VMware, also provide DaemonSet or sidecar options for Kubernetes monitoring.
At this point, I believe you have a deeper understanding of "how to deal with Kubernetes monitoring". You might as well do it in practice. Here is the website, more related content can enter the relevant channels to inquire, follow us, continue to learn!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.