This is a simple and effective (moves most space hogging folders from internal memory to sd-ext) APP2SD solution.
It moves the following things from /data partition to ext partition on SD card:
/data/app => /sd-ext/app
/data/app-private => /sd-ext/app-private
/data/dalvik-cache => /sd-ext/dalvik-cache
and creates symlinks to new locations in place of original folders.
Solution consists of 2 via recovery flashable ZIPs:
sd-ext_patch-signed-vXX.zip - this updates/creates CyanogenMod 7/9 script that mounts SD card ext partition to /sd-ext so /sd-ext can be any ext version (by default it can be only ext3) and installs e2fsck. This must be re-flashed after each ROM update (unless you know that ROM will mount your /sd-ext out of the box).
to_sd-ext_patch-signed-vXX.zip - actually moves folders to ext partition on SD card. This can be flashed only after first boot into ROM after wiping /data. It should be re-flashed only in conjunction with wiping /data and /sd-ext.
This mod requires ext2/ext3/ext4 partition on SD card.
Always make full Nandroid backup before flashing this mod or updating ROM with mod installed!
Disclaimer: I am not responsible for anything that may happen as a result of using this mod.
Installation/usage:
To install mod on a working ROM:
Flash sd-ext_patch-signed-vXX.zip via Recovery.
Flash to_sd-ext_patch-signed-vXX.zip via Recovery.
After updating ROM:
Re-flash sd-ext_patch-signed-vXX.zip without booting into updated ROM.
After wiping /data from Recovery:
Delete moved folders from /sd-ext (in most cases you will want to do this by wiping /sd-ext from Recovery).
Boot into your ROM.
Re-flash to_sd-ext_patch-signed-vXX.zip via Recovery.
This mod is tested with CyanogenMod 7 (7.1 by mik_os and 7.2 official builds) and CyanogenMod 9 by hephappy and Amon RA recovery 3.0.6.
If you are using Clockworkmod Recovery see this post.
+1
Is this mod developed by you?
DJoptimus-One said:
Is this mod developed by you?
Click to expand...
Click to collapse
Yes
DavisNT said:
Yes
Click to expand...
Click to collapse
Nice work, I'm surely gonna try
Keep up.
Good work here!! Really nice to see some REAL development here
Will try it and report soon.........
Sent from heaven, wandering with Steve Jobs
Any feedback yet? Would love to give it a try :thumbup:
Sent from my LG-P500 using XDA
FitAmp said:
Any feedback yet? Would love to give it a try :thumbup:
Sent from my LG-P500 using XDA
Click to expand...
Click to collapse
Don't ask for that, try it yourself!!
nice work will try
Does this work on gb?2.3.3?
How to move app's ? Does this automatically moves it?
Sent from my LG-P500 using XDA
Just flashed on cm9 weekly... so for so good
Sent from my LG-P500 using XDA
Good work. Nice example of KISS approach - three symlinks + few lines of other code
dynamite33 said:
Does this work on gb?2.3.3?
How to move app's ? Does this automatically moves it?
Click to expand...
Click to collapse
You can make full Nandroid backup (Nand backup in recovery) and try whether it works on your ROM.
This requires the following things:
ext partition on SD card (you must have partitioned your SD card)
ROM that supports init.d scripts
kernel that supports ext filesystem version that is on SD card
You can test all this by (making full Nandroid backup and) flashing sd-ext_patch-signed-vXX.zip, booting in Android and issuing the following commands in Terminal Emulator:
Code:
su
mount
mount | grep sd-ext
If you see line like this somewhere in the output:
Code:
/dev/block/mmcblk0p2 on /sd-ext type ext4 (rw,noatime,nodiratime,barrier=1,data=ordered)
then /sd-ext is mounted and you can proceed to flashing to_sd-ext_patch-signed-vXX.zip.
Apps are moved when flashing to_sd-ext_patch-signed-vXX.zip.
DavisNT said:
You can make full Nandroid backup (Nand backup in recovery) and try whether it works on your ROM.
This requires the following things:
ext partition on SD card (you must have partitioned your SD card)
ROM that supports init.d scripts
kernel that supports ext filesystem version that is on SD card
You can test all this by (making full Nandroid backup and) flashing sd-ext_patch-signed-vXX.zip, booting in Android and issuing the following commands in Terminal Emulator:
Code:
su
mount
mount | grep sd-ext
If you see line like this somewhere in the output:
Code:
/dev/block/mmcblk0p2 on /sd-ext type ext4 (rw,noatime,nodiratime,barrier=1,data=ordered)
then /sd-ext is mounted and you can proceed to flashing to_sd-ext_patch-signed-vXX.zip.
Apps are moved when flashing to_sd-ext_patch-signed-vXX.zip.
Click to expand...
Click to collapse
Ok thanx a lot! Will try it.
Sent from my LG-P500 using XDA
hi DavisNT
i use Link2sd now, and want to try ur script, can i remove link2sd and use ur script without problem and without losing my apps ?
GonDr said:
i use Link2sd now, and want to try ur script, can i remove link2sd and use ur script without problem and without losing my apps ?
Click to expand...
Click to collapse
Try it, but remember to take full Nandroid backup before trying.
You can do this:
do full Nandroid backup from recovery
With Link2SD move all applications back to internal memory
delete mount scripts created by Link2SD (probably there is a kind of uninstall option in Link2SD)
install my mod
If you don't have enough space in internal memory, then it is possible to use Titanium Backup to backup and restore apps (however I am not sure whether Titanium Backup can backup data of applications linked with Link2SD - probably can, but I am not sure).
DavisNT said:
Try it, but remember to take full Nandroid backup before trying.
You can do this:
do full Nandroid backup from recovery
With Link2SD move all applications back to internal memory
delete mount scripts created by Link2SD (probably there is a kind of uninstall option in Link2SD)
install my mod
If you don't have enough space in internal memory, then it is possible to use Titanium Backup to backup and restore apps (however I am not sure whether Titanium Backup can backup data of applications linked with Link2SD - probably can, but I am not sure).
Click to expand...
Click to collapse
I don't think that titanium can restore anything to sdext, it just saves anything, including linked stuff and if trying to restore everything together it will fail, if the total of backed apps is larger than internal storage...
However, if link2sd is installed, the later will start linking data/apps 'on the fly' as Tib restores them. That's why it is essential to install link2sd or similar before going to batch-restore everything.
I guess this script should handle it in a similar way? I'm going to try anyway.
My idea was backing up most of apps with Titanium Backup while using Link2SD, then removing them (and moving left apps back to internal memory, uninstalling Link2SD mount scripts) and restoring after installing my script (Move to sd-ext).
Move to sd-ext links all applications (and dalvik cache, but not application data and library files extracted to data folders) at once - Titanium Backup will restore directly to SD card
can you explain me what's the difference between this mod and d2sd ungaze?
thanks
mutia said:
can you explain me what's the difference between this mod and d2sd ungaze?
thanks
Click to expand...
Click to collapse
If I correctly got what D2SD ungaze does, then it moves applications, applications data and libraries (/data/app, /data/app-private and /data/data) to SD card ext partition and leaves Dalvik cache (/data/dalvik-cache) on internal memory (/data partition).
While my mod moves and links applications and Dalvik cache (see first post in this thread for details), leaving all other folders (some system configuration and application data and libraries) in internal memory (/data partition).
Also technical implementation is very different from my mod. D2SD ungaze copies everything and links back certain things. It looks like D2SD ungaze also doesn't free space on /data partition.
DavisNT said:
You can make full Nandroid backup (Nand backup in recovery) and try whether it works on your ROM.
This requires the following things:
ext partition on SD card (you must have partitioned your SD card)
ROM that supports init.d scripts
kernel that supports ext filesystem version that is on SD card
You can test all this by (making full Nandroid backup and) flashing sd-ext_patch-signed-vXX.zip, booting in Android and issuing the following commands in Terminal Emulator:
Code:
su
mount
mount | grep sd-ext
If you see line like this somewhere in the output:
Code:
/dev/block/mmcblk0p2 on /sd-ext type ext4 (rw,noatime,nodiratime,barrier=1,data=ordered)
then /sd-ext is mounted and you can proceed to flashing to_sd-ext_patch-signed-vXX.zip.
Apps are moved when flashing to_sd-ext_patch-signed-vXX.zip.
Click to expand...
Click to collapse
i flashed the first zip file, then made this test through Terminal Emulator and got a line similar to the one you mentioned (my sd-ext is type 3, and the info in brackets was a bit different).
then i flashed second zip file.
the free RAM space increased (which necessarily means that things were moved to the sd-card, right?)
i then installed an app - and saw RAM decreasing accordingly, plus - the sd-ext folder is empty
how can i know if it works ?!?
hey guys ,
I faced this error a few times :my sd-ext partition used to become read only automatically . Due to this , I could not link any apps to sd-ext .
when I Googled it , I found that the fs converts sd-ext partition to read only as safety if it might get corrupted
formatting the sd-ext will make it read write but you will lose you data .
To solve this just follow this steps so that the data is not lost:
1.make a nandroid backup of current rom
2. go in recovery mode- mount and storage and format sd-ext ONLY
3.then go in backup and restore - advance restore . Select the nandroid file you just backed up
there will be options to restore just the system or just the data etc
4.choose sd-ext
it will check the md5 and restore your sd-ext partition making it read write too !
5. reboot to your rom
Sent from my GT-S5670 using xda premium
Sent from my GT-S5670 using xda premium
u can also directly select ext 4 in link2sd.....
if u hav already partitioned sd card.........
if the tom had ext4 support den do dis.....
it will never fail........
PRESS THANX IF I HELPED U
Please help me...I flashed the FlyROM V4 correctly but its stuck at boot animation...when i go to mount sd-ext..its shows "Error mounting sd-ext"..is that the problem? If it is..how to solve it?
Make Sure You Made A Sd-Ext Partition Correct, To Check Whether You Made A Partition Correct Or Not, Just Mount Sd-Ext In Recovery, If It Mounts Without Any Error Then Just Go Ahead, But If It Shows An Error, It Means You Didn't Make A Partition Correct. So Now What You Need To Do Is:
1. Don't Partion Your SD Card By Using Recovery.
2. Partition It Via "Minitool Partition Wizard" Manually.
3. Create A Ext 4 Partition As Primary.
4. Now, Install Yannou's Recovery (The One Which You Install While Rooting)
5. Finally, Mount Sd-Ext And Flash Any Sense 4 Rom..
Note: Don't Use CWM Recovery, It Never Mount Sd-Ext At Any Cost.. Use Yannou's Recovery Or Philz Touch Recovery Instead..
Sent from my HTC Explorer using xda premium
thanks for replying here..i got the problem solved by just
1. removing old partitions
2. changing to philz recovery
3. making a new partition using philz and then flashing..
But now am unable to install any kind of memory script to increase internal memory..even after installing successfully .. the memory isnt increasing..what's wrong?
First open ur rom zip, navigate to system/etc/init.d and remove that 78mv2ext file and replace it with ur desired script and then reflash rom..
But do this at your own risk, if u get into a bootloop just reflash the rom with 78mv2ext script again..
Note: in sense roms, internal memory will always be 150 mb, but when you install apps its internal memory will not decrease as it decreases usually because of that Sd-Ext Partition you created..
Sent from my HTC Explorer using xda premium
lol i didnt know internal memory is always 150mb..but it doesnt decreases..if its true..then there's no problem.
Hi,
I am on TWRP 2.6.3.1 and CM11, but I can´t mount ext. SDcard for backup or flashing ROMs. I have to copy them to internal storage before flashing or restore something. Is this a bug in newest TWRP? Backup and restore to internal storage went well.
greets Lecter224
Lecter224 said:
Hi,
I am on TWRP 2.6.3.1 and CM11, but I can´t mount ext. SDcard for backup or flashing ROMs. I have to copy them to internal storage before flashing or restore something. Is this a bug in newest TWRP? Backup and restore to internal storage went well.
greets Lecter224
Click to expand...
Click to collapse
Nope, I don't seem to have that problem, are you switching the partition being viewed at the top of the file manager?
cmendonc2 said:
Nope, I don't seem to have that problem, are you switching the partition being viewed at the top of the file manager?
Click to expand...
Click to collapse
I can´t switch to ´/sd-ext´ . The log says: "E: Unable to mount external_SD" eveytime I want to mount it or wipe it. The SDCard ist readable in CM11.
Lecter224 said:
I can´t switch to ´/sd-ext´ . The log says: "E: Unable to mount external_SD" eveytime I want to mount it or wipe it. The SDCard ist readable in CM11.
Click to expand...
Click to collapse
Is it formatted correctly for Android? FAT32 works fine.
cmendonc2 said:
Is it formatted correctly for Android? FAT32 works fine.
Click to expand...
Click to collapse
Yes, it is, FAT32. Formated on Win7 and with CM11. It is the SDcard in dock, not MicroSD in tablet!
Please help which Recovery supports SD-Cache[ext-4] backup, I am using PLL2 OC Method by Cute_Prince
muraari4u said:
Please help which Recovery supports SD-Cache[ext-4] backup, I am using PLL2 OC Method by Cute_Prince
Click to expand...
Click to collapse
None of the recoveries support backup of sd cache partition.. As far as cache is concerned recovery doesnt mount sd ccache partition and neither it detects the cache partition.. So to say there is no recovery that takes backup of SD cache..
shubhojit89 said:
None of the recoveries support backup of sd cache partition.. As far as cache is concerned recovery doesnt mount sd ccache partition and neither it detects the cache partition.. So to say there is no recovery that takes backup of SD cache..
Click to expand...
Click to collapse
Thank you,
if i backup my rom i,e[OC kernel PLL2 method] its backup only SD-DATA and no SD-CACHE and when i restore backup its work or not? that
means every time a problem happen i want to restore my backup but there is no recovery that takes SD cache backup,
so what to do every time fresh install the Rom? or any another way
[Sorry for my bad English]
muraari4u said:
Thank you,
if i backup my rom i,e[OC kernel PLL2 method] its backup only SD-DATA and no SD-CACHE and when i restore backup its work or not? that
means every time a problem happen i want to restore my backup but there is no recovery that takes SD cache backup,
so what to do every time fresh install the Rom? or any another way
[Sorry for my bad English]
Click to expand...
Click to collapse
SD Cache will work plus that partition doesnt store any of your data so backing up or restoring wont affect your ROM or any operations in the ROM.. While restoring just make sure SD cache is present or else you wont be able to OC.. You will be able to restore your phone but wont be able to OC unless and until you dont delete SD cache while restoring..
shubhojit89 said:
SD Cache will work plus that partition doesnt store any of your data so backing up or restoring wont affect your ROM or any operations in the ROM.. While restoring just make sure SD cache is present or else you wont be able to OC.. You will be able to restore your phone but wont be able to OC unless and until you dont delete SD cache while restoring..
Click to expand...
Click to collapse
Thank you very much, for clarified my doubts