Bug#783509: systemd: /tmp purged on every reboot

Andreas Metzler ametzler at bebt.de
Mon Apr 27 18:15:38 BST 2015


On 2015-04-27 Michael Biebl <biebl at debian.org> wrote:
> Am 27.04.2015 um 18:15 schrieb Andreas Metzler:
> > Package: systemd
> > Version: 215-17
> > Severity: normal

> > I am not sure for how long but I guess less than two months (jessie),
> > systemd has started purging my /tmp on every reboot, although I have
> > these settings:
[...] 
> Or maybe, have you tmpfs-on-tmp enabled?

> What's the output of systemctl status tmp.mount ?

Hello,

thanks for the help, that is exactly what seems to have happened:

--------------------------------------
ametzler at argenau:~$ systemctl status tmp.mount
● tmp.mount - Temporary Directory
   Loaded: loaded (/lib/systemd/system/tmp.mount; disabled)
   Active: active (mounted) since Mon 2015-04-27 17:07:24 CEST; 1h 33min ago
    Where: /tmp
     What: tmpfs
     Docs: man:hier(7)
           http://www.freedesktop.org/wiki/Software/systemd/APIFileSystems
  Process: 178 ExecMount=/bin/mount -n tmpfs /tmp -t tmpfs -o mode=1777,strictatime (code=exited, status=0/SUCCESS)

Warning: Journal has been rotated since unit was started. Log output is incomplete or unavailable.
ametzler at argenau:~$ mount | grep ' /tmp'
tmpfs on /tmp type tmpfs (rw)
ametzler at argenau:~$ systemctl list-dependencies --reverse tmp.mount
tmp.mount
● ├─chroots-amd64\x2djessie-tmp.mount
● ├─chroots-amd64\x2dwheezy-tmp.mount
● ├─chroots-etch-tmp.mount
[...]
● └─chroots-wheezy-tmp.mount
--------------------------------------

The reverse dependencies are just bind-mounts:
ametzler at argenau:~$ grep /wheezy.*tmp /etc/fstab
/tmp            /chroots/wheezy/tmp        none    bind,auto        0       0

It looks like this started on April 5 (journalctl history goes back to
2014):
ametzler at argenau:~$ journalctl --since=2015-03-15 | grep tmp.mount
Apr 05 15:20:55 argenau systemd[1]: tmp.mount: Directory /tmp to mount over is not empty, mounting anyway.
Apr 06 13:38:42 argenau systemd[1]: tmp.mount: Directory /tmp to mount over is not empty, mounting anyway.
[...]

/var/log/apt/history.log marks the upgrade to systemd 215-14 from -12 as
triggering point:
8X--------------------------------------
End-Date: 2015-04-04  13:09:01

Start-Date: 2015-04-05  07:39:52
Commandline: apt --option APT::Get::Purge=true full-upgrade
Upgrade: libcap2:i386 (2.24-7, 2.24-8), libudev1:i386 (215-12, 215-14), systemd-
sysv:i386 (215-12, 215-14), systemd:i386 (215-12, 215-14), libsystemd0:i386 (215
-12, 215-14), libcap2-bin:i386 (2.24-7, 2.24-8), udev:i386 (215-12, 215-14), lib
gudev-1.0-0:i386 (215-12, 215-14)
End-Date: 2015-04-05  07:40:28

Start-Date: 2015-04-10  19:31:11
8X------------------------------------

Looking at the respective changelog, only the fix for 779902 ("/tmp
can be mounted as tmpfs against user's will") seems to be
tmpfs-related.

cu Andreas

-- 
`What a good friend you are to him, Dr. Maturin. His other friends are
so grateful to you.'
`I sew his ears on from time to time, sure'




More information about the Pkg-systemd-maintainers mailing list