A Deep Dive into Debian 13 /tmp: What's New, and What to Do If You Don't Like It
9 months ago
- #Debian
- #System Administration
- #Linux
- Debian 13 'Trixie' 将 /tmp 改为使用 tmpfs,文件存储在内存而非磁盘中。
- tmpfs 访问速度更快,但文件是临时的,重启后会丢失。
- /tmp 默认分配内存的50%,可通过 systemctl edit tmp.mount 调整。
- 自动清理机制:/tmp 中未使用的文件10天后删除,/var/tmp 中30天后删除。
- 低内存系统可能觉得默认 tmpfs 分配过高,但可用 systemctl mask tmp.mount 禁用此功能。