Linux动态监控tomcat日志,将新的数据输出到指定文件

tail -f catalina.out >> 'test.log'
清空文件内容:>'test.log'

编程技巧