[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: /tmp is too small



On Thu, Jun 07, 2012 at 01:48:25PM +0000, Hendrik Boom wrote:
> I need more space for /tmp.  I though, easy, I'll just take out the /tmp 
> entry in /etc/fstab so that it doesn't mount anything on /tmp and uses 
> the the space on the root partition, which has more than room enough.  
> But then I discover that in my newly installed wheezy system, there *is* 
> no /etc/fstab entry for /tmp.  Apparently the kernel, all  by itself, 
> decides to mount the tmpfs on /tmp.
> 
> How can I get it not to do this?

Set RAMTMP=no in /etc/default/rcS (or /etc/default/tmpfs, depending upon
the initscripts version you have).  This is not done by the kernel, it's
done by the initscripts at startup (/etc/init.d/mount*.sh).

Note that the latest version in unstable changes the default for RAMTMP
from "yes" to "no", so it'll be disabled once this enters testing (next
time you restart).

> Or alternatively, how can I enlarge the tmpfs?  I need it enlarged from 
> anout 200M to about 2G for this week's project.  Yes, that's a lot bigger 
> than my RAM.

Set TMP_SIZE=2g in /etc/default/tmpfs, or add an entry in /etc/fstab
with size=2g.  Note that you'll need enough RAM + swap to back this
usage, so you might want to increase the swap size.

As an example (perhaps a little extreme), I have 8 GiB RAM +
16 GiB swap and a 5GiB tmpfs on /tmp.  This is because the default
(in unstable) is 20%VM i.e. 20% of all RAM + swap.


Regards,
Roger

-- 
  .''`.  Roger Leigh
 : :' :  Debian GNU/Linux    http://people.debian.org/~rleigh/
 `. `'   schroot and sbuild  http://alioth.debian.org/projects/buildd-tools
   `-    GPG Public Key      F33D 281D 470A B443 6756 147C 07B3 C8BC 4083 E800


Reply to: