lkml.org 
[lkml]   [1996]   [Apr]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: Unnecessary seeks
Date
> The DOS-fs does no read-ahead on the FAT. So whenever you read a
> cluster of a file that's located in a yet unread sector of the FAT,
> the head has to move to track 0 to read the next part of the FAT.

Perhaps this is why mtools is 4 times faster than the Linux
filesystem code when copying a large file. This happens with
a 650kB file on a floppy and with a 4.3MB file on a Zip disk.

Zip drive example:
Use mcopy to duplicate a 4.3MB file: 1 minute
Use cp for same purpose on a mounted disk, sync: 4 minutes

> I added a really ugly hack that always causes the whole FAT to be read
> on the first access (if the FAT is small enough, i.e. on floppies).
> This keeps the whole FAT in the buffer cache and now I can read a
> complete disk without any unnecessary seeks. But this is definitely
> not the right solution, because other FSs (ext2, for example) seem to
> have similar problems.

I would imagine they have the problem but do not suffer as much.
This has something to do with the linear FAT structure. Still,
maybe ext2 could be quite a bit faster.



\
 
 \ /
  Last update: 2005-03-22 13:37    [W:0.029 / U:0.612 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site