解决 Graylog 报错 Journal utilization is too high 消息积压修复
排查企业日志系统 Graylog 界面弹出 Journal utilization is too high (100.0%) 告警,分析 Elasticsearch 写入瓶颈与调优 processbuffer 线程。
问题现象
Graylog 顶部导航栏频繁弹出严重红色通知:
Journal utilization is too high
Journal utilization is currently 98.5%. You may encounter message drops
if the journal fills up completely.
节点吞吐监控中,Uncommitted messages 持续逼近上限。
触发根因
Graylog 内部采用基于磁盘的 Disk Journal 作为输入缓冲队列。当日志流入速度远大于处理和写入下游 Elasticsearch / OpenSearch 的速度时,未消费的日志在 Journal 堆积直至利用率达到 100%:
- Elasticsearch 集群写入发生瓶颈(如触发了 Disk Watermark 限写、或慢查询拖垮 JVM);
- Graylog 处理线程(Processbuffer Processors)分配过少。
解决步骤
1. 检查并调优下游 Elasticsearch 索引刷新速度
放宽索引刷新间隔,从默认 1 秒提升至 30 秒,极大提升批量吞吐:
curl -X PUT "http://localhost:9200/graylog_*_0/_settings" -H 'Content-Type: application/json' -d'{
"index" : {
"refresh_interval" : "30s"
}
}'
2. 在 server.conf 中调优处理器并发线程数
编辑 /etc/graylog/server/server.conf:
# 根据物理 CPU 核心数增加并行线程
processbuffer_processors = 8
outputbuffer_processors = 4
重启 Graylog 服务使配置生效:
sudo systemctl restart graylog-server
验证确认
在 Web 控制台观察 System / Overview 指标:
Journal utilization 迅速从 98% 骤降至 5% 以下,积压日志全部消化完毕。


