I am trying to figure out a method for finding removable SD cards in Android devices. I have found several methods that provide consistently good results. Sometimes I find two different file paths that seem to point to the exact same position.
For example:
/mnt/sdcard
and
/storage/sdcard0
appear to point to the same location on some devices. My conclusion is that one of them is an alias, but both can be used to write to the SDcard. I am not too familiar with the use of aliasing, but is there a way to find out if either or both of the files is an alias? Is it possible to determine the "real" file path?
I know that Android is built on a Linux kernal, and has adopted some of the file system conventions. Is there a standard Linux way of doing this?