For data maintenance, the cleanup script can be run to move logs and process archives to a backup location and remove the old ones from the server. This script has been updated to account for Tomcat logs with the logsv2 option.
logsv2
Logs that are cleaned up when using the logsv2 option include the following:
To run the Cleanup Script, follow the steps in the documentation. Below are example use cases of the logsv2 option:
To move files to a backup directory and keep the five most recent versions of log files, run the following:
<APPIAN_HOME>/server/_scripts/cleanup.sh logsv2 -target <Backup_Location> -keep 5
To delete files and keep the 30 most recent versions of log files, run the following:
<APPIAN_HOME>/server/_scripts/cleanup.sh logsv2 -delete -keep 30
To run the debug flag with the cleanup script, run the following:
<APPIAN_HOME>/server/_scripts/cleanup.sh logsv2 -target <Backup_Location> -keep 30 -debug
Note: The -debug flag enables debugging information helpful for troubleshooting.
-debug
Additionally, the -logDir flag can be used to point to a different log directory rather than the default logs folder.
-logDir
This article applies to all self-managed versions of classic Appian.
Last Reviewed: March 2024