[FrontPage] [TitleIndex] [WordIndex

This is a read-only archived version of wiki.centos.org

How to access files hidden under another mounted filesystem

Sometimes a new filesystem many be mounted over a directory already containing files. For example assume a new partition has been mounted to provide a larger /home space, and it is mounted over the original /home directory. The underlying directory structure can be accessed as follows:

mkdir /tmp/mnt
mount --bind / /tmp/mnt

Now you can look in /tmp/mnt/home and access the directory structure there. After you're done:

cd
umount /tmp/mnt
rmdir /tmp/mnt

2023-09-11 07:23