Product SiteDocumentation Site

2.7. Unwritten Extents

An unwritten extent is an extent which has been marked as "not yet written" ondisk.
Unwritten extents can be created by preallocating file space using:
Unwritten extents apply only to regular files.
The unwritten state prevents the uninitialised data in the extent from being exposed to the user.
Once such an extent is written to, or partially written to, a transaction is issued to convert the written part into a regular written extent, and mark the remaining (up to 2) extents as unwritten.
Use the -p option to xfs_bmap to view unwritten extents.
# xfs_io -f -c 'resvsp 0 10m' -c 'bmap -vp' /tmp/foo