Change logs catalina.out properties

Document ID : KB000017168
Last Modified Date : 14/02/2018
Show Technical Document Details
Question:

How do I change the log size of catalina.out?

Environment:
Portal 3.5
Answer:

Please see the steps below. 

*** LOG ROTATE STEPS **** 

1. SSH to the root prompt of the API Portal 

2. Create the file ?/etc/logrotate.d/levelPortal? with the below contents; this will rotate the catalina log file once it reaches 100MB 

/opt/Deployments/lrs/server/logs/catalina.out { 
copytruncate 
size 100M 
rotate 10 
compress 
missingok 


3. Run the following command: 
chmod 644 /etc/logrotate.d/levelPortal 

4. You can force the log rotation by running this command: 
logrotate -f /etc/logrotate.d/levelPortal