This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# The complete example from: https://unix.stackexchange.com/a/780608/256005 | |
# Create a 100M file, filled with zeros | |
dd if=/dev/zero of=100MB.bin bs=1024 count=102400 | |
# Show the size used by 100MB.bin | |
ls -sh 100MB.bin | |
# Add a filesystem to 100MB.bin | |
mkfs -t ext4 100MB.bin | |
# Show the size used by 100MB.bin | |
ls -sh 100MB.bin |