[SOLVED] /tmp and /var/tmp

Started by aa, June 21, 2015, 05:58:09 PM

Previous topic - Next topic
June 21, 2015, 05:58:09 PM Last Edit: July 02, 2015, 10:36:13 AM by franco
Just for consideration, FreeBSD uses /var/tmp for temporary objects
that expected to be living/survive between reboot.

I'm not sure about OPNsense, but pfSense symlinked /tmp to /var/tmp,
even on full install, which I think defeated the original purpose.

There is no symlink, but the rc system still clears /var/tmp at startup. I've removed the only usage of /var/tmp (unbound code), but I won't remove the /var/tmp wipe at startup right away.

Please also note that using MFS on /var will make /var/tmp not survive a reboot as well.

Tested this, and it looks good.

/var/tmp (as well as /var/run and /var/etc) are not being cleaned on boot anymore in time for 15.7: https://github.com/opnsense/core/commit/8e77138ab864a4fb9540804f7ac0dff45982864d