Created
November 7, 2016 21:05
-
-
Save ldante86/1917061b9561b8f334a3919a53be91d2 to your computer and use it in GitHub Desktop.
notes on loopback filesystem
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
### make loopback filesystem | |
exit | |
# must be superuser | |
sudo su | |
# write file.img - 10M | |
dd if=/dev/zero of=file.img bs=10M count=1 | |
# make ext4 filesystem with file.img | |
mkfs.ext4 file.img | |
# create mount-point | |
mkdir /mnt/mount1 | |
# mount it | |
mount -o loop file.img /mnt/mount1 | |
# unmount it | |
umount /mnt/mount1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment