I'm using a raspberry pi. I didn't think mounting a samba share to a folder full of files would do anything - I thought it would copy the files to the samba share. Now the files are gone from this folder, but the pi's drive is still full. Where did the files go when I mounted the samba share to the folder?
Asked
Active
Viewed 129 times
0
-
2It made more sense to you to ask this question than to do the obvious: Unmount the share and see what happens...? – Hauke Laging Feb 04 '14 at 04:21
-
Agreed, more work to ask a Q here then to unmount? – slm Feb 04 '14 at 04:24
-
I'm fairly new to Linux, and I wanted to be sure before trying anything. – enigmaticeasteregg Feb 04 '14 at 04:29
-
@enigmaticeasteregg That's a strange statement considering that you have "tried" mounting the share without having understood anything about mounting... – Hauke Laging Feb 04 '14 at 04:31
-
@HaukeLaging Unbeknownst to me the folder on the pi became disconnected from the networked folder, and thus disconnected from a TIFF-JPEG conversion script that I had running on the incoming TIFFs in this networked folder. With the network link broken, the pi quickly filled up. I had never run into the situation before of a network link like this being broken, and the pi filling up. – enigmaticeasteregg Feb 04 '14 at 04:38
-
@enigmaticeasteregg Directories which shall be used as mountpoint shall never be writable. If your script could not have created the files then the problem of filling up the whole volume would have been avoided. In order to copy the files rename the local folder and create a (write-protected) new one with the old name. Mount the share again then. – Hauke Laging Feb 04 '14 at 05:46
-
I was unaware what would happen when you mount a volume to a directory that already has content, so I'm going to up vote up (to 0) as despite the lack of research, the Q and A were useful to me. – virtualxtc Feb 04 '14 at 08:04
1 Answers
3
The mounted volume covers the filesystem content. The files will reappear when you unmount the share.
You can mirror the filesystem content with mount --bind
. If you do that before you mount the share then you can still see the filesystem content (at the other location).

Hauke Laging
- 90,279
-
Thanks, I suspected that that would help, but wanted to be sure. – enigmaticeasteregg Feb 04 '14 at 04:27