1 |
On Thu, 10 May 2007 11:34:46 +0100 |
2 |
Neil Bothwick <neil@××××××××××.uk> wrote: |
3 |
|
4 |
> On Thu, 10 May 2007 12:11:34 +0200, Benno Schulenberg wrote: |
5 |
> |
6 |
> > > No idea, but I tried it when I encountered that page and portage |
7 |
> > > operations were measurably faster. |
8 |
> > |
9 |
> > That might well be just the transfer effect: you went from an old |
10 |
> > fragmented file system to a fresh unfragmented one. |
11 |
> |
12 |
> I allowed for that. I created a new filesystem for /usr/portage - I |
13 |
> had been using a directory in /usr before. |
14 |
> |
15 |
> |
16 |
Well, maybe it has to do with the efficiency of reading discontiguous |
17 |
blocks from one file as opposed to a filesystem. Since it's a sparse |
18 |
file, there might be a lot of 'space' that, if it were on an actual |
19 |
disk, the heads would have to pass over; thus there may be a way in |
20 |
which a sparse file is more efficient than a regular filesystem. |
21 |
|
22 |
Remeber that the files in portage are, except for distfiles, quite |
23 |
small. By my calculation, the average size for files and directories |
24 |
under $PORTDIR (excluding $DISTDIR of course) is only 62 bytes. What |
25 |
would you bet that on a disk partition, the other 962 to 4034 bytes per |
26 |
block (I couldn't have block sizes less than 1K on reiser for my |
27 |
portage, and 4096 is the default for most FS's) are filled with |
28 |
nothing, and the heads need to pass over them to read the next block. |
29 |
On a sparse file that space is merely reserved, it needn't actually |
30 |
exist. Hope that helps you conceptualize the difference. |
31 |
-- |
32 |
gentoo-user@g.o mailing list |