Re: How to generate a large file allocating space

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

 



On Sun, Oct 31, 2010 at 04:34:44PM +0100, Alex Bligh wrote:
> That's /almost/ perfect:
> 
>   9  247808 15069184           14336 unwritten,eof
> testfile: 2 extents found
> 
> I think all I need do is clear the unwritten flag in each of the extents.
> Else I think if I read the file using ext4 later (i.e. after I've
> written directly to the sectors concerned) it will appear to be
> empty. 

Yes, it would appear empty. It is due to security concers others mentioned
too.

> Any idea how I do that?

Sorry, I don't. debugfs(8) only appears to have read-only support for
reading extents, and not for (re-)writing them, so I guess you'll have to
find some function in libext2fs if it exists (or write your own if it
doesn't) to use on unmounted fs.

-- 
Opinions above are GNU-copylefted.

_______________________________________________
Ext3-users mailing list
Ext3-users@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/ext3-users


[Index of Archives]         [Linux RAID]     [Kernel Development]     [Red Hat Install]     [Video 4 Linux]     [Postgresql]     [Fedora]     [Gimp]     [Yosemite News]

  Powered by Linux