Kaptain.
Telegram /
LinkedIn /
Email /
GIT /
RSS /
GPG /
Заказ печатных плат

№ 12523 В разделе
Sysadmin
от June 7th, 2024,
В подшивках: Linux, systemd
In new Linux distributions, despite standards, systemd creators continue to break Linux. The fact is that in many distributions /tmp began to be located in tmpfs and cleaned after a certain period of time, causing serious program crashes and sudden file loss.
Mounted tmpfs volume and serious size limits:
$> df -h tmpfs 3.8G 17M 3.7G 1% /tmp
Now imagine how you run mc and want to see the contents of a 10 gigabyte archive file. There are archives that mc can process simply by reading its headers (such as zip), and there are continuous archives (for example, tar.gz) that unpack the entire contents of the archive to /tmp, and there all 50-100 gigs can be. This means that /tmp will run out of space and the archive scan operation will fail. Okay, let’s say you are watching the contents of your small archive and everything is fine, you continue to work, you want to unpack the selected file and then bang! new bug! suddenly unpacked files are MISSING! Exactly the same problems with copying files over ssh to mc. Also in /tmp are Libreoffice, ssh, ssh-agent files and heaps of other system software. Can you imagine what special effects will await you if you drag out the work with them for more than a day? What to do? Patch EACH program to use /var/tmp. Is this idiocy? Yes, in its purest form. And this is due to another crutch that the creators of systemd have prepared for us:
To disable mounting /tmp as tmpfs, you need to disable tmp.mount in systemd:
sudo systemctl mask tmp.mount
Now all temporary files in /tmp will be located on disk like in any normal linux.
You can also change the behavior of /tmp if you edit the configs in /usr/lib/tmpfiles.d или /etc/tmpfiles.d.
For example I made cleanup of /tmp only once at boot in /usr/lib/tmpfiles.d/fs-tmp.conf like in any normal linux.
D! /tmp 1777 root root -
Because fuck you systemd developers. Do not brake linux with your idiotic ideas.
Fortune cookie: A pansy who lived in Khartoum Took a lesbian up to his room. They argued all night Over who had the right To do what, with which, and to whom.
Leave a Reply