I have a live log file called log.log and you want to catch some suitable patterns and values ββin it:
Example: log.log grows, and we look for lines with the pattern ResponseTime = VALUE, and we want to retrieve a consistent VALUE:
I carry out:
tail -F log.log | grep ResponseTime | cut -d = -f 2 | tr -d " "
And I expect to see
VALUE1
VALUE2
.. etc
But it does not work ... what should I do?
Thanks Namo
============
Thanks, it works now. I use: inotail -f log.log | stdbuf -oL grep ResponseTime | stdbuf -oL cut -d '=' -f 2 | stdbuf -oL tr -d ""
source
share