All DLXS classes use session management, with session files that need to be occasionally purged. The managesession.pl script is supplied as a tool to help with this maintenance task.
The syntax of the managesessions.pl program options is:
managesessions.pl [-a age] -m [clean|list] -s [CSV|MySQL]where
- -a signifies the maximum age of session inactivity in minutes
- -m signifies the mode
- clean will remove sessions that exceed the specified age
- list will simlpy list the sessions that exceed the specified age
- -s signifies the data store
- CSV indicates a file-based (CSV) data store. Obsolete as of DLXS release 13.
- MySQL indicates a MySQL-based data store
You must add a crontab entry to clear the session files. For example, the following crontab entry will run hourly, removing data for sessions that have not been accessed in 120 minutes. Replace the string
$DLXSROOT with the DLXSROOT for your installation.
SESSION_AGE value is 120 minutes.
# # clear old web sessions from DLXS sessions database 51 * * * * (DLXSROOT=$DLXSROOT; export DLXSROOT; $DLXSROOT/bin/managesessions.pl -m clean -a 120 -s File)
DLXS uses a cache directory (
$DLXSROOT/web/cache) for dynamically converted page images, style sheets, and other files that are more efficiently served in a static form. To absolutely maximize performance, you may choose to configure your systems with enough disk space to keep all converted page images, and develop a local script to clear other sorts of files from the cache, but generally, you should add a crontab entry to clear the cache on a regular basis. We recommend that you add the following line (replacing the string
$DLXSROOT with the DLXSROOT for your installation) to the crontab of any non-root user who has write privilege in the cache directory. It will remove cached files that have not been accessed in a number of days (seven, by default). See the comments within the script if you wish to change the default cache file lifetime for your installation.
# # clear web cache 23 1 * * * $DLXSROOT/bin/managecache.sh