- #1
- 2,130
- 2,706
I was trying out the Linux concept bind mount in Android. As everyone knows, Android is developed on Linux framework. I have a rooted phone, and also a terminal emulator with a busybox that supports most of the important Linux commamds.
I ran the following commands:
Here,
The bind mount was successful as mountpoint returned a positive result, and I could see the effect in my file browser.
Now, what if I wanted to view the original directory of the bind mount? That is, if I were given the directory Books in
I ran the following commands:
Code:
$su
#cd /storage/emulated/0
#mkdir Books
#mount -o bind /storage/6333-6461/Books ./Books
#mountpoint Books
6333-6461
is my sd card, and emulated/0
is the internal storage as usual. su
is the same as sudo
in linux.The bind mount was successful as mountpoint returned a positive result, and I could see the effect in my file browser.
Now, what if I wanted to view the original directory of the bind mount? That is, if I were given the directory Books in
/storage/emulated/0
, how can I figure out that it's original directory is /storage/6333-6461/Books? What Linux command(s) will help me do this? (If you tell me the solution in Linux, I will try it out in Android.)