35 lines
970 B
Plaintext
35 lines
970 B
Plaintext
# Fluent Bit 主配置(边缘节点日志采集 → ClickHouse)
|
||
# 生产环境将 INPUT 改为 tail 采集 /var/log/edge/edge-node/*.log
|
||
|
||
[SERVICE]
|
||
Flush 5
|
||
Log_Level info
|
||
Parsers_File parsers.conf
|
||
storage.path /var/lib/fluent-bit/storage
|
||
storage.sync normal
|
||
storage.checksum off
|
||
storage.backlog.mem_limit 128MB
|
||
|
||
@INCLUDE clickhouse-upstream.conf
|
||
|
||
[INPUT]
|
||
Name tail
|
||
Path /var/log/edge/edge-node/*.log
|
||
Tag app.logs
|
||
Refresh_Interval 5
|
||
Read_from_Head false
|
||
DB /var/lib/fluent-bit/logs.db
|
||
Mem_Buf_Limit 128MB
|
||
Skip_Long_Lines On
|
||
|
||
[OUTPUT]
|
||
Name clickhouse
|
||
Match *
|
||
Upstream ch_backends
|
||
Table logs_ingest
|
||
Http_User ${CH_USER}
|
||
Http_Passwd ${CH_PASSWORD}
|
||
json_date_key timestamp
|
||
json_date_format epoch
|
||
Retry_Limit 10
|