电报输入尾插件语法

时间:2021-07-20 18:03:15

标签: telegraf-inputs-plugin

我正在尝试电报输入尾插件。我是第一次这样做,语法令人困惑。 请更正语法。日志文件是多行文本。

[[inputs.tail]]
## file(s) to tail:
files = ["/home/test.log"]
     
from_beginning = true
#name of the "Metric" (which I want to see in prometheus)
name_override = "test"
data_format = "grok"
grok_patterns = ["%{CUSTOM_LOG}"]
grok_custom_patterns = '’’CUSTOM_LOG %{TIMESTAMP_ISO8601} %{LOGLEVEL} %GREEDYDATA:logMessage:tag}'''
[[outputs.prometheus_client]]
## Address to listen on.
listen = "localhost:9273"
## Path to publish the metrics on.
path = "/metrics"

0 个答案:

没有答案
相关问题