问题原文
原帖链接 · xuhdev · CC BY-SA 3.0
The output of journalctl really looks messy without colors. Is it possible to add colors to its output? On my system it seems only important lines are highlighted. Even dmesg can output with color by adding the --color switch!
已采纳解答
原帖链接 · Mark Stosberg · CC BY-SA 3.0
The color support of journalctl is documented in man journalctl:
When outputting to a tty, lines are colored according to priority: lines of level ERROR and higher are colored red; lines of level NOTICE and higher are highlighted; other lines are displayed normally.
That's from systemd 229. As seen in the man page, There are no other built-in color controls for journalctl.
摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。
