how to automatically clean /tmp
Walter Cazzola
cazzola at di.unimi.it
Wed Jan 27 19:29:57 UTC 2016
Dear Linux Experts,
I've recently passed from Fedora 20 to Fedora 23 on my laptop.
I've a separate partition for /tmp that I'm used to see it wiped out at
any reboot on my previous installation but now this is never wiped out.
This is a real partition:
/dev/sda10 5029504 1154204 3596772 25% /tmp
whereas previously it was a tmpfs partition. I've read on the web that
after Fedora 20 the tmpfs has been dropped in favor of real partition
but I was expecting anacron/cron entry that wipe the content of the
partition at boot but my system doesn't have any.
It is also difficult to create my own anacron/cron entry because this
should take effect before the system starts and create its temp
files/sockets in there.
I'm also puzzled because I also have a couple of tmpfs partitions:
tmpfs 1633640 0 1633640 0% /run/user/989
tmpfs 1633640 16 1633624 1% /run/user/526
that I don't what they are for and if I can (and how) rid of them.
Probably I could add an entry like this
tmpfs /tmp tmpfs rw,seclabel 0 0
in /etc/fstab but this would means a waste of the space I currently have
reserved for /tmp (4Gb not much but I would prefer to use them).
So there is a way to wipe out the /tmp partition before it has been
mounted and the system creates its files and use the current partition
for it?
Thank you
Walter
--
More information about the users
mailing list