Subject: Re: hexdumping large sparce files
From: David Laight <firstname.lastname@example.org>
Date: 01/27/2003 11:44:13
On Mon, Jan 27, 2003 at 12:23:12PM +0100, Jaromir Dolecek wrote:
> As a matter of fact, all filesystems deal properly with
> write + lseek + write.
> Filesystems which don't support holes per se will use
> space on the filesystem for the 'hole' as appropriate.
> I.e. you don't need any special handling in application.
> You lseek where you want and the fs code DTRT.
Yes - I've known that for 20 years or so.
I started this thread because I was wondering if there was a
way of speeding up reads of sparce files (eg for hexdump -C
where big blocks of zeros only generate one line of output).
Leaving the file created by:
$ echo|dd of=big seek=34000000000
lurking will confuse some methods of archiving filesystems.
At 17TBytes finding the odd non-zero byte is like looking for
a needle in a haystack (actually the latter will have less places
David Laight: email@example.com