coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Feature request: Add fibmap/SEEK_HOLE support to sha1sum.


From: Pádraig Brady
Subject: Re: Feature request: Add fibmap/SEEK_HOLE support to sha1sum.
Date: Thu, 05 Sep 2013 14:20:11 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130110 Thunderbird/17.0.2

On 09/05/2013 12:45 PM, Chris Dew wrote:
> Hi,
> 
> I have a customer who has several broken CentOS systems which behave badly 
> when reading holes from sparse files (cause not yet discovered).
> 
> They are asking for fibmap and optionally SEEK_HOLE support in sha1sum.  I 
> would be happy to add these for them.  If I did so, would coreutils accept a 
> patch for such features?  (I believe these would only yield a marginal 
> performance increase on non-broken systems.)
> 
> If so, would I be better autodetecting fibmap and SEEK_HOLE support, or doing 
> this via command line switches?

We already have fiemap support for detecting holes,
which is used by cp for sparse files.
http://git.savannah.gnu.org/gitweb/?p=coreutils.git;a=blob;f=src/extent-scan.c;hb=HEAD
SEEK_HOLE came later to Linux than fiemap and has a cleaner
more focused interface than fiemap.
I'd be happy using either interface TBH.

Such a change would require copyright attribution, See "Copyright assignment" 
in:
http://git.savannah.gnu.org/cgit/coreutils.git/plain/HACKING

In general any of the coreutils that operate on binary data (blocks)
rather than textual data (lines) could make use of hole detection.
Since checksum utils are often used with large files, they would
be good candidates to add hole detection to.

Note as well improved read efficiencies, there might be
some processing efficiencies possible too:
http://stackoverflow.com/q/15007629/4421

thanks,
Pádraig.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]