tomcat 日期切分

https://www.cnblogs.com/t-road/p/6837221.html

if [ "$1" = "-security" ] ; then
    ......
    org.apache.catalina.startup.Bootstrap "$@" start 2>&1 \
      | /usr/local/cronolog/sbin/cronolog "$CATALINA_BASE"/logs/catalina.%Y-%m-%d.out >> /dev/null &
else
    ......
    org.apache.catalina.startup.Bootstrap "$@" start 2>&1 \
      | /usr/local/cronolog/sbin/cronolog "$CATALINA_BASE"/logs/catalina.%Y-%m-%d.out >> /dev/null 

这个里面的
usr/local/cronolog要是自己配置的地址
./configure --prefix=/usr/local/cronolog //按自己需要指定安装路径,或不指定

 

 

上一篇:如何控制Tomcat的catalina.out的大小


下一篇:linux taomcat catalina.out 日志分割