Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
cd /opt/apache/tomcat.1/conf/
sed -i 's/8005/8105/' server.xml
sed -i 's/8009/8109/' server.xml
sed -i 's/8080/8180/' server.xml
sed -i 's/8443/8543/' server.xml

Fix Tomcat

...

catalina.out Logging

Tomcat Logging has a bug where after if catalina.out reaches a large file size over logging over (question) (need to research) logging stops working. On top of that if your log file reaches Worse if over 2GB Tomcat will fail to not start and without reporting also not report any errors. Yes this is pretty crazy that this is not fixed.

Ubuntu

Edit the bin/catalina.sh,

Code Block
languagebash
cd /opt/apache/tomcat.1/bin/
 
# For Tomcat 8
 
# Turns off the creation of the generic file.
sed -i 's/touch "$CATALINA_OUT"/#touch "$CATALINA_OUT"/' catalina.sh
 
# Uses cronolog to rotate.
sed -i 's/>> "$CATALINA_OUT" 2>&1 "&"/2>&1 |/usr/bin/cronolog "$CATALINA_BASE/logs/catalina-%Y-%m-%d.out" &/' catalina.sh

This solution comes from SpringSource. Not super happy with this solution, so let me know if you find something better. I last looked May 2016.

Windows

Warning

TBC - Research and a solution needs to be found for this.

This article by SpringSource uses cronolog (they know Tomcat so well they created a variation with more Enterprise features looks promising").

Apache Tomcat's position is to not fix in the near future (we disagree as enough restarts will cause the problem with the log file) and the same article also provides some solutions too.

...