引入lumberjack和fluentbit自动分发

This commit is contained in:
robin
2026-02-13 22:36:17 +08:00
parent c6da67db79
commit e9093baffb
47 changed files with 4589 additions and 317 deletions

View File

@@ -47,6 +47,32 @@ flowchart TD
- `/var/log/edge/edge-node/*.log`
3. ClickHouse 已建表:`logs_ingest`(见 `deploy/fluent-bit/README.md`)。
### 3.3 本地日志轮转(默认开启)
从当前版本开始EdgeNode / EdgeDNS 使用内建 `lumberjack` 轮转,不再依赖系统 `logrotate`。
默认值:
- `maxSizeMB=256`
- `maxBackups=14`
- `maxAgeDays=7`
- `compress=false`
- `localTime=true`
可在策略 `file.rotate` 中配置,例如:
```json
{
"path": "/var/log/web-access-${date}.log",
"autoCreate": true,
"rotate": {
"maxSizeMB": 256,
"maxBackups": 14,
"maxAgeDays": 7,
"compress": false,
"localTime": true
}
}
```
---
## 4. 三种目标模式怎么配