1 |
On Wed, Jan 7, 2015 at 12:26 PM, Neil Bothwick <neil@××××××××××.uk> wrote: |
2 |
> On Wed, 7 Jan 2015 16:12:28 +0000 (UTC), James wrote: |
3 |
> |
4 |
>> > That's why I thought XFS may help. |
5 |
>> > Reports of the speed gain from tmpfs are quite mixed, but I do use it |
6 |
>> > myself. |
7 |
>> |
8 |
>> I'm moving to btrfs and eventually ceph, so xfs is not on my roadmap.... |
9 |
> |
10 |
> Not as a general FS, but as a specific choice for $PORTAGE_TMPDIR it may |
11 |
> be worth testing. XFS was designed for an environment that used temporary |
12 |
> files that didn't need to be committed to disk, so its caching doesn't |
13 |
> write to disk anywhere near as often. That means you would be working |
14 |
> with files stored in RAM a lot of the time. |
15 |
> |
16 |
|
17 |
If you're going to be saving the build files using mv/ln (or with cp |
18 |
--reflink on a filesystem that supports this), then the LAST thing I |
19 |
would do is use a different fs for PORTAGE_TMPDIR. The |
20 |
best-performing option would be to make it a directory on the same |
21 |
filesystem as wherever you're going to store the files by |
22 |
moving/(ref)linking them. That makes the move/(ref)link operation |
23 |
require minimal IO. |
24 |
|
25 |
If you put PORTAGE_TMPDIR on xfs, and then mv all those files to a |
26 |
separate filesystem, then you're going to have to do a disk-to-disk |
27 |
copy of everything and a removal of the original files. That is |
28 |
expensive in terms of IO. At last with a tmpfs you're just doing |
29 |
memory-to-disk so you're only doing disk IO once. |
30 |
|
31 |
If you're going to create tarballs then tmpfs will still be fastest, |
32 |
but using another filesystem for PORTAGE_TMPDIR isn't a problem since |
33 |
you're going to have to do disk-to-disk IO no matter what, since |
34 |
creating a tarball will always require rewriting everything. |
35 |
|
36 |
-- |
37 |
Rich |