Hi all
I am trying to make sense of something:
I have done the following: create an empty file, format it and mount it like a regular filesystem. Actually I mounted it at two different places.
My fstab looks like this:
Code:
$ cat /etc/fstab
# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point> <type> <options> <dump> <pass>
# / was on /dev/sda1 during installation
UUID=56b92ca1-312c-45e6-8f57-8c80762f96b9 / ext4 errors=remount-ro 0 1
# swap was on /dev/sda5 during installation
UUID=07d0cb84-79a6-47bd-a155-cbfd045cf6ca none swap sw 0 0
/dev/fd0 /media/floppy0 auto rw,user,noauto,exec,utf8 0 0
/home/davy/swap.img swap swap sw 0 0
/home/davy/test.img /home/davy/mnt auto rw,user,auto,exec,async 0 0
/home/davy/test.img /home/davy/test auto rw,user,auto,exec,async 0 0
As you can see the same file is mounted on two different places. Now when I write stuff into one my test folder I don't see it in mnt and I don't understand why.
Code:
$ ls test
asdfkl asdfksdfklsd bla lost+found testfiles
$ rm test/asdfk*
$ ls test
bla lost+found testfiles
$ ls mnt
asdfkl asdfksdfklsd bla lost+found testfiles
$ cd mnt
$ cat asdfk
cat: asdfk: No such file or directory
since both mnt and test mount the same file, shouldn't whatever I change on one end be reflected on the other side especially since I included the async option? Now when I try to access the file it is definitely gone, how do I get to update itself?
The img file is created via dd and formated as ext4.
Thanks