[rfc] boot-time async readahead...
John Moser
john.r.moser at gmail.com
Thu Feb 12 05:44:43 UTC 2009
On 2/11/09, Daniel J Blueman <daniel.blueman at gmail.com> wrote:
> By modifying the boot-time readahead to be at lower I/O and processor
> priority than the boot scripts and asynchronous, I see a 20% reduction
> in overall boot time (from installing bootchart) on my desktop: 41s
> down to 33s.
A while back I pointed out that the file list for read-ahead was
sorted by block rather than boot sequence; and that by leaving it
sorted by boot sequence (i.e. first read == first need) and
parallelling it you would necessarily have exactly two states: 1)
waiting for a file readahead is trying to read anyway; 2) readahead is
ahead of you because the rest of the boot process has spent some time
CPU bound and not touching I/O. Also, it's likely as soon as you
enter state (2) that you stay there-- which is to say, almost
immediately.
I showed some modest gains paralleling readahead with the rest of the
boot process, and not block-sorting. Nobody cares. The theory that
seeking all over the disk is slower (it is) and thus should never be
done in any case, and thus we should give readahead its own process to
make sure nothing causes a disk seek, and thus we should also sort
readahead's file list by physical position on the disk, and thus we
also assume there's no such thing as fragmentation, just happens to be
favored.
More information about the Ubuntu-devel-discuss
mailing list