04-11-2025, 12:59 PM
(04-11-2025, 11:26 AM)roderickvd Wrote: There are only two reasons that I can think of why this would be disabled by default:
1. Let the user choose whether he/she wants to spend the RAM on it. Some RPi's may have little RAM onboard, or have software that requires a lot; this is the safe default.
2. Maybe during the boot process some things are initially written to disk-based /tmp before the tmpfs service starts.
I don't know, could be interesting to think about changing the default for moOde? Or make it a system setting? After all, moOde itself takes very little RAM, and most RPi's have plenty. So it would be a safe thing to do in 99.9% of cases.
It could be a setting. The systemd unit specifies size=50% (there is actually a bug in that option) It specifies 50%% but the extra % sign doesn't seem to cause any issues.
Code:
[Mount]
What=tmpfs
Where=/tmp
Type=tmpfs
Options=mode=1777,strictatime,nosuid,nodev,size=50%%,nr_inodes=1m
I'll run it on one of my systems for few days and see what happens.
Currently utilization is really low
Code:
pi@moode9:~ $ df -h /tmp
Filesystem Size Used Avail Use% Mounted on
tmpfs 2.0G 32K 2.0G 1% /tmp