Thread: Why Mounting hides original files?

  1. #1
    Unregistered
    Guest

    Why Mounting hides original files?

    Hi,
    I am new to unix and learning it. My question is when we mount a file system on a directory (say "mount /dev/cdrom /opt" ) why do all the original files under /opt get hidden? Is there any way to access those files without unmounting the filesystem?
    Thanks.

  2. #2
    Registered User jasrajva's Avatar
    Join Date
    Oct 2001
    Posts
    99
    you shouldnt mount it on opt
    when you do that the /dev/cdrom replaces /opt

    you should create a partit or directory called /mnt and mount everything into this

    eg /dev/cdrom goes into /mnt/cdrom
    /dev/floppy goes into /mnt/floppy
    /dev/hdawhatever goes to /mnt/c: or d: etc
    jv

  3. #3
    Unregistered
    Guest
    Thanks but the question still remains. If I mount the filesystem, say on /mnt, why are the original files inside /mnt get hidden and can be accessed only after I have unmounted the file system.
    Thanks again.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Create Copies of Files
    By Kanshu in forum C++ Programming
    Replies: 13
    Last Post: 05-09-2009, 07:53 AM
  2. Linking header files, Source files and main program(Accel. C++)
    By Daniel Primed in forum C++ Programming
    Replies: 3
    Last Post: 01-17-2006, 11:46 AM
  3. Multiple Cpp Files
    By w4ck0z in forum C++ Programming
    Replies: 5
    Last Post: 11-14-2005, 02:41 PM
  4. Folding@Home Cboard team?
    By jverkoey in forum A Brief History of Cprogramming.com
    Replies: 398
    Last Post: 10-11-2005, 08:44 AM
  5. Dos commands hehe
    By Carp in forum A Brief History of Cprogramming.com
    Replies: 2
    Last Post: 01-17-2003, 02:51 PM