I am studying UNIX file system.
And i am trying to understand MOUNT system call.
Now there's are two sentences given in the book, which i could not understand.
1. There reference count of the directory inode must not be greater than 1(it must be at least 1 -why?), because of potentially dangerous side effects.
What exactly is this reference count in this case. I know wat is reference count. But can you explain me with an example? And why the reference should not be greater than 1?
2. By noting the device number of the attempted mount, the kernel can prevent other processes from mounting the same file system again, because strange things could happen if a double mount were allowed.
I tried mounting /dev/hda6 ( which is e drive in windows for my computer) on two mount points
a. on /mnt/ddrive
b. on /mnt/edrive
There was no error. And also i tried to update one of the mount points. Like i added a file to ddrive, and i observed that edrive also got updated automaticall. Then y is it written in the second sentence that strange things could happen? I already did double mounting and i din't face any problem. Yes I am using FEDORA CORE 2
. Is there any difference betwn mount system call of UNIX and FEDORA CORE 2?
Hope to get a reply from you soon. Thank you.