初始化提交

This commit is contained in:
2025-10-07 15:58:15 +08:00
commit 0e593caf99
378 changed files with 77890 additions and 0 deletions

View File

@@ -0,0 +1,37 @@
# 配置索引模板名称和模式
setup.template.name: "prod-sourcing-agents"
setup.template.pattern: "prod-sourcing-agents*"
setup.template.enabled: true
setup.ilm.enabled: true
#主配置文件加载子配置文件
filebeat.config.inputs:
enabled: true
path: /etc/filebeat/inputs.d/*.yml
reload.enabled: true
reload.period: 10s
#输出
output.elasticsearch:
hosts: ["http://106.53.194.199:9200"]
username: "admin"
password: "123456"
index: "%{[environment]}-%{[application]}-%{+yyyy.MM}" # 按月分割索引
bulk_max_size: 50 # 单批次传输最大文档数
worker: 1 # 并行工作线程数
timeout: 15s
# 日志记录
logging.level: info
logging.to_files: true
logging.files:
path: /var/log/filebeat
name: filebeat.log
keepfiles: 7
permissions: 0644
# 设置队列和内存使用
queue.mem:
events: 1024
flush.min_events: 512
flush.timeout: 10s

View File

@@ -0,0 +1,45 @@
- type: log
id: prod_lessie_sourcing_agents
enabled: true
paths:
- /data/webapps/prod_lessie_sourcing_agents/logs/lessie_sourcing_agents_latest.log
follow_symlinks: true
harvester_limit: 1
fields:
application: lessie # 自定义字段,标识应用名称
log_type: lessie.log # 自定义字段,标识日志类型
environment: prod # 自定义字段,标识机器环境名称
instance: weblessie-server # 自定义字段,标识机器名称
fields_under_root: true
multiline.pattern: '^\d{4}-\d{2}-\d{2} \d{2}:\d{2}:\d{2}'
multiline.negate: true
multiline.match: after
ignore_older: 24h # 忽略旧日志文件(避免处理已归档的日志)
scan_frequency: 10s # 定期扫描新文件的频率
clean_inactive: 25h # 清除超过一天未更新的文件
close_inactive: 5m # 文件超过5分钟无更新则关闭
close_renamed: true # 处理被重命名的文件
start_position: beginning # 从文件的开头读取
- type: log
id: prod_lessie_sourcing_agents
enabled: true
paths:
- /data/webapps/prod_lessie_sourcing_agents/logs/lessie_sourcing_agents_latest.log
follow_symlinks: true
fields:
application: lessie # 自定义字段,标识应用名称
log_type: lessie.log # 自定义字段,标识日志类型
environment: prod # 自定义字段,标识机器环境名称
instance: weblessie-server # 自定义字段,标识机器名称
fields_under_root: true
ignore_older: 24h # 忽略旧日志文件(避免处理已归档的日志)
scan_frequency: 10s # 定期扫描新文件的频率
clean_inactive: 25h # 清除超过一天未更新的文件
close_inactive: 5m # 文件超过5分钟无更新则关闭
close_renamed: true # 处理被重命名的文件
start_position: beginning # 从文件的开头读取