[Solved] Mounting ext. sdcard folders to int. sdcard

obicom

Senior Member
Nov 9, 2010
283
81
0
Cologne
No, normally you did not need to format the sdcard.
With the few information nobody will be able to help or support you.
Let us know what works and what didn't work ...
What did you try yet? Did normal mount work? Did init.d support work? :confused:
 

CypherWolf

Member
Nov 18, 2011
35
3
0
Yes the init.d support works and I can see the music files from my external SD card in my player and i can play them. but music in my internal storage are now missing. I was under the impression that this adds additional storage to my tablet for music, video, and photos. but it just replace my internal music/video/pictures folder with the one from the external SDcard. is this how it's suppose to be? how does this actually work? does it actually add extra storage via external SDcard?
 

Chaotnix

Member
Jul 26, 2009
38
22
8
Norderstedt,Germany
The directories from the sdcard are bound to the directories in internal memory. So the contents of the directories in internal memory are not visible. That is normal in Linux.
If you want to see the files from internal memory and sdcard, create folders with name "SD2" in all three directories in internal memory. And change the script to the following:

mount -o bind /mnt/sdcard2/Music /mnt/sdcard/Music/SD2
mount -o bind /mnt/sdcard2/VIDEO /mnt/sdcard/VIDEO/SD2
mount -o bind /mnt/sdcard2/Pictures /mnt/sdcard/Pictures/SD2

With this, the files from sdcard are visible in the SD2 subfolders of the correspondending directories in internal memory.

Or change script to:

mount -o bind /mnt/sdcard2 /mnt/sdcard/transferred

So all files and directories from sdcard are visible in the transferred folder in internal memory.


Gesendet von meinem Sony Tablet S mit Tapatalk
 
  • Like
Reactions: TheHurf

TheHurf

Senior Member
Jan 30, 2011
76
15
0
The directories from the sdcard are bound to the directories in internal memory. So the contents of the directories in internal memory are not visible. That is normal in Linux.
If you want to see the files from internal memory and sdcard, create folders with name "SD2" in all three directories in internal memory. And change the script to the following:

mount -o bind /mnt/sdcard2/Music /mnt/sdcard/Music/SD2
mount -o bind /mnt/sdcard2/VIDEO /mnt/sdcard/VIDEO/SD2
mount -o bind /mnt/sdcard2/Pictures /mnt/sdcard/Pictures/SD2

With this, the files from sdcard are visible in the SD2 subfolders of the correspondending directories in internal memory.

Or change script to:

mount -o bind /mnt/sdcard2 /mnt/sdcard/transferred

So all files and directories from sdcard are visible in the transferred folder in internal memory.


Gesendet von meinem Sony Tablet S mit Tapatalk
Dude, thanks for the above post. Never occurred to me to streamline the command like that.

Folks, can confirm mount -o bind /mnt/sdcard2 /mnt/sdcard/transferred works an absolute charm (tested with music only, for now!) for mounting the external card AND being able to see content on the internal memory!

32GB SD card here I come!
 

05081983

Senior Member
Jun 2, 2008
87
9
0
Northridge
Dude, thanks for the above post. Never occurred to me to streamline the command like that.

Folks, can confirm mount -o bind /mnt/sdcard2 /mnt/sdcard/transferred works an absolute charm (tested with music only, for now!) for mounting the external card AND being able to see content on the internal memory!

32GB SD card here I come!
Can you please tell me what is the sleep time you mentioned in init.d script.
I am tired of trying different values but nothing seems to work.
If somebody can help me here please
 

rimsilva

Senior Member
Apr 11, 2009
1,181
267
113
Can you please tell me what is the sleep time you mentioned in init.d script.
I am tired of trying different values but nothing seems to work.
If somebody can help me here please
I'm with the same problem too..

additionally I'm getting error message "android.process.media has stopped unexpectedly. Please try again" at start up and times to times.

Can someone share his/her script?
 

TheHurf

Senior Member
Jan 30, 2011
76
15
0
The script I listed above works fine without putting in any of the sleep bits. I used Scripter, from the market place, dumped the script in there, Bob's your uncle!
 

05081983

Senior Member
Jun 2, 2008
87
9
0
Northridge
The script I listed above works fine without putting in any of the sleep bits. I used Scripter, from the market place, dumped the script in there, Bob's your uncle!
So your Script contained only one line????

Were you able to see all your songs stored on external SD in Sony Music Player, or you downloaded an app from market for it???
 

obicom

Senior Member
Nov 9, 2010
283
81
0
Cologne
@TheHurf:
With a tool like Scripter it works without a sleep time ...
but if you want to put it in a init.d script (for autostart) you need.

@05081983
It is possible with only this one line in the script ...
(mount -o bind /mnt/sdcard2 /mnt/sdcard/transferred )
But I would like to suggest to do it with three or four lines with a mapping into the original folders for Music, Photo and Video. But this are my own 2 cents.
 

im_iceman

Senior Member
Apr 7, 2010
2,201
130
0
Alsager
Doesn't mapping the external SD folders to the internal folders mean that you won't know which files are on the internal memory and which are on the external SD card?
 

obicom

Senior Member
Nov 9, 2010
283
81
0
Cologne
No, if you go the "one line way" all folders will be mapped on the internal sd card into the folder 'transferred'. Therefore you know that all folders in 'transferred' are from the external card.
 

TheHurf

Senior Member
Jan 30, 2011
76
15
0
Just something else to bear in mind when setting up the script file, dont save it as a .txt or .sh, leave the suffix blank, then it'll run properly!
 
  • Like
Reactions: rimsilva

rimsilva

Senior Member
Apr 11, 2009
1,181
267
113
Finnaly I was able to have this script working :)

I'can see the the music in SONY music player, but I have 2 questions:

1. The files will only be available in SONY player? They don't appear in Goggle Play.

2. The files in Music sdcard2 were copy to sdcard? They appear there.
 

obicom

Senior Member
Nov 9, 2010
283
81
0
Cologne
1.) The same files should be vissible in both (all) players. maybe you could re-scan the sdcard with a tool like "Rescan SD" from the Google Play Market. (feeless)

2.) The files are not copied. they are mapped with the mount command. It only looks like .. that this file are on the internal sdcard ... but in reality they are physically on the external sdcard.
 
  • Like
Reactions: rimsilva

[email protected]

Senior Member
Sep 24, 2007
1,465
194
93
What I'm looking for is be able access external card from computer.
So I've tried

mount -o bind /mnt/sdcard2 /mnt/sdcard/sdcard

It works fine from within tablet itself, I see /sdcard/sdcard folder and in that folder all files from /sdcard2, but on Windows 7 it shows an empty folder. However copying new files in that folder save them on /sdcard2 as it supposed to. But after tablet reboot, even though files are still physically there, Windows 7 shows an empty folder again.

Any solution for this?

Thank you.

[EDIT]
It seems this only happens if tablet plugged in to the computer before reboot. If I plug it after reboot, everything is fine. Maybe I need increase the sleep time for this?

[EDIT2]
Is bind command only works with root of partition?

I've tried use this and it doesn't work, nothing mounts:
mount -o bind /mnt/sdcard2 /mnt/sdcard/external/sdcard
 
Last edited:

sengoku

Senior Member
Nov 22, 2008
51
10
0
this is all great and all.
but' how about a nice little app you could point to that does about the same, or is this script method the only way??
i'm guessing root is required but thats all i'm getting:silly:
 
Our Apps
Get our official app!
The best way to access XDA on your phone
Nav Gestures
Add swipe gestures to any Android
One Handed Mode
Eases uses one hand with your phone