Sometimes it is useful create an ad-hoc file system to test applications or to investigate OS’s odd behaviours.
Instead of using your usb stick you can simple create a “real” file system within a file (obviously using GNU\Linux).
Here is a brief tutorial.

  1. create an empty file
    • dd if=/dev/zero of=emptyfile bs=128M count=8
  2. format the empty file
    • mkfs.vfat emptyfile
  3. mount the formatted file
    • mount emptyfile /mnt/fat -o loop
  4. use the mounted formatted file
Advertisements