tail + grep

一个使用场景

  1. tail -f 监视文件的内容
  2. grep 关注其中特定的行

tail + grep

tail -f -c +0 some.log | fgrep hello
  • -f 持续输出文件的新内容
  • -c +0 从文件的开头开始