CageFS makes sure that each user has his own /tmp directory, and that directory is the part of end-user's quota.
The actual location of the directory is $USER_HOME/.cagefs/tmp
Once a day, using cron job, CageFS will clean up user's /tmp directory from all the files that haven't been accessed during 30 days.
This can be changed by running:
Where 720 is the number of hours that the file had to be inaccessible to be removed.
By default this is done at 03:37 AM, but you can also force the clean up outdated files that match 'chosen period' of all user's /tmp directories without waiting for a job to be launched by cronjob. Just run:
$ cagefsctl --tmpwatch
The following paths will be cleaned as well:
/var/cache/php-eaccelerator (actual location $USER_HOME/.cagefs/var/cache/php-eaccelerator)
/var/cpanel/php/sessions/ea* (actual location $USER_HOME/.cagefs/var/cpanel/php/sessions/ea*)
You can configure tmpwatch to clean custom directories inside CageFS.
Create /etc/cagefs/cagefs.ini configuration file and specify tmpwatch_dirs directive as follows:
After that directories /dir1 and /dir2 inside CageFS will be cleaned automatically.
Note that actual location of those directories in real file system is $USER_HOME/.cagefs/dir1 and $USER_HOME/.cagefs/dir2.