Rod*_*wer 40 linux boot centos logging
我想找到 Linux 写入所有引导消息的位置。你懂:
facility one [STARTED]
facility two [STARTED]
facility three [FAILED]
Run Code Online (Sandbox Code Playgroud)
我搜索了
find . -print0 | xargs -0 grep -i "words from boot messages"
Run Code Online (Sandbox Code Playgroud)
在 /var/log/ 中,但一无所获。
我有 CentOS 5.5。
例如在启动时我有:“确定 eth0 的 IP 信息......失败;没有链接存在。检查电缆?”
我不特别关心错误,但我找不到任何包含此错误的日志。
dmesg | grep "no link present"
也不返回任何东西。
小智 26
大多数引导消息都放在缓冲区中,您可以使用命令访问该缓冲区dmesg
。在大多数 Linux 发行版上,该输出也存储在
/var/log/dmesg.log
Run Code Online (Sandbox Code Playgroud)
您可以查看
tail -n 100 /var/log/dmesg.log
Run Code Online (Sandbox Code Playgroud)
这个解决方案肯定适用于 Debian 系统,但无论如何可能会有用。
为了存储启动期间显示的所有消息,您必须启动一个名为的服务bootlogd
,在下次重新启动后您可以在/var/log/boot
.
归档时间: |
|
查看次数: |
204837 次 |
最近记录: |