Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
1.The first question I have is...I umounted my /data directory, and created a file using the command echo myname >/data/name.
Then when I went to re-mount the /data filesytem and tried to cat the name file again it is no longer there. Where is the file located now or where does a file from an umounted filesytem go when you re-mount it?
Any help is greatly appreciated! Thanks!
Last edited by computergeek7; 04-22-2010 at 11:20 AM.
Any files in a directory are inaccessible when the directory is used as a Mount point; they will be accessible again when the file system is unmounted.
It is better to create one thread per topic because it gets confusing when more than one question is discussed in the same thread.
EDIT: oops! I meant to reply in the original thread.
k thanks...so your saying that the reason I can not cat the file is because it is only accessible when the filesystem is unmounted? If so, is this because I created the file when the /data filesystem was unmounted?
Last edited by computergeek7; 04-22-2010 at 11:25 AM.
Think of "mount" as "connecting". You connect a filesystem to the main tree in order to be able to see it. What is less intuitive is that the second mount (connection) hides the first one. In effect, it is as if the first connection was broken---except that it automatically reappears once the second connection is broken.
If something is hidden by a later mount, all you have to do to access it is mount it somewhere else.
Obviously, all of this creates infinite opportunities for confusion and even loss of data---be careful!!!
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.