Swap External_SD with Internal SD (WIP, need help) - Galaxy S II Q&A, Help & Troubleshooting

There is a sizable thread over i9003 forum about editing vold.fstab to swap internal with external sd. I guess they were more desperate as i9003 comes with very small internal storage. But even our "16GB" isn't enough for many of us.
I'm on 2.3.5, and I've tried editing the file using vim, and have failed miserably each and every time.
Unfortunately, the fstab file for i9003 differs quite a bit from the one for i9100. Here are what I've noticed:
i9003:
mount_deep
mbr_policy
i9100:
format_option
otg subsection
They also have different sysfs path and mount point.
Any knowledgeable person/people wanna jump in and make the magic happen?

does no one else see the value in this?

Sure I do
For instance I applied the idea from ownwhere (here) but in the most simple way just to test it.
I tested it with the gameloft dir.
So first I moved /sdcard/gameloft/ to /sdcard/external_sd/gameloft/
Then I created back an empty folder /sdcard/gameloft/
and then I mounted the external_sd/gameloft dir in it with :
mount --bind /sdcard/external_sd/gameloft/ /sdcard/gameloft/
I used Script Manager free version from market to run this script at boot time (added a baaad sleep 60 at the top of it to wait for the system to finish the storages checks).
And this works for me. It will help me to wait for a true external_sd / internal_storage swap mod...
I hope it will also help other people here in the same way as it did for me

sirnono said:
Sure I do
For instance I applied the idea from ownwhere (here) but in the most simple way just to test it.
I tested it with the gameloft dir.
So first I moved /sdcard/gameloft/ to /sdcard/external_sd/gameloft/
Then I created back an empty folder /sdcard/gameloft/
and then I mounted the external_sd/gameloft dir in it with :
mount --bind /sdcard/external_sd/gameloft/ /sdcard/gameloft/
I used Script Manager free version from market to run this script at boot time (added a baaad sleep 60 at the top of it to wait for the system to finish the storages checks).
And this works for me. It will help me to wait for a true external_sd / internal_storage swap mod...
I hope it will also help other people here in the same way as it did for me
Click to expand...
Click to collapse
But you'd have to unmount every time you want to use usb storage, no?
I think I've tried all realistic combination/possibility of editing the vold.fstab file given my very limited knowledge. My conclusion is, someone with knowledge needs to try this

ln -s /sdcard/external_sd/gameloft /sdcard/gameloft ?

samaral said:
ln -s /sdcard/external_sd/gameloft /sdcard/gameloft ?
Click to expand...
Click to collapse
Nope, doesn't work. Does symlink even work on FAT?

g2tl said:
But you'd have to unmount every time you want to use usb storage, no?
I think I've tried all realistic combination/possibility of editing the vold.fstab file given my very limited knowledge. My conclusion is, someone with knowledge needs to try this
Click to expand...
Click to collapse
Hello
Yes I need to do this if i want to use usb storage on desktop computer with the default system option.
But you can use apps like multi mount sd-card lite (free on market) to mount sd-card(s) on desktop computers and keep them mounted on the phone (read-only).
This way I didn't get any mounting problems but I didn't test very much so perhaps this can lead to mounting errors later on.
Maybe you have already tried this ?

I get massive slowdonws when copying large files with that widget.
Sent from my GT-I9100 using XDA App

Related

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

Hi folks,
As you know, the Sony media and video player didn't show the mp3 and videos on the external SD card in his library.
Now my idea was to mount folders of the external sdcard into folders on the internal sdcard.
Solution:
I created a script for mounting photo, video and music folders from ext. sdcard to the corresponding folders on the int. sdcard. After successful tests, I implemented init.d support on my Tablet S for a 'autostart' solution at boot time and moved the script to 'init.d' folder. For me it works great and fulfilled my requirements 100%.
Enclosed the content of my 'automount' script:
#!/system/bin/sh
# need sleep 75 for right timing maybe you can reduce it to 30
sleep 75
mount -o bind /mnt/sdcard2/Music /mnt/sdcard/Music
mount -o bind /mnt/sdcard2/Video /mnt/sdcard/VIDEO
mount -o bind /mnt/sdcard2/Fotos /mnt/sdcard/Pictures
Click to expand...
Click to collapse
Here you can find my [HOW_TO] for init.d support:
http://forum.xda-developers.com/showthread.php?t=1505340
P.S.: If it do not work for you, try to increase the sleep value. If you have a 'fresh' system 30 should be enough ... if you use two or three widgets 'sleep 75' could be ok ... and so on ...
I hope that someone has the technical knowhow how to do this, that would be great to access extra memory
also one interesting thing in build.prop:
Code:
ro.separated.external.storage=true
Would you try what happened if you change to "false"?
I found the same entry ... but do not know what it mean.
Saw the same thing myself, but don't have an SD card with me, so I wont get to try till I get home.
But I guess the change of the mount point in the /etc/svold.fstab is particularly promising. I still waiting for a rating of a expert. No one here?
Changed that line in true, rebooted.
Openend up Poweramp and this had to scan my folders again.
Sd Card still there and working but nothing more I think.
Can't really see if there's anything changed.
I tried:
Removing nosdcard from ro.build.characteristics
Changing ro.external.storage.removable to true
Changing ro.separated.external.storage to false
I haven't been able to see any difference.
Things I looked at:
The stock video player won't recognize videos on my SD card.
Videos on SD card will play if I navigate to them using Root Explorer
I can move apps to SD card using Titanium Backup, and play them from the SD card.
Anyone have some tips on what else I can look for?
50% Solution
Hi guys,
I tried a other way (and more secure) from a hint in an other forum.
If you use the following command with adb or a app like "scripter" on your tablet,
you will mount the external card into the internal, but step by step:
1. create a new folder /external_sd under /mnt/scard/
e.g. with adb shell : mkdir -p /mnt/sdcard/external_sd
2. then mount the /mnt/sdcard2 to this folder
e.g. with adb shell: mount -o bind /mnt/sdcard2 /mnt/sdcard/external_sd
3. now it is done and if you now refresh your media library, you will find all your media stuff on your media player.
Unfortunately you have to do the same after a reboot or switch off/on.
I am a little bit afraid to add this command line in init.rc or something else.
Do one of you have a proposal how we can make it permanent, without a risk?
obicom said:
Hi guys,
I tried a other way (and more secure) from a hint in an other forum.
If you use the following command with adb or a app like "scripter" on your tablet,
you will mount the external card into the internal, but step by step:
1. create a new folder /external_sd under /mnt/scard/
e.g. with adb shell : mkdir -p /mnt/sdcard/external_sd
2. then mount the /mnt/sdcard2 to this folder
e.g. with adb shell: mount -o bind /mnt/sdcard2 /mnt/sdcard/external_sd
3. now it is done and if you now refresh your media library, you will find all your media stuff on your media player.
Unfortunately you have to do the same after a reboot or switch off/on.
I am a little bit afraid to add this command line in init.rc or something else.
Do one of you have a proposal how we can make it permanent, without a risk?
Click to expand...
Click to collapse
I will check it for you if you want but after work, evening
These are good news
I am sure for you it is a "child's play", but I think helpful for all of us.
Please let me know if I can test something ...
THANKS IN ADVANCE !
-- Edit --
Maybe we can add this command to rescan media files after mount command:
mount -o bind /mnt/sdcard2 /mnt/sdcard/external_sd
pm enable com.android.providers.media/com.android.providers.media.MediaScannerReceiver
Click to expand...
Click to collapse
50%...............phew, getting closer, keep up the good work chaps.
http://www.androidtablets.net/forum...cation-discussion-post-root-2.html#post149151
Maybe this helps?
Good find there. Wonder if the Vizio is similar to the Sony.
Link2SD
If you want app data to be moved to external sd Link2Sd works but with a few extra steps only. Here is how I manage this on mine.
Installed Link2SD on tablet.
Formatted external card (in my case a 32GB microsd in an SD adapter) on my laptop using EASEUS to have to PRIMARY partitions 1st in FAT32 and second in EXT3 formats.
At first Link2SD does not recognise any ext partition present and if I try to recreate mounting script on it telling it EXT3 format it says something like could not do, directory does not exist or similar.
Then after a reboot Link2sd warning pops up saying the sd card was not mounted at boot and therefore the system did not load apps on it. You have an option to recreate a mounting script (which I did not need to do as did it already previously) and the quick reboot option (which is different from the regular reboot in the way that it only restarts the android interface not the whole hardware) - so I do this reboot and after everything starts you can see the extra partition and use it.
So currently quick reboot is needed after every total shutdown of the tablet - thankfully I almost never shut down the tablet completely unless run out of battery completely or some other rare reason or testing like this one.
Also note that quick reboot sometimes gives a close/wait warning just after it is done - I always chose wait and everything seemed ok after that.
Make sure you give Link2sd superuser permission. I decided to leave out Lib out of the app data I link because I noticed that if I move data back to internal storage link2SD shows that libs are unlinked already/ I know there is an option in link2sd to relink libs at boot but I was not able to confirm if it works and they tend to take little space internally anyway.
Regarding extra partition size I tried less than 1GB and ca 14Gb. With bigger than 1GB partition it seems to recognise its size in link2sd but once you move more than 1gb data to it does not reflect the increase above 1gb but still seems to make the apps I moved before and after that work still.
I wonder if multi mount widget could help when combined with link2SD somehow. My guess best solution would be to make android mount external card early in its boot.
Hope it helps
I tried today several things ....
@ps3taker
that sound a little bit more complicated then my solution with app scripter and the mount command.
I tried today several things to get a "autostart" solution but unfortunately without success:
- App "autostart (root)" don't work on Tablet S
- Change in svold.fstab need sd card eject and insert to be mounted after rboot
- Change in vold.fstab need sd card eject and insert to be mounted after reboot
- Add mount command in init.goldfish.sh don't work
- Startup script tweaks can't work, no "/system/bin/playlogosnow" on Tablet S
(http://forum.xda-developers.com/showthread.php?t=813309)
Someone additional ideas for a autostart option for the mount command?
-- Edit --
I did a little bit more investigations and find out, that after a reboot it needs a short time before the internal sd card is ready to use. Therefore it is senseless to search a solution during boot time. I guess this is the reason why the change in svold.fstab and vold.fstab didn't work.
That means we need a "autostart" App, as a Widget or a Virus scanner that mount the device and rescan the medias. Who is willing and to do that for us?
just create an init.d script and symlink the ext_sd folder to the desired folder on sdcard...
check if this device has:
/system/etc/install-recovery.sh
if it doesnt then check if the /init.rc (or other init.*.rc) files contain the text "install-recovery.sh"
if the text exists then just create the file /system/etc/install-recovery.sh which has the following at the top:
Code:
#!/system/bin/sh
followed by the symlink/bind code
and save file and give it 777 permission (chmod 777 /system/etc/install-recovery.sh)
that should automatically run the desired commands at each boot...
if the above is not possible then just create a GScipt script and execute it at startup
DooMLoRD said:
just create an init.d script and symlink the ext_sd folder to the desired folder on sdcard...
Click to expand...
Click to collapse
Hi DooMLoRD,
symlink will not work - because of fat32 sdcard! We've got to use mount -o bind, it works without problem, about autorun thing - thanks - i've got to try it
br
condi
@DooMLoRD & Condi
I did exactly this in my tests before, with the "install-recovery.sh".
The file "/system/etc/install-recovery.sh" don't exist but the the "init.rc" files contains the text "install-recovery.sh".
So I created the file "/system/etc/install-recovery.sh" with the commands:
#!/system/bin/sh
mount -o bind /mnt/sdcard2 /mnt/sdcard/external_sd
Click to expand...
Click to collapse
and give it 777 permission but unfortunately it dosen't work.
I guess the reason is the timing problem, that sdcard mount is not ready in this moment. I will try tomorrow add first the mount command for "/mnt/sdcard" in this file and will see what will happen.
Keep you informed.
thank you all for trying.
Could you please summarise what works currently please.
a) Do you manage to link apps to external sd as in rooted gingerbread?
b) or is it just for showing external sd media in the native player in a separate subfolder or something similar
c) do you manage to swap around external and internal sds, i.e. mnt\sdcard is now external as on gingebread and mnt\sdcard2 is the built-in/internal one
I think all of the above is useful but would like to know what's the initial plan.

[UPDATE]possibility to move ANY game data to sdcard2 ;)

hi there, thats it
is there any possibility to move the games-data to the sdcard2?
i couldnĀ“t get gl2sd to work correctly. it moves my data, but my games dont recognize it and begins to download the data again (yes, i mounted the storage ^^).
ive got a 32gb sdcard, it would be awesome to get something to work in that direction.
----
Update:
YES I GOT IT! thx google and a guy named sergey_f1 ( credits goes to him, i only changed it for tablet s)
here it is: (example galaxy on fire2)
mount -o bin /mnt/sdcard2/net.fishlabs.GalaxyonFire2THD /mnt/sdcard/Android/data/net.fishlabs.GalaxyonFire2THD
in scriptmanager with SU + Boot on
please confirm if i made something wrong. im not a dev nor am i used to it-basics ^^
but for now it rocks
This should work. One thing to be wary of for new users reading this:
You're not actually really moving game data anywhere. You are simply making the folder /mnt/sdcard/Android/data/ be actually stored on another filesystem device. Anyone who has used Linux would understand the concept of remounting a folder elsewhere. The biggest difference with this (for your average user) is that if you remove the SD Card, you will not be able to use those games properly as their data storage location is now completely invalid, not just that the files are missing. This also means that if you are, for example, copying files from the /mnt/sdcard/Android/data folder onto your PC, you won't save any space on your internal storage, since that folder is mounted elsewhere.
As you said, that should work, its just a good idea to know technically whats going on before people start remounting FS's all over the place.

obb "Game Data" to external_sd and Link2Sd Info [Updated 3/24]

UPDATE:
I now recommend using FolderMount instead of the scripts below.
Forum Link: http://forum.xda-developers.com/showthread.php?t=2192122
Market Link: https://play.google.com/store/apps/...251bGwsMSwxLDEsImNvbS5kZXZhc3F1ZS5mbW91bnQiXQ..
Click to expand...
Click to collapse
PART 1: obb "Game Data" to external_sd
Simple script that binds the internal obb folder to an external Gamedata folder on your sd to save space on Internal SD Card.
Use at your own risk.
1. Create a folder on the external_sd called "Gamedata"
2. Move all folders located in sdcard/android/obb to the newly created folder "Gamedata" (This takes a long time using Root Explorer, be patient. I recommend using Solid Explorer so that you can see the progress.)
3. Download the txt file and rename the extension to .sh OR Create a new script using:
Stock ICS:
Code:
mount -o bind /mnt/sdcard/external_sd/Gamedata /mnt/sdcard/Android/obb/
SnowJB (may or may not work on other JB ROMS) - Credit:
Code:
mount -o bind /storage/external_SD/Gamedata /storage/sdcard0/Android/obb/
4. Download Smanager from the playstore.
5. Find the script you created and set it to run with SU, make sure to save.
6. You can run it now to see if it worked. (If it did, make sure to edit the script to run at boot)
Notes:
I reclaimed about 6GB+ and was able to download several new games after doing this.
Occasional a folder called /Android/data/ gets created in Gamedata but it stays empty and doesn't effect anything. Just ignore it.
Newly downloaded game data will automatically be downloaded to the Gamedata folder. (As long as the addition data is downloaded through Google Play)
Works with Link2SD
This should work on every device that has an external sd card, however you might have to edit the paths to make sure they match up with how your device has the external sd card implemented (emmc, sdcard1, extSdCard). You may also have to edit the internal sd path for 4.2 and above to because of multi-user support.
Thanks to DeathmonkeyGTX! His music cache script gave me the idea to do the same for obb game data. They could probably be combined into one script, should you want to.
PART 2: Link2SD Info - for even more space saving
You can also use Link2Sd (found on the market) to store apps on the external sd card.
I formatted my external sd into two partitions. One 55 GB partition (For user data) and another 4 GB partition (for Link2SD).
Notes:
The highest app that I linked only saved about 50 MBs. Not really saving that much space, but after I linked several 50 MBs and under apps, I recovered about 1.2 GBs of space on the Internal.
The second partition can only be used for Link2SD.
To Set Up:
Backup your SD, format it to Fat32, use MiniTool to resize the first partition, then create a second partition (FAT 32 and make sure it is Primary) using the remaining space. You should now have two partitions. Now just launch the Link2SD app and create the start-up mount scripts. Reboot, launch the app once more, and finally start linking apps to your external sd card.
More info here: http://www.link2sd.info/home
I recommend reading the description and FAQ.
Both "PARTS" can be used together or separately just fine on ICS. However, I was not able to get Link2Sd working on SnowJB.
Seems to be working great! We now have so much more room for activities!
This is what I call a WIN: http://imgur.com/a/WBtHP
as far as I know I did everything I was supposed to but I went and deleted the files on my internal sd card and it deleted the ones on external sd card. I downloaded the app again and it saved the files in both locations and I deleted the internal one and it deleted both again. What could be causing this?
mws1986 said:
as far as I know I did everything I was supposed to but I went and deleted the files on my internal sd card and it deleted the ones on external sd card. I downloaded the app again and it saved the files in both locations and I deleted the internal one and it deleted both again. What could be causing this?
Click to expand...
Click to collapse
You have to delete the files before you set the script to run at boot. Otherwise you will be deleting the files on the external sd since the script tricks the system into thinking they are on the internal. I'm also think that your misunderstanding when you say they are on both. If you look at the total space when tapping the obb folder on your internal you will notice it goes from 11GB to whatever size you external sd card is. The two folders are binded so it would appear that they are on both but they are only on your external.
Joecascio2000 said:
You have to delete the files before you set the script to run at boot. Otherwise you will be deleting the files on the external sd since the script tricks the system into thinking they are on the internal. I'm also think that your misunderstanding when you say they are on both. If you look at the total space when tapping the obb folder on your internal you will notice it goes from 11GB to whatever size you external sd card is. The two folders are binded so it would appear that they are on both but they are only on your external.
Click to expand...
Click to collapse
I just noticed this today, I ran this correctly (thank you for adapting it btw) and saw that I had "duplicates" on my internal. Then I saw that the total space was listed as 32 gigs... and it clicked, lol.
For a little clarification, you will see the folder in both places, the one on the internal card is just a link, it shouldn't actually take up any room on the internal card.
I was also able to get this to work for another folder created by a game that didn't put the files in obb folder.
(Just make a copy of the script and edit the pathways in it and run as root at boot.)
bleached45 said:
I just noticed this today, I ran this correctly (thank you for adapting it btw) and saw that I had "duplicates" on my internal. Then I saw that the total space was listed as 32 gigs... and it clicked, lol.
For a little clarification, you will see the folder in both places, the one on the internal card is just a link, it shouldn't actually take up any room on the internal card.
I was also able to get this to work for another folder created by a game that didn't put the files in obb folder.
(Just make a copy of the script and edit the pathways in it and run as root at boot.)
Click to expand...
Click to collapse
Yeah it bugs me big time that some apps download files to different places. I noticed some apps that download additional files through the play store, download the data to the /android/data/ folder instead of /android/obb/. Google really needs to make that uniform, where all additional game data get downloaded to one place. I did, however, adapt my script to link the whole /android/ folder to the external sdcard.
I won't release that one because there is way more things that can go wrong. The /android/data folder is used for so much more than just games and if it's not set up just right you could get force closes and blank widgets on boot. But just FYI, it is possible and is working well for me.
Worked! Thanks a lot for the script man helped save a lot of data!
Sent from my LG-E970 using xda app-developers app
Well, I can't get this post deleted, but I was able to figure out my problem!
Thanks for posting this solution! So happy to have it!
Re: obb "Game Data" to external_sd and Link2Sd Info
I used both methods here, obb and links2sd and it helped me out tremendously. Nice work and thanks for posting this.
Sent from my LG-E970 using xda premium
Hey Joecascio2000,
Do you know how one would modify this script to work on the Stock 4.1.2 Jelly Bean LG-E973/1/5/0 CANADA / ATT / INTERNATIONAL rom?
I've read in that thread that the sdcard locations are different for Jellybean.
I've tried the following path to no avail.
mount -o bind /mnt/storage/external_SD/Gamedata /mnt/storage/sdcard0/Android/obb/
Using that path will have smanager error out stating the following:
card0:/AndroidObbSwap.sh'
mount: No such file or directory
Any input would be greatly appreciated.
Yoreo said:
Hey Joecascio2000,
Do you know how one would modify this script to work on the Stock 4.1.2 Jelly Bean LG-E973/1/5/0 CANADA / ATT / INTERNATIONAL rom?
I've read in that thread that the sdcard locations are different for Jellybean.
I've tried the following path to no avail.
mount -o bind /mnt/storage/external_SD/Gamedata /mnt/storage/sdcard0/Android/obb/
Using that path will have smanager error out stating the following:
card0:/AndroidObbSwap.sh'
mount: No such file or directory
Any input would be greatly appreciated.
Click to expand...
Click to collapse
I don't have JB installed yet so I don't know exactly how the sd card and external sd card are mount. I'm assuming your paths are correct. But I suggest making sure that the script is running from the internal SD card. Also, I would add a "sleep" line just to make sure the external sd is mounted properly before running the bind.
Try:
#start
sleep 30
mount -o bind /mnt/storage/external_SD/Gamedata /mnt/storage/sdcard0/Android/obb/
#end
Joecascio2000 said:
I don't have JB installed yet so I don't know exactly how the sd card and external sd card are mount. I'm assuming your paths are correct. But I suggest making sure that the script is running from the internal SD card. Also, I would add a "sleep" line just to make sure the external sd is mounted properly before running the bind.
Try:
#start
sleep 30
mount -o bind /mnt/storage/external_SD/Gamedata /mnt/storage/sdcard0/Android/obb/
#end
Click to expand...
Click to collapse
I gave that a shot, and it's still kicking out the same error. I think I'm going to post in that thread and see if anyone there can tell me if my path names are incorrect.
Well Joecascio2000, I figured it out after getting a good nights sleep. My paths weren't correct.
Anyhow, the correct path/command is as follows:
Code:
mount -o bind /storage/external_SD/Gamedata /storage/sdcard0/Android/obb/
Feel free to update your OP to notify anyone who may be using that rom to use the above script for things to work properly.
What would be the code to get this working with the new cm 10.1 conversion?
I tried
mount -o bind /storage/sdcard1/Gamedata /storage/emulated/0/Android/obb/
and a few others
Yoreo said:
Well Joecascio2000, I figured it out after getting a good nights sleep. My paths weren't correct.
Anyhow, the correct path/command is as follows:
Code:
mount -o bind /storage/external_SD/Gamedata /storage/sdcard0/Android/obb/
Feel free to update your OP to notify anyone who may be using that rom to use the above script for things to work properly.
Click to expand...
Click to collapse
Thanks. I updated to OP to include your code and put a link to your post.
whoamanwtf said:
What would be the code to get this working with the new cm 10.1 conversion?
I tried
mount -o bind /storage/sdcard1/Gamedata /storage/emulated/0/Android/obb/
and a few others
Click to expand...
Click to collapse
Again, not really sure how CM10.1 handles the external sd. Did you try the code directly above your post? It works for the JB port so it may work for the CM10.1 ROM.
EDIT:
Try:
mount -o bind /storage/sdcard1/Gamedata /storage/sdcard0/Android/obb/
That is what I have on my Captivate running CM10.1.
Re: obb "Game Data" to external_sd and Link2Sd Info
I'm not 100% for sure on this but doesn't cm10 handle the external sd as emmc?
Sent from my LG-E970 using xda premium
Re: obb "Game Data" to external_sd and Link2Sd Info
tmease1 said:
I'm not 100% for sure on this but doesn't cm10 handle the external sd as emmc?
Sent from my LG-E970 using xda premium
Click to expand...
Click to collapse
I know they used too on my Captivate but with the multiple users in 10.1 I think they might have changed it. And again it could be different for every device. I recommend using solid explorer to just search around. If you tap the little android icon in the top left it gives you the exact path of the folder you are in.
Sent from my LG-E970 using xda premium
Joecascio2000 said:
I know they used too on my Captivate but with the multiple users in 10.1 I think they might have changed it. And again it could be different for every device. I recommend using solid explorer to just search around. If you tap the little android icon in the top left it gives you the exact path of the folder you are in.
Sent from my LG-E970 using xda premium
Click to expand...
Click to collapse
Yeah it is weird I found the exact paths and changed the script but it still doesnt work, even got it to where it looked like it worked, went green and no mount error but no data
whoamanwtf said:
Yeah it is weird I found the exact paths and changed the script but it still doesnt work, even got it to where it looked like it worked, went green and no mount error but no data
Click to expand...
Click to collapse
Did you add the sleep line? Some ROMS take longer to mount the sd card than others. If the sd card isn't mounted before the script runs nothing will happen.
Code:
#start
sleep 30
mount -o bind /storage/external_SD/Gamedata /storage/sdcard0/Android/obb/
#end
This will wait 30 seconds before running the script. If the paths are correct, I don't see why it wouldn't work. Under smanager, click menu>more> advanced>configuration, and turn on "Show On Boot Script Log". That should give you an idea as to what is happening.

Delete sdcard and mount extSdCard

Delete sdcard and mount extSdCard 16 gb as internal memory.
How to? i have small memory on Samsung b5330 2GB only, and i want to install more apps... and some games, how to delete sdcard i don't need it and mount the extSdCard as internal. Thank you
agentulxxx said:
Delete sdcard and mount extSdCard 16 gb as internal memory.
How to? i have small memory on Samsung b5330 2GB only, and i want to install more apps... and some games, how to delete sdcard i don't need it and mount the extSdCard as internal. Thank you
Click to expand...
Click to collapse
Well, no reason to just disable it. You can swap them however, though with the limited available development for your phone, there doesn't seem to be any out of the box solutions. You'll either have to try an app like this: https://play.google.com/store/apps/details?id=eu.codlab.int2ext or follow a guide for say, an S3, and mod that to reflect the correct partition mounts and names for your particular phone and update. For some phones, a compatible kernel is needed for the swap. If that is the case for your phone, you are probably out of luck since there doesn't seem to be much of anything like that for you. Make sure to not only back up your phone, but internal and external storages before attempting this. Would also be good to be familiar with how to flash back to stock with Odin since that's about the only option you have to get back to normal if things don't work right.
NO problem
Is not a problem to do format with odin, i have root-it the phone, i have change some times andoid version on it, i don't care about apps, i have all apps on my pc. i tried more commands with terminal emulator.. no Lucky. i will try this app,
i try to modify "vold.fstab" but nothing changes except on start up, all apps has crashed. and i am sorry for my bad english.
I have a problem, now my extSdCard is same as sdcard folder, and sdcard folder has no changes. are the same... any ideea
Now finaly working, i have changed where normal i have to write path of internal name o /mnt/sdcard to extSdCard and for external i have write /mnt/sdcard now is working .. i have inverted the names.i have loot of memory now how to make the 2 gb of memory work as swap? or lass 512.. becouse i cant see it anywhere.:good:
agentulxxx said:
Now finaly working, i have changed where normal i have to write path of internal name o /mnt/sdcard to extSdCard and for external i have write /mnt/sdcard now is working .. i have inverted the names.i have loot of memory now how to make the 2 gb of memory work as swap? or lass 512.. becouse i cant see it anywhere.:good:
Click to expand...
Click to collapse
Good job! As far as the swap - are you referring to virtual RAM swap?
es0tericcha0s said:
Good job! As far as the swap - are you referring to virtual RAM swap?
Click to expand...
Click to collapse
Yes, Virtual RAM swap... i have made it on sd card
dd if=/dev/zero of=/mnt/extSdCard/.swapfile bs=1024 count=94288
mkswap /mnt/extSdCard/.swapfile
chown root:root /mnt/extSdCard/.swapfile
chmod 0600 /mnt/extSdCard/.swapfile
swapon /mnt/extSdCard/.swapfile
But i can't find anymore the 2 gb sdcard, is only my ext sdcard working :laugh::laugh:
Results
Sent from my GT-B5330 using XDA Premium 4 mobile app
Yea, not so sure about that part, unfortunately. I haven't had to do that manually before that didn't already have an established method for the particular phone. Glad the main part is working though!
es0tericcha0s said:
Yea, not so sure about that part, unfortunately. I haven't had to do that manually before that didn't already have an established method for the particular phone. Glad the main part is working though!
Click to expand...
Click to collapse
Any ideea to overclok CPU and GPU seems my kernel isnt supoport this, how to make-it to support :laugh::laugh:
On my pc i did overclok about 30%
agentulxxx said:
Any ideea to overclok CPU and GPU seems my kernel isnt supoport this, how to make-it to support :laugh::laugh:
On my pc i did overclok about 30%
Click to expand...
Click to collapse
That part will probably be pretty tricky because there isn't really any development for it, and almost certainly no source code to build the kernel yourself. Your best bet is to check out some other phones that use the same chipset that might have some development that you can kind of piggyback off of. These other phones would be similar: http://pdadb.net/index.php?m=pdamaster&posted=1&cpu=a21654
It looks like the Galaxy Y Plus (i9001) has a decent little development community. The guys there would probably be more helpful with figuring out stuff to do since it has a similar processor. Might try to befriend a kernel dev there and see if they could give you a hand.
http://forum.xda-developers.com/galaxy-s-i9000/i9001-development

[Q] Use /storage/external_SD instead of /storage/sdcard0

I have a LG Optimus L3 II, and since it has less than 2 GB of total ROM, I have bought an external SD card. I have some experience with Linux desktop systems, but not really with Android. On a Linux desktop, if I lack disk space, I can mount /home to the device I want using /etc/fstab, so all my personal files are transparently saved to the specified device.
I have noticed that my user files on the LG Optimus are all saved to /storage/sdcard0. Also, that there is a symlink from /sdcard to /storage/sdcard0.
What I would like to accomplish is to transparently have all my personal files on /storage/external_SD, but I'm not sure if I can just change /sdcard to point to the new location, or if I would need to change mount points somewhere, etc. I have searched on Google about this, but found nothing clear, and it seems this may vary from device to device. Also, I haven't tried anything yet, because I don't really think I would be able to recover if anything goes bad.
Thanks for your attention!
teresaejunior said:
I have a LG Optimus L3 II, and since it has less than 2 GB of total ROM, I have bought an external SD card. I have some experience with Linux desktop systems, but not really with Android. On a Linux desktop, if I lack disk space, I can mount /home to the device I want using /etc/fstab, so all my personal files are transparently saved to the specified device.
I have noticed that my user files on the LG Optimus are all saved to /storage/sdcard0. Also, that there is a symlink from /sdcard to /storage/sdcard0.
What I would like to accomplish is to transparently have all my personal files on /storage/external_SD, but I'm not sure if I can just change /sdcard to point to the new location, or if I would need to change mount points somewhere, etc. I have searched on Google about this, but found nothing clear, and it seems this may vary from device to device. Also, I haven't tried anything yet, because I don't really think I would be able to recover if anything goes bad.
Thanks for your attention!
Click to expand...
Click to collapse
You can't just replace /sdcard to point to a new location, as Android is always expected to run from the internal storage, and this can cause mayhem. Now, the first question you should answer to yourself is what you mean when you say "personal files": if you just need to store songs, pictures, movies etc., you can store them on the external SD without any issues.
However, the main problem with Android in this aspect is the applications (apps and their data). The best thing would be if you could natively install them on the SD. But this is not always possible, since SD cards are usually formatted with non native Linux file systems (such as FAT) ,in order for them to be mounted on Windows, meaning that they lack the infrastructure to run apps from within (like file permissions or symlinks).
Solution here is the following: Format your SD card to be either all or partially of an ext3/4 file system type (so it can at least hold all apps and their data), then install the Link2SD app, which moves the application to this SD partition and creates all links from the internal drive to this partition. The paid version of this app (Link2SD+, which costs $1) allows you to link also the application data to the SD card (not only the app itself). I have used this solution on many low end devices I had in the past (like yours basically), and it solved this issue perfectly.
Digdis said:
You can't just replace /sdcard to point to a new location, as Android is always expected to run from the internal storage, and this can cause mayhem. Now, the first question you should answer to yourself is what you mean when you say "personal files": if you just need to store songs, pictures, movies etc., you can store them on the external SD without any issues.
However, the main problem with Android in this aspect is the applications (apps and their data). The best thing would be if you could natively install them on the SD. But this is not always possible, since SD cards are usually formatted with non native Linux file systems (such as FAT) ,in order for them to be mounted on Windows, meaning that they lack the infrastructure to run apps from within (like file permissions or symlinks).
Solution here is the following: Format your SD card to be either all or partially of an ext3/4 file system type (so it can at least hold all apps and their data), then install the Link2SD app, which moves the application to this SD partition and creates all links from the internal drive to this partition. The paid version of this app (Link2SD+, which costs $1) allows you to link also the application data to the SD card (not only the app itself). I have used this solution on many low end devices I had in the past (like yours basically), and it solved this issue perfectly.
Click to expand...
Click to collapse
Thanks for your answer, Digdis! What I'm really looking for is not to have applications installed on the external SD card, since 2GB is more than enough for applications for me. What I really want is to have stuff that generally goes to /storage/sdcard0 in /storage/external_SD, because this is where my personal files and settings goes to. For example, if I download something, no matter what size, or record videos, I would expect them all to go directly to the SD card. I know a few applications, not all, can be directly configured to use the external card, but it would be a rather unintelligent way, unless Google has decided to throw basic Linux design out of the window.
Also, what you are telling me is that applications will fail to run if Android/data/ is on an external SD card? Because if I just install applications on SD card, it won't really solve my problem, because I have few applications installed, but data on /storage/sdcard0 tends to grow a lot.
teresaejunior said:
Thanks for your answer, Digdis! What I'm really looking for is not to have applications installed on the external SD card, since 2GB is more than enough for applications for me. What I really want is to have stuff that generally goes to /storage/sdcard0 in /storage/external_SD, because this is where my personal files and settings goes to. For example, if I download something, no matter what size, or record videos, I would expect them all to go directly to the SD card. I know a few applications, not all, can be directly configured to use the external card, but it would be a rather unintelligent way, unless Google has decided to throw basic Linux design out of the window.
Also, what you are telling me is that applications will fail to run if Android/data/ is on an external SD card? Because if I just install applications on SD card, it won't really solve my problem, because I have few applications installed, but data on /storage/sdcard0 tends to grow a lot.
Click to expand...
Click to collapse
OK understood. First of all 2GB seems a bit low for both ROM and apps, but if you say it works for you...
Now, regarding automatic download of pics etc. to SD. You can try Xposed module Downloads2SD . Didn't try it, but you can give it a try.
You can actually do that by telling the system to mount them differently but LG handles that by initiation not fstab. I can try and help you.
Didn't explain it very well. Mount the External SD as sdcard0 and sdcard0 as External_sd so the phone will safe on sdcard0 which we just made the external_SD. There can be problems with pictures recognition or music stuff like that but it should work.
Thanks a lot, @Digdis, I'll keep everything you said for reference.
@christi9503 OK, please, let's try it!
teresaejunior said:
Thanks a lot, @Digdis, I'll keep everything you said for reference.
@christi9503 OK, please, let's try it!
Click to expand...
Click to collapse
Are you rooted with a custom recovery? We need root for this and also you need to give me some files.
christi9503 said:
Are you rooted with a custom recovery? We need root for this and also you need to give me some files.
Click to expand...
Click to collapse
Yes, it is rooted, but what do you mean with "a custom recovery"?
teresaejunior said:
Yes, it is rooted, but what do you mean with "a custom recovery"?
Click to expand...
Click to collapse
CloworkMod(CWM) or TWRP recovery. So you can flash flashable zip.
christi9503 said:
CloworkMod(CWM) or TWRP recovery. So you can flash flashable zip.
Click to expand...
Click to collapse
Are both supported on this device?
teresaejunior said:
Are both supported on this device?
Click to expand...
Click to collapse
Search around the forum a guy around ported all from what I know. Anyway install one of the recoveries to get ready.
What I want you to do now is this:
Check in storage path (with a root explorer) what folder you have like sdcard0, external_sd etc. Tell me all and what is the address (where it links)
EX: sdcard0 -> internal storage.
Also go in system/etc/ and copy me with a root explorer to sd card and then upload it on forums this file : init.qcom.post_boot.sh
christi9503 said:
Search around the forum a guy around ported all from what I know. Anyway install one of the recoveries to get ready.
What I want you to do now is this:
Check in storage path (with a root explorer) what folder you have like sdcard0, external_sd etc. Tell me all and what is the address (where it links)
EX: sdcard0 -> internal storage.
Also go in system/etc/ and copy me with a root explorer to sd card and then upload it on forums this file : init.qcom.post_boot.sh
Click to expand...
Click to collapse
Installing will probably take me some time, because Android is refusing to install anything now saying I don't have enough free space (although I have 199MB, but maybe it thinks is too little). The information you have requested I have already:
There is /sdcard/, which is just a symlink to /storage/sdcard0/.
/storage/sdcard0, which is the internal memory, is mounted like:
Code:
/dev/fuse /storage/sdcard0 fuse rw,nosuid,nodev,relatime,user_id=1023,group_id=1023,default_permissions,allow_other 0 0
And there is also /storage/external_SD/, which is mounted like:
Code:
/dev/block/vold/179:33 /storage/external_SD vfat rw,dirsync,nosuid,nodev,noexec,relatime,uid=1000,gid=1015,fmask=0002,dmask=0002,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro 0 0
init.qcom.post_boot.sh is attached.
teresaejunior said:
Installing will probably take me some time, because Android is refusing to install anything now saying I don't have enough free space (although I have 199MB, but maybe it thinks is too little). The information you have requested I have already:
Click to expand...
Click to collapse
This is why I urged you to start moving apps to the SD card. Android will refuse to install anything on your internal memory unless you have at least 10% free space.
teresaejunior said:
Installing will probably take me some time, because Android is refusing to install anything now saying I don't have enough free space (although I have 199MB, but maybe it thinks is too little). The information you have requested I have already:
There is /sdcard/, which is just a symlink to /storage/sdcard0/.
/storage/sdcard0, which is the internal memory, is mounted like:
Code:
/dev/fuse /storage/sdcard0 fuse rw,nosuid,nodev,relatime,user_id=1023,group_id=1023,default_permissions,allow_other 0 0
And there is also /storage/external_SD/, which is mounted like:
Code:
/dev/block/vold/179:33 /storage/external_SD vfat rw,dirsync,nosuid,nodev,noexec,relatime,uid=1000,gid=1015,fmask=0002,dmask=0002,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro 0 0
init.qcom.post_boot.sh is attached.
Click to expand...
Click to collapse
Well install recovery by adb with dd (in shell).
---------- Post added at 06:43 PM ---------- Previous post was at 06:31 PM ----------
@teresaejunior
Under /mnt (on the root I think) you will have some folder like sdcard, external_SD etc inside that folder. Tell me what folders are there and the one that gets you in internal and the one that gets you in external pls.
CWM is installed!
In /mnt there are:
Code:
asec
obb
sdcard -> /storage/sdcard0
secure
teresaejunior said:
CWM is installed!
In /mnt there are:
Code:
asec
obb
sdcard -> /storage/sdcard0
secure
Click to expand...
Click to collapse
Ok gonna give you a flashable zip in a second that will replace your post boot script. If it goes into bootloop we got a backup don't worry.
teresaejunior said:
CWM is installed!
In /mnt there are:
Code:
asec
obb
sdcard -> /storage/sdcard0
secure
Click to expand...
Click to collapse
Flash this and tell me if they are swapped. Through CWM.
View attachment SwapL32.zip
christi9503 said:
Flash this and tell me if they are swapped. Through CWM.
View attachment 3082829
Click to expand...
Click to collapse
I think it swapped, but now many applications are crashing or failing to open files. I copied all files from sdcard0 to external_SD and rebooted, but it still doesn't seem to help. Maybe I should have formatted the external SD to ext*?
teresaejunior said:
I think it swapped, but now many applications are crashing or failing to open files. I copied all files from sdcard0 to external_SD and rebooted, but it still doesn't seem to help. Maybe I should have formatted the external SD to ext*?
Click to expand...
Click to collapse
Nope you do not need to format it in order to work. Just make a clean install and use this swap. Maybe you copied them wrong. If the swap worked all is fine my friend.
christi9503 said:
Nope you do not need to format it in order to work. Just make a clean install and use this swap. Maybe you copied them wrong. If the swap worked all is fine my friend.
Click to expand...
Click to collapse
OK, thank you so much, now _this is_ going to take a good time!

Categories

Resources