3.7 KiB
【E21现场】国家中心NZ服务器10.224.11.3-6硬盘/分区使用率接近80%
| ID | Creation Date | Assignee | Status |
|---|---|---|---|
| OMPUB-875 | 2023-03-29T16:16:49.000+0800 | 史振东 | 已关闭 |
查询过去24小时告警,发现NeZha Server3频繁出现Disk_usages_sysroot和NZ Disk space告警;
后续查询了国家中心的8台NZ服务器,发现10.224.11.3-6,这四台硬盘/分区使用率已接近80%;
最终定位到/var/log/messages文件占用较大,而且目前还在持续频繁写入日志,详情如下:
10.224.11.3:79% messages 84G
10.224.11.4:68% messages 51G
10.224.11.5:80% messages 237G
10.224.11.6:72% messages 208G
附件包含以下内容:
告警截图,以及这四台服务器硬盘空间占用情况、messages文件大小截图和对应服务器的messages文件部分内容截图。shizhendong commented on 2023-03-29T16:24:56.724+0800:
通过执行 ll /var/log -hl | grep messages 命令,发现 /var/log 目录下只存在一个 message 文件,logrotate 未生效 !11.png!
shizhendong commented on 2023-03-29T16:47:19.384+0800:
通过检查其他服务器,确认 10.224.11.3-10 八台服务器存在该问题,均为 National Center NZ Server !33.png!
shizhendong commented on 2023-03-30T09:20:27.331+0800:
排查步骤:
- 检查其他日志是否被轮播
ll /var/log
- 检查 rsyslog 状态
systemctl status rsyslog
- 检查 cron 状态
systemctl status crond.service
- 检查 logrotate syslog
logrotate -d -f /etc/logrotate.d/syslog
- 查看 logrotate 状态
cat /var/lib/logrotate/logrotate.status
其中检查发现 cron 服务未开启,由于 Logrotate 是基于 crond.service 实现日志轮播的,所以造成了该问题
注:centos 默认不开启 crond.service(开机不自启)
现已将 10.224.11.3-6 都执行启动了 crond 并开机自启,并手动对日志进行轮播,持续观察中
Attachments
Attachment: 11.png
Attachment: 33.png
Attachment: 微信图片_20230329110851.png
Attachment: 微信图片_20230329110902.png
Attachment: 微信图片_20230329110906.png
Attachment: 微信图片_20230329110913.png
Attachment: 微信图片_20230329110917.png
Attachment: 微信图片_20230329110920.png
Attachment: 微信图片_20230329110925.png
Attachment: 微信图片_20230329110928.png









