当前位置:网站首页>Logstash discards log data that does not match the file name exactly
Logstash discards log data that does not match the file name exactly
2022-06-26 00:24:00 【zhangphil】
logstash Discard log data that does not exactly match the file name
A scene , If it is determined that this file needs to be accurately collected f:\x\data\2022-05-27-231259\my.txt The data in it , Not in this way data\yyyy-mm-dd-hhmmss\my.txt file , Never collect log data .
filter {
grok {
match => {
"[log][file][path]" => "/data/%{YEAR}-%{MONTHNUM}-%{MONTHDAY}-%{HOUR}%{MINUTE}%{SECOND}/my.txt"
}
tag_on_failure => [ "tag_failure" ]
}
if "tag_failure" in [tags]{
drop{
# discarded
}
}
}First of all, we need to follow log.file.path The full path of the file matches , Matching failure , Add one more tag_failure label , stay if If this is detected in logical judgment tag label , Just drop, This drop Will be discarded to the collected log line .
边栏推荐
- Why do we need to make panels and edges in PCB production
- EasyConnect连接后显示未分配虚拟地址
- ORA-01153 :激活了不兼容的介质恢复
- Function and principle of SPI solder paste inspection machine
- Smt贴片机工作流程
- What is micro service
- Redux workflow explanation + small examples
- dbca静默安装及建库
- Explain from a process perspective what happens to the browser after entering a URL?
- EBS R12.2.0升级到R12.2.6
猜你喜欢

10.4.1 données intermédiaires

Camkiia et gcamp6f sont - ils les mêmes?

How to deliver a shelter hospital within 48 hours?

Research and development practice of Kwai real-time data warehouse support system

【图像检测】基于高斯过程和Radon变换实现血管跟踪和直径估计附matlab代码

ValueError: color kwarg must have one color per data set. 9 data sets and 1 colors were provided

11.1.1、flink概述_flink概述
![[advanced ROS] Lecture 1 Introduction to common APIs](/img/25/85e8c55605f5cc999a8e85f0a05f93.jpg)
[advanced ROS] Lecture 1 Introduction to common APIs

CaMKIIa和GCaMP6f是一樣的嘛?

When installing PSU /usr/bin/ld:warning: -z lazload ignore
随机推荐
Run the test program using rknn-toolkit-lite2 for rk3568 development board
Rocket message storage
10.4.1、数据中台
机器视觉:照亮“智”造新“视”界
Xiaohongshu microservice framework and governance and other cloud native business architecture evolution cases
What are AOI, X-ray and ICT in SMT industry? What does it do?
SMT贴片加工pcba立碑现象的原因和解决方法
防抖和节流
farsync 简易测试
在同一台机器上部署OGG并测试
19c安装psu 19.12
Redis memory elimination mechanism
idea设置mapper映射文件的模板
Datetimeformatter and localdatetime
ValueError: color kwarg must have one color per data set. 9 data sets and 1 colors were provided
SMT操作员是做什么的?工作职责?
What do SMT operators do? operating duty?
快手实时数仓保障体系研发实践
no_expand和use_concat
10.4.1 data console