Gentoo Archives: gentoo-user

From: Kai Krakow <hurikhan77@×××××.com>
To: gentoo-user@l.g.o
Subject: [gentoo-user] Re: /var/tmp on tmpfs
Date: Sat, 10 Feb 2018 19:12:40
Message-Id: 0is3le-2ni.ln1@hurikhan77.spdns.de
In Reply to: Re: [gentoo-user] /var/tmp on tmpfs by gevisz
1 Am Fri, 09 Feb 2018 12:30:21 +0200 schrieb gevisz:
2
3 > 2018-02-09 10:11 GMT+02:00 Neil Bothwick <neil@××××××××××.uk>:
4 >> On Thu, 8 Feb 2018 23:18:19 +0000, Wol's lists wrote:
5 >>
6 >>> > More specifically, /var/tmp is traditionally supposed to be
7 >>> > non-volatile (across reboots).
8 >>> >
9 >>> > Comparatively the contents of /tmp can be volatile (across reboots).
10 >>> >
11 >>> > I would advise against mounting /var/tmp on tmpfs.
12 >>> >
13 >>> EMPHATICALLY YES.
14 >>>
15 >>> /tmp is defined as being volatile - stuff can disappear at any time.
16 >>>
17 >>> /var/tmp is defined as the place where programs store stuff like crash
18 >>> recovery files. Mounting it tmpfs is going to screw up any programs
19 >>> that reply on that *defined* behaviour to recover after a crash.
20 >>>
21 >>> Mounting /var/tmp/portage as tmpfs is perfectly fine as far as I know
22 >>> -
23 >>> I do it myself.
24 >>
25 >> Why mess around with another tmpfs? Just set PORTAGE_TMPDIR="/tmp" in
26 >> make.conf. Job done!
27 >
28 > It is an interesting idea. But why it is not done by default then?
29 >
30 > Can somebody think of a situation when it should not be done?
31 >
32 > My /tmp is not on tmpfs currently. Only /run
33 >
34 > May be, it is not a good idea to put /mnt on tmpfs at the time of
35 > Spector and Meltdown?
36
37 Portage doesn't run off /tmp by default because general recommendation is
38 to mount /tmp with noexec. Build scripts won't be able to run that way.
39
40
41 --
42 Regards,
43 Kai
44
45 Replies to list-only preferred.