1
General / Re: Tweak for /tmp folder
« on: May 31, 2022, 03:37:25 PM »
On your Linux system, you can keep /tmp data in a virtual file system in memory. If you decide to do so, first understand that all content of /tmp will get lost during each power cycle. But I say this is the correct behaviour of a temporary filesystem.
On my Linux host, I use this line in/etc/fstab:
tmpfs /tmp tmpfs defaults,size=2048m 0 0
Means that I have a virtual partition which can hold up to 2GB of data in RAM. If you have lots of RAM, you can increase that limit.
If you know what you do, you can add some more options for hardening your system but that might cause problems during update of some programs which execute install scripts in /tmp:
tmpfs /tmp tmpfs defaults,noexec,nodev,nosuid,size=2048m 0 0
When the entry is placen in your /etc/fstab, reboot your host.
On my Linux host, I use this line in/etc/fstab:
tmpfs /tmp tmpfs defaults,size=2048m 0 0
Means that I have a virtual partition which can hold up to 2GB of data in RAM. If you have lots of RAM, you can increase that limit.
If you know what you do, you can add some more options for hardening your system but that might cause problems during update of some programs which execute install scripts in /tmp:
tmpfs /tmp tmpfs defaults,noexec,nodev,nosuid,size=2048m 0 0
When the entry is placen in your /etc/fstab, reboot your host.