What is a sparse file?
AdvancedConceptFilesystem Hierarchy, Inodes & Links
Answer
A sparse file has holes: ranges never written that occupy no disk blocks and read as zeros. VM disk images and database files are often sparse, so ls -l (apparent size) is much larger than du (allocated blocks).
truncate -s 10G disk.img
ls -lh disk.img; du -h disk.img
cp --sparse=always src dst
rsync -S src dst
Copying without sparse awareness can fill a disk unexpectedly.
More on Filesystem Hierarchy, Inodes & Links
Explain the purpose of the main top-level directories in the FHS.BeginnerWhat is the "/usr merge"?IntermediateWhat are /proc and /sys?BeginnerWhat is an inode? What does it store and what does it NOT store?BeginnerA disk shows free space but you get "No space left on device". Why?IntermediateWhat is a hard link?Beginner