[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: 'strictatime' vs. 'relatime' for /tmp



On Wed, Jul 30, 2014 at 4:12 AM, Andrei POPESCU
<andreimpopescu@gmail.com> wrote:
>
> When mounting a tmpfs on /tmp systemd sets 'strictatime'. I was
> wondering whether this is really needed. Does anybody know of software
> that would break with 'relatime' (the default) or even 'noatime'?
>
> I'd be happy to RTFM if anybody can point me to the relevant FM.

Perhaps because it cleans "/tmp" every 10 days (possibly not on Debian
but I only have access to Fedora at the moment) and therefore needs
files' atime fully updated.




/lib/systemd/system/systemd-tmpfiles-clean.timer

[Unit]
Description=Daily Cleanup of Temporary Directories
Documentation=man:tmpfiles.d(5) man:systemd-tmpfiles(8)

[Timer]
OnBootSec=15min
OnUnitActiveSec=1d




/lib/systemd/system/systemd-tmpfiles-clean.service

[Unit]
Description=Cleanup of Temporary Directories
Documentation=man:tmpfiles.d(5) man:systemd-tmpfiles(8)
DefaultDependencies=no
Conflicts=shutdown.target
After=systemd-readahead-collect.service
systemd-readahead-replay.service local-fs.target time-sync.target
Before=shutdown.target

[Service]
Type=oneshot
ExecStart=/usr/bin/systemd-tmpfiles --clean
IOSchedulingClass=idle




/lib/tmpfiles.d/tmp.conf

# Clear tmp directories separately, to make them easier to override
d /tmp 1777 root root 10d
d /var/tmp 1777 root root 30d

# Exclude namespace mountpoints created with PrivateTmp=yes
x /tmp/systemd-private-%b-*
X /tmp/systemd-private-%b-*/tmp
x /var/tmp/systemd-private-%b-*
X /var/tmp/systemd-private-%b-*/tmp


Reply to: