Colorize tail output

后端 未结 6 559
慢半拍i
慢半拍i 2021-01-30 07:27

I\'ve been trying to make tail a little more readable for server startups. My current command filters out most of the INFO and DEBUG messages from the startup:

         


        
6条回答
  •  一整个雨季
    2021-01-30 07:59

    I have been using a tool called grc for this for years. works like a charm. It comes with some quite good templates for many standard log outputs and formats and it is easy to define your own. A command I use often is

    grc tail -f /var/log/syslog
    

    It colorizes the syslog output so it is easy to spot errors (typically marked red.

    Find the tool here:

    https://github.com/garabik/grc

    (it is also available as package for most common linux flavours).

提交回复
热议问题