* Re: [gentoo-doc] WIKI: /var/tmp/portage with tmpfs
2019-08-12 15:18 ` [gentoo-doc] WIKI: /var/tmp/portage with tmpfs Javier Juan Martínez Cabezón
@ 2019-08-19 2:00 ` Dale
0 siblings, 0 replies; 2+ messages in thread
From: Dale @ 2019-08-19 2:00 UTC (permalink / raw
To: gentoo-doc
Javier Juan Martínez Cabezón wrote:
>
>
>
>
> Hi all, I have one suggestion that could be useful for you and a better
> approach:
>
> I think it could be added to this part of the wiki:
>
> https://wiki.gentoo.org/wiki/Portage_TMPDIR_on_tmpfs
>
>
> an controlled autofs tmpfs mounted on /var/tmp/portage:
>
>
> Relevant files:
>
> (based on https://wiki.gentoo.org/wiki/AutoFS)
>
>
> from my /etc/autofs/auto.master entry:
>
>
> /- /etc/autofs/autofs.vartmp
>
>
>
> and from my /etc/autofs/autofs.vartmp:
>
>
> /var/tmp/portage -fstype=tmpfs,size=14G tmpfs --timeout 300
>
>
> with those lines in the mount command output you could see:
>
>
> /etc/autofs/autofs.vartmp on /var/tmp/portage type autofs
> (rw,relatime,fd=6,pgrp=31264,timeout=300,minproto=5,maxproto=5,direct)
>
> and after accesing the directory:
>
> tmpfs on /var/tmp/portage type tmpfs (rw,relatime,size=14680064k)
>
>
> At this way you could get a portage dir mounted just only when you need
> it (emerging packages) and the RAM freed after use with the timeout.
>
I put emerge's work directory on tmpfs here as well. From my
understanding, when it is not being used, all the memory is available
for other programs. Right now, I have 16GBs for tmpfs but it still
shows 32GBs available because none of that space is in use. When I am
emerging something, regular updates etc, then it shows memory being used
but only what is actually in use, not the whole 16GBs.
Setting a timeout or only mounting it when you are about to use it
really doesn't change anything. It just makes it unmounted until it is
needed is all. Memory available stays the same.
Dale
:-) :-)
^ permalink raw reply [flat|nested] 2+ messages in thread