Reputation: 21
With CKAN, a new Beaker session is saved with each page load, AJAX request, and Flash message popup.
Is it really necessary to save so many sessions. Forgive my ignorance but I don't think I fully understand the benefit especially as it steadily fills the cache directory with many small files.
Is there any downside to periodically clearing out the directory?
Upvotes: 2
Views: 535
Reputation: 11
CKAN does not manage the beaker session files, you can find more info on this related issue https://github.com/ckan/ckan/issues/5294, where sessions are saved on db rather than on filesystem.
I added a line like this in my crontab file, to remove session files older than 24 hours:
0 * * * * ckan find /tmp/<YOUR_CKAN_NAME>/sessions/ -mmin +1440 -type f -print -exec rm {} \;
Upvotes: 1