Support for uncompressed sparse files.

Gao Xiang hsiangkao at aol.com
Mon Nov 18 04:30:55 AEDT 2019


Hi Pratik,

On Sun, Nov 17, 2019 at 03:40:43PM +0530, Pratik Shinde wrote:
> Hello Gao,
> 
> I have started working on above functionality for erofs.
> First thing we need to do is detect sparse files & determine location of
> holes in it.
> 
> I was thinking of using lseek() with SEEK_HOLE & SEEK_DATA for detecting
> holes.
> Let me know what you think about the approach OR any other better approach
> in your mind.
> 
> PS : support for SEEK_HOLE & SEEK_DATA came in 3.4 kernel.

That is a good start to detect sparse files by SEEK_HOLE & SEEK_DATA.

And as the first step, we need to design the on-disk extent format
for uncompressed sparse files. Is there some preliminary proposed
ideas for this as well? :-) (I'm not sure whether Chao is busy in
other stuffs now, we'd get in line with sparse on-disk format.)

Thanks,
Gao Xiang



More information about the Linux-erofs mailing list