当前位置:网站首页>The company needs to be monitored. How do ZABBIX and Prometheus choose? That's the right choice!
The company needs to be monitored. How do ZABBIX and Prometheus choose? That's the right choice!
2022-07-04 17:26:00 【Java technology stack】
source :cnblogs.com/xiaoyuxixi/p/12235979.html
New companies need to be monitored , The interview mentioned Prometheus It is the monitoring solution that the company needs , Of course, I chose to follow the trend .
The main thing I did before was Zabbix, Since the company needs Prometheus, There's no way out. , Only a good comparison , Get to know , After all, the skill is not too much .
But a little deeper , I realized Prometheus The advantages of , Summarize these two monitoring methods .
A brief history of the two monitoring tools
Prometheus
Kubernetes since 2012 Since its open source in, it has become an irresistible leader in scheduling and scheduling in the container field .
Kubernetes yes Google Borg Open source implementation of the system , Corresponding to this Prometheus It is Google BorgMon Open source implementation .
Prometheus By SoundCloud Open source monitoring and alarm system and time series database developed .
Literally ,Prometheus It consists of two parts , One is the monitoring and alarm system , The other is its own time series database (TSDB).
2016 year , from Google Sponsored Linux The original cloud foundation under the foundation (Cloud Native Computing Foundation) take Prometheus Included in its second largest open source project .
Prometheus It's also very active in the open source community , stay GitHub I have more than 20000 Star, And the system will have a small version update every two weeks , and Prometheus With its “ Elder martial brother ”Kubernetes All have their own aura of cloud origin , Nature can be friendly and cooperative .
Zabbix
Zabbix The official release date can be traced back to 2012 year , Time is better than Prometheus Four years earlier .
Zabbix By Alexei Vladishev Open source distributed monitoring system , It is an enterprise level distributed open source monitoring scheme . Software that can monitor various network parameters and server health and integrity . Use flexible notification mechanisms , Allows users to configure mail based alerts for almost any event .
In this way, we can quickly feed back the problems of the server . Based on stored data , Provides excellent reporting and data visualization capabilities .
Architecture contrast
Prometheus
Prometheus The basic principle of HTTP Periodically grab the status of the monitored component , Any component only needs to provide corresponding HTTP Interface and conform to Prometheus Defined data format , You can access it Prometheus monitor .
Prometheus Server Be responsible for grasping the target regularly Metrics( indicators ) The data is stored in local storage .
Prometheus One was adopted Pull( PULL ) How to get data , Not only does it reduce the complexity of the client , The client only needs to collect data , No need to know about the server side , And the server can be more convenient for horizontal expansion .
If the monitoring data reaches the alarm threshold Prometheus Server Will pass HTTP Send the alarm to the alarm module alertmanger, After the alarm is suppressed, the e-mail or webhook.
Prometheus Support PromQL Provide multi-dimensional data model and flexible query , By monitoring the indicators associated with multiple tag The way , Combine and aggregate the monitoring data in any dimension .
Zabbix
Zabbix from 2 Part of the form ,Zabbix Server With optional components Zabbix Agent.Zabbix Server Can pass SNMP,Zabbix Agent,ping, Port monitoring and other methods are provided for remote servers / Monitoring of network status , Data collection and other functions .
It can run in Linux,Solaris,HP-UX,AIX,Free BSD,Open BSD,OS X Platforms such as .
The core components are mainly Agent and Server, among Agent It is mainly responsible for collecting data and sending it to Server/Proxy, besides , To extend the monitor ,Agent It also supports the execution of custom scripts .
Server Mainly responsible for receiving Agent Monitoring information sent , And carry out summary storage , Trigger alarm, etc .
Zabbix Server Store the collected monitoring data in Zabbix Database in .Zabbix Database Support common relational database , If MySQL、PostgreSQL、Oracle etc. , The default is MySQL, And provide Zabbix Web page (PHP To write ) Data query .
Zabbix Because of the use of relational data to store temporal data , Therefore, when monitoring large-scale clusters, it is often difficult to save data .
So from Zabbix 4.2 Support for TimescaleDB Time series database , But the maturity is not high yet .
Comprehensive comparison
The table above , In terms of development language , In order to meet the needs of high concurrency and fast iteration , The development language of the monitoring system has gradually changed from C Language transfer to Go.
Have to say ,Go With simple syntax and elegant concurrency , stay Java Occupy business development ,C In the case of occupying the bottom development , Positioning middleware development requirements accurately , It is widely used in current open source middleware products .
In terms of system maturity ,Zabbix It's an old monitoring system :Zabbix Is in 1998 It came out in , The system function is relatively stable , Higher maturity .
and Prometheus It was born in recent years , Although the functions are still being updated iteratively , But on the shoulders of giants , In the architecture design, we have used the experience of many old monitoring systems for reference .
In terms of data storage ,Zabbix Using relational database to save , This greatly limits Zabbix Acquisition performance , and Prometheus Self developed a set of high performance time series database , stay V3 Version can reach tens of millions of data storage per second , Expand the storage of historical data by docking with the third-party time series database .
In terms of configuration complexity ,Prometheus There's only one core server Components , One command to start , Compared with , Other system configuration is relatively troublesome .
In terms of community activity , at present Zabbix More active , But it's basically domestic companies that participate in ,Prometheus In this respect, we have an absolute advantage , Although the community is not as active as , But by CNCF Support for , The later development is worth looking forward to .
From the perspective of container support , because Zabbix Appeared earlier , At that time, the container was not born , Naturally, the support for containers is also relatively poor .
and Prometheus Dynamic discovery mechanism , Not only can it support Swarm Native clusters , And support Kubernetes Monitoring of container clusters , It is the best solution for container monitoring at present .
summary
Taken together ,Zabbix More mature , It's faster to get started , But better integration leads to less flexibility , The bigger problem is , As the complexity of monitoring data increases ,Zabbix Further customization is very difficult , Even if customized , I can't use the data collected before ( Problems caused by relational databases ).
Prometheus Basically the opposite , It's more difficult to get started , But due to the high flexibility of customization , Data also has more aggregation possibilities , It is much less difficult to use after starting Zabbix.
But if you have accumulated technology in the traditional monitoring system , Or we should carefully consider changing the monitoring .
If you're monitoring a physical machine , use Zabbix No problem ,Zabbix In traditional monitoring system , Especially in server related monitoring , Take the absolute advantage of .
Even when the environment does not change very frequently ,Zabbix It's better than Prometheus Well done ; But if it's a cloud environment , Unless it is Zabbix Play very slippery , You can make all kinds of customization , Otherwise, or Prometheus Well , After all, that's what people do .
Prometheus It began to become the standard configuration of leading and container monitoring , And it will be widely used in the foreseeable future .
If it's just going to the monitoring system , Don't hesitate ,Prometheus It must be true .
Recent hot article recommends :
1.1,000+ Avenue Java Arrangement of interview questions and answers (2022 The latest version )
2. Explode !Java Xie Cheng is coming ...
3.Spring Boot 2.x course , It's too complete !
4. Don't write about the explosion on the screen , Try decorator mode , This is the elegant way !!
5.《Java Development Manual ( Song Mountain version )》 The latest release , Download it quickly !
I think it's good , Don't forget to like it + Forward !
边栏推荐
- [Acwing] 58周赛 4489. 最长子序列
- Is it safe for CITIC Securities to open an account online? Is the account opening fee charged
- Smart Logistics Park supply chain management system solution: digital intelligent supply chain enables a new supply chain model for the logistics transportation industry
- 中银证券网上开户安全吗?
- 新享科技发布小程序UniPro小优 满足客户移动办公场景
- How to implement a delay queue?
- Leetcode list summary
- What grade does Anxin securities belong to? Is it safe to open an account
- 上网成瘾改变大脑结构:语言功能受影响,让人话都说不利索
- 《吐血整理》保姆级系列教程-玩转Fiddler抓包教程(2)-初识Fiddler让你理性认识一下
猜你喜欢
太方便了,钉钉上就可完成代码发布审批啦!
Vb无法访问数据库stocks
Load test practice of pingcode performance test
Yanwen logistics plans to be listed on Shenzhen Stock Exchange: it is mainly engaged in international express business, and its gross profit margin is far lower than the industry level
Blood spitting finishing nanny level series tutorial - play Fiddler bag grabbing tutorial (2) - first meet fiddler, let you have a rational understanding
VB cannot access database stocks
NFT流动性市场安全问题频发—NFT交易平台Quixotic被黑事件分析
detectron2安装方法
Go development: how to use go singleton mode to ensure the security of high concurrency of streaming media?
CANN算子:利用迭代器高效实现Tensor数据切割分块处理
随机推荐
PyTorch深度学习快速入门教程
长城证券安全不 证券开户
C# 服务器日志模块
长城证券开户安全吗 证券账户怎么开通
Learn more about the basic situation of 2022pmp examination
太方便了,钉钉上就可完成代码发布审批啦!
leetcode刷题目录总结
Summary of tx.origin security issues
雨量预警广播自动化数据平台BWII 型广播预警监测仪
散列表
S2b2b solution for lighting industry: efficiently enable the industrial supply chain and improve the economic benefits of enterprises
开发者,MySQL专栏完更,助你轻松从安装到入门进阶
NFT liquidity market security issues occur frequently - Analysis of the black incident of NFT trading platform quixotic
将Opencv绘制图片显示在MFC Picture Control控件上
Rebalance operation in spark and its difference from repartition operation
NFT流动性市场安全问题频发—NFT交易平台Quixotic被黑事件分析
DataKit——真正的统一可观测性 Agent
ble HCI 流控机制
基于wifi控制的51单片机温度报警器
最大子数组与矩阵乘法