Sample Header Ad - 728x90

How to highlight the whole log-line in color with multitail

1 vote
1 answer
6456 views
I'm trying to use multitail to tail logs with color highlights. I defined a custom color scheme in multitail.conf, something like this: colorscheme:my-color cs_re:red:^\[E cs_re:yellow:^\[W cs_re:magenta:^\[D cs_re:green,,bold:All session(s) filled for.* What I want to achieve with each line: 1. Color **the whole log-line** Red if it starts with string '[E' 2. Color ................................ Yellow if it starts with string '[W' 3. Color ................................ Magenta if it starts with string '[D' 4. Color ................................ Green if the line contains the string 'All session(s) filled for' Unfortunately, none of the above is happening for me. For the first 3, it does color correctly the substring (e.g. '[E', '[W', etc) but not the whole log-line. In the last case, it doesn't color at all. I also want to color the whole line by matching the third character of a line, e.g. color it Blue if the third character is 'A', how should I do this reliably with multitail?
Asked by MLister (217 rep)
Apr 12, 2013, 09:25 PM
Last activity: Apr 12, 2013, 09:53 PM