Ask Questions and Find Answers
Important:
Ask is now read-only. You can review any existing questions and answers, but not add anything new.
But - don't panic! While ask is no more, we've replaced it with discuss - the new Liferay Discussion Forum! Read more here here or just visit the site here:
discuss.liferay.com
Liferay Tomcat Bundle Remove stdout log file in the Tomcat directory
Hi All,
I am trying to remove the stdout log file created in the folder LiferayHome/tomcat-9.0.75/logs/liferayuat-stdout.2024-02-28 as this file is not rolling daily basis and all logs are writtent to one file. Also we already have the daily log files in the LiferayHome/logs folder.
I am running Liferay bundle as a windows service, not from command prompt. So this file will get larger after deploying to production and we can't delete without stopping tomcat bundle.
I have tried configuring LiferayHome/tomcat-9.0.75/conf/logging.properties by removing handler java.util.logging.ConsoleHandler as mentioned in the below URL and tried setting java.util.logging.ConsoleHandler.level = OFF, But not worked for me.
https://liferay.dev/blogs/-/blogs/improve-your-liferay-and-tomcat-logging
Could somone please share how we can remove this stdout log file.
Does this stdout log file deleted automatically after 90 days?
Thanks in advance
I have set swallowOutput to true in the tomcat/conf/Catalina/localhost/ROOT.xml Context XML and now the default thread logs are not adding to the stdout file.
Only logs from other threads are getting added to this file
Make sure your own code is not using System.out.println or similar. Rather use proper logging.