linux tomcat catalina.out bak 备份

  

cp catalina.out catalina.out.bak_`date +%Y%m%d_%H%M%S`
The command above will generate file with format fileName: catalina.out.bak_20200219_215651
Clear the content of log file:
echo "" > catalina.out

相关推荐