Lucee stderr log file huge, can I set a limit?

Hi everyone,

On Windows Server 2022 64/bit running Lucee 5.4.3.2, Apache Tomcat/9.0.78, Java 11.0.20 (Eclipse Adoptium) 64bit

Our lucee stderr file grows all the time to over 1TB in size, filling all the space in our disk every so often. Is there a way to auto-prune the old contents of that file so that only the new content shows and it does not go over a certain fixed size limit? (say, 200MB).

Any help would be appreciated.

JE

lognamesuchasCatalinalog.log > nul

You can just Null it on windows, it takes the stress off IOPs

If you want a specific file size, you would have to configure tomcats logging.

in tomcatroot\conf\logging.properties

add or make sure exists

handlers = 1catalina.org.apache.juli.FileHandler, 2localhost.org.apache.juli.FileHandler, manager.org.apache.juli.FileHandler, 4host-manager.org.apache.juli.FileHandler, context.org.apache.juli.FileHandler
#Add the following
catalina.org.apache.juli.FileHandler.limit=250000000 # 250 MB limit
catalina.org.apache.juli.FileHandler.count=4 # Maximum number of files to keep

save the file, restart the service
donate 20 bucks to lucee.org if you found this helpful.