we are facing now and then issues with user sessions that always lead back to subdirectories under /var/tmp/ondemand-nginx/xyz being removed (client_body disappearing is a “popular” one).
i only now realised this is most likely systemd-tmpfiles cleaning up things, and i was wondering what the recommendations are for this, in particular, tmpfiles completely ignore /var/tmp/ondemand-nginx
(it would be good if ood itself managed this by either settign this systemwide eg in /usr/lib/tmpfiles.d/ood.conf, or adding a per user exclude in eg /run/tmpfiles.d/ood-userxyz.conf each time the pun is started)
Could you test a change for us to see if we can override the defaults for “/var/tmp”? Something like this:
cat > /etc/tmpfiles.d/ondemand-nginx-tmp.conf <<EOF
d /var/tmp/ondemand-nginx 0755 root root - -
Z /var/tmp/ondemand-nginx - - - - -
EOF
If that kind of change resolves the issue then we can incorporate it into the OnDemand distributed tmpfiles.d files that would come with the RPM or Deb packages.
The Z line ensures SELinux contexts are applied upon creation. If you don’t use SELinux you don’t need it but when we ship the change in RPMs we have to include that line as it’s required for sites using SELinux and harmless to sites not using SELinux.
from the man page
“The age field only applies to lines starting with d, D, e, v, q, Q, C, x and X. If omitted or set to “-”, no automatic clean-up is done.”
so no trailing ‘-’ needed (also not for Z)
i’ll test this instead of the x, it’s a much better way than using ‘x’. i am assuming the /var/tmp/ondemand-nginx is configurable, but it doesn’t hurt to set this even unused (and admins using other location should take care/know better