The /var/tmp directory is made available for programs that require temporary ﬁles or directories that are preserved between system reboots. Therefore, data stored in /var/tmp is more persistent than data in /tmp.
Files and directories located in /var/tmp must not be deleted when the system is booted. Although data stored in /var/tmp is typically deleted in a site-speciﬁc manner, it is recommended that deletions occur at a less frequent interval than /tmp.
I’m not aware of any Linux distributions that automatically clean
/var/tmp. IMO, the applications that use
/var/www cleanup after themselves in some reasonable manner.
All RHEL-based distros clean
/var/tmp of files older than 30 days. I don’t know about other distros. Look for a cron entry that invokes tmpwatch. On Fedora/RHEL it is
/etc/cron.daily/tmpwatch. It has a line like:
/usr/sbin/tmpwatch "$flags" 30d /var/tmp
/usr/sbin/tmpwatch 720 /var/tmp
(720 hours = 30 days)