mcelog 是 x86 的 Linux 系统上用来检查硬件错误,特别是内存和CPU错误的工具。
1.安装方式
yum install mcelog
2.配置mcelog后台运行
mcelog --daemon
3.查看:
cat /var/log/mcelog
mcelog日志
Hardware event. This is not a software error. MCE 0 CPU 1 BANK 8 MISC f95000051281 ADDR bf829a00 TIME 1447231148 Wed Nov 11 16:39:08 2015 MCG status: MCi status: Corrected error MCi_MISC register valid MCi_ADDR register valid MCA: MEMORY CONTROLLER RD_CHANNELunspecified_ERR Transaction: Memory read error Memory read ECC error Memory corrected error count (CORE_ERR_CNT): 1 Memory transaction Tracker ID (RTId): 81 Memory DIMM ID of error: 1 Memory channel ID of error: 1 Memory ECC syndrome: f950 STATUS 8c0000400001009f MCGSTATUS 0 MCGCAP 1c09 APICID 0 SOCKETID 0 CPUID Vendor Intel Family 6 Model 44
Mcelog相关文件
/dev/mcelog 设备文件 /var/log/mcelog messages日志文件 /etc/mcelog/mcelog.conf配置文件 /var/run/mcelog.pid
默认故障日志只记录在/var/log/mcelog,并不记录到系统日志中。
如果需要在系统日志中也体现,需修改/etc/mcelog/mcelog.conf文件,将前面#去掉,并保存。
# log output options # Log decoded machine checks in syslog (default stdout or syslog for daemon) #syslog = yes # Log decoded machine checks in syslog with error level #syslog-error = yes # Never log anything to syslog #no-syslog = yes # Append log output to logfile instead of stdout. Only when no syslog logging is active #logfile = filename
时间: 2024-10-05 23:07:53