当前位置:网站首页>How Filebeat ensures that the log file is still correctly read when the log file is split (or rolled)
How Filebeat ensures that the log file is still correctly read when the log file is split (or rolled)
2022-07-30 00:13:00 【Sadness from the ages】
During peak traffic periods, there will always be missing log collection. After investigation, the matching rules are not appropriate, and the scan_frequency defaults to 10s. In these 10s, multiple files may be missed, resulting in missing collection.close_inactive
This parameter specifies how long to close the file handle when the monitored file has not changed.The official recommendation is to set this parameter to a value larger than the maximum file update interval.For example, the file is updated every 5s at most, then set it to 1min.The default value is 5min.
scan_frequency
This parameter specifies how often (time interval) Filebeat searches for new files.When a new file is found to be created, Filebeat will start another harvester for it to monitor.The default is 10s.
Combining the above two mechanisms, when logback completes log cutting (ie renaming), the old harvester is still monitoring the renamed log file, but since the file will not be updated, it will be closed at the close_inactive time.After closing the harvester of this file.When the scan_frequency time expires, Filebeat will find that a new file appears in the directory, so it starts the harvester for the file to monitor.This ensures that the data can be transmitted without loss or weight when the log is cut.(Not heavy is achieved by saving the offset for each log file)
边栏推荐
- From the perspective: the interviewer interview function test engineer mainly inspects what ability?
- News text classification
- Minesweeper game in c language
- 2022/7/29 考试总结
- How to increase account weight?3 ways to operate your own media to help you get more revenue
- Worthington dissociating enzyme: detailed analysis of neutral protease (dispase)
- Worthington's tried and tested cell isolation system protocols
- 新媒体运营必备的4个热点查询网
- rk-boot framework combat (1)
- Worthington弹性蛋白酶&透明质酸酶简介
猜你喜欢

自媒体短视频标题怎么写?3个爆款标题,让你的视频收获更多流量

【集训DAY16】KC ‘ s Stars【dfs】

抖音短视频流量获取攻略,掌握好这些一定可以出爆款

自媒体人如何打造出爆文?这3种类型的文章最容易爆

消息中间件解析 | 如何正确理解软件应用系统中关于系统通信的那些事?

Based on TNEWS 'today's headline news in Chinese short text classification

Worthington细胞分离技术丨基本原代细胞分离方法和材料

指令集数据产品如何设计和实现报表协同系统——基于指令集物联网操作系统的工业协同制造项目开发实践

The go language (functions, closures, defer, panic/recover, recursion, structure, json serialization and deserialization)

How to increase account weight?3 ways to operate your own media to help you get more revenue
随机推荐
【云原生Kubernetes】二进制搭建Kubernetes集群(中)——部署node节点
Sentinel入门
【集训DAY16】KC ‘ s Stars【dfs】
自媒体短视频标题怎么写?3个爆款标题,让你的视频收获更多流量
二维数组的查找
【经验】经验总结-经验教训
At the age of 29, I was fired from a functional test. Can't find a job after 2 months of interviews?
Filebeat如何保证在日志文件被切割(或滚动rolling)时依然正确读取文件
【Incubator DAY18】Interesting exchange【Simulation】【Math】
【集训DAY16】KC‘s Can 【动态规划】
How do we-media people create explosive articles?These 3 types of articles are most likely to explode
绘制几何图形
新闻文本分类
Worthington's tried and tested cell isolation system protocols
Paper Intensive Reading - YOLOv3: An Incremental Improvement
Elephant Swap: Provide arbitrage space in the crypto market with ePLATO
外包干了五年,废了...
多商户商城系统功能拆解18讲-平台端商家售后
cp强制覆盖与不覆盖拷贝方法
what is a .pro file in qt