When is the right time to mount /tmp
(on Debian)? For /home
I would not feel bad just to echo "/dev/foo /home type defaults 0 0" >>/etc/fstab
- but can I be sure that /tmp
is not used by any programs when the fstab
is applied?
I am using either Ubuntu or plain Debian or Debian/Grml - this would not make much difference I guess.
What I have read so far:
The internet is full of advice to just add
tmpfs /tmp tmpfs <optionns> 0 0
- but I am unsure.I found this answer on what to do when
/tmp
is full without rebooting (in short: It's best to reboot anyway, except maybe for a union mount).The [Deban policy] does not explain where to add the mount, or when the first access to
/tmp
may happen. More helpful are/etc/init.d/README
and/etc/rcS/README
on my Ubuntu (read them online).
Background: I am going to use some Debian flavor on my Netbook (no HD, 8 GB SSD, 1 GB RAM - will double the RAM when neccessary). I am not low on memory. Some tasks are much too slow (building medium-sized C programs or compiling PDF from TeX both take 5+ seonds), but they take no time on a tmpfs. I want to mount a tmpfs on /tmp to accelerate them.
/tmp
from the/etc/fstab
is not any problem. Thanks to Gilles, Nils, Mikel, emory, CodeGnome!