New: XDA launches forum for app developers. Discuss coding, tools, marketing, and more.
XDA Developers Android and Mobile Development Forum
Forgot your password?
 
Post Reply+
Tip us?
 
wolfilein
Old
(Last edited by wolfilein; 26th December 2010 at 07:40 PM.)
#1  
Senior Member - OP
Thanks Meter 51
Posts: 223
Join Date: Aug 2010

 
DONATE TO ME
Arrow [Howto] App2sd Step by step

a big part of this new tutorial is not from me, credits go to tot31

New version out !!


Now you can choose if you also want to move the dalvik cache an the /data/data directory to sd (if you have an slow sd-card this will be a bit laggy) (to use this you can now use the update funktion)

and i've added an update funktion and protectet the install function so now you can't install app2sd two times an brick your fimrware

and if this help you you can help/thanks me

If You have an x10 mini (pro) go here :

http://forum.xda-developers.com/showthread.php?t=804574



The leds on boot are Now working :





blue means:

no proplem with sd card booting normal

purple/voilet means
sdcard malfunktion booting with failsafe



.

How To : App2sd on Xperia X10i

Pre Installation.
Root the phone by using z4root ( http://forum.xda-developers.com/showthread.php?t=833953 )

Step 1 : Preparing your micro SD Card.
Please refer to this link ( http://forum.xda-developers.com/wiki/index...rd_partitioning ) on how to prepare your micro sd card.

For better performance I would advise that you use a Class 10 card instead of the original card that comes with the phone because the card is only Class 2 card. For more infomation on speed class rating of sd card please go here -> http://en.wikipedia.org/wiki/Secure_Digital

An excerpt taken from wikipedia :-
The following are the ratings of some currently available cards:
* Class 0 - These cards do not specify performance, which includes all legacy cards prior to class specifications.
* Class 2 - Minimum of 2 MB/s performance. Lowest speed for SDHC cards.
* Class 4 - Minimum of 4 MB/s performance.
* Class 6 - Minimum of 6 MB/s performance.
* Class 10 - Minimum of 10 MB/s performance.

Note : The recommended maximum size of ext2 partition is 1.4GB. I've tried 3GB before and ended up with unstable system and eventually crash the phone. So if you're really greedy since you've bought a 16GB or 32GB card to partition the ext2 more than the recommended size and if your phone is unstable, you've been warn but normaly 1.4 GB are enough

Step 2 : Download the related files.
1. App2sd : see attachment
2. adb shell : see attachment

Step 3 : Enabling USB Debugging mode on you phone.
Go to Settings -> Applications -> Development -> USB Debugging (check this option).

Step 4 : Installing App2sd.
Create a folder name adb in your pc and extract all the files from adb.zip into this folder.

Connect your phone to your pc and mount the sd card. Extract all the file from app2sd2.1.zip to the root of your sd card. Make sure to unmount the sd card before continue the next step.

In your pc open up a dos terminal box by typing cmd in the Search programs and files box.

Type

cd /adb

then type

adb shell

then type

sh /sdcard/app2sd.sh

you'll be presented by this screen...
+________________________________+
|********************************|
|*Welcome To wolfilein's App2sd *|
|*installing script *|
|********************************|
+------------------------------------------+

~this version should be go on any device ~

+___________________+
|********************|
|* Menu *|
|* *|
|*[0] install app2sd *|
|* *|
|*[2] exit *|
|********************|
+-------------------------+
[0]


now just press the enter key & wait.

Important : Make sure to set your phone screen timeout to the max because Superuser will ask for your permission to allow this script to run. If your screen goes blank, you can't see this prompt and the installation will fail.

after a while you'll get this..

busybox is /system/bin/busybox
rm failed for /etc/mount_sd.sh, No such file or directory
+________________________________+
|********************************|
| finished going reboot now |
|********************************|
+-----------------------------------------+


the both messages above doesn't mean that your installation has failed

Finally after a reboot, your phone is ready with app2sd. From now on when you install any applications it will save into your sd card.

Disclaimer : Do this at your own risk. I will not responsible if any injuries or damage occur to you or your phone
Attached Files
File Type: zip app2sd.zip - [Click for QR Code] (978.6 KB, 7562 views)
File Type: zip adb.zip - [Click for QR Code] (784.1 KB, 7753 views)
File Type: zip app2sd2.1.zip - [Click for QR Code] (949.3 KB, 8394 views)
The Following 12 Users Say Thank You to wolfilein For This Useful Post: [ Click to Expand ]
 
seanswn
Old
#2  
Junior Member
Thanks Meter 0
Posts: 4
Join Date: Jan 2010
Good, But can someone make a more detail guide on step by step to get this done.

Thank you
 
MrPappy86
Old
#3  
Senior Member
Thanks Meter 4
Posts: 219
Join Date: Dec 2008
How to partition the sd card without bootlodaer?
Sorry if this is a noob question.
For all ROM developers in this forum:
http://www.funpic.hu/swf/thks.html

Samsung Omnia 7

Windows Phone 7.8 User (7.10.8835.35)
[OM7] mi7Rom WP7.8 Edition Nokia Mod v2
 
zephyrix
Old
#4  
Senior Member
Thanks Meter 0
Posts: 256
Join Date: Apr 2010
Quote:
Originally Posted by Wenner View Post
How to partition the sd card without bootlodaer?
Sorry if this is a noob question.
Use a MicroSD reader and a linux system?
 
zdzihu
Old
#5  
zdzihu's Avatar
Recognized Developer
Thanks Meter 5157
Posts: 647
Join Date: Sep 2008

 
DONATE TO ME
No need for card reader, just plug the phone and use parted
The Following 2 Users Say Thank You to zdzihu For This Useful Post: [ Click to Expand ]
 
wolfilein
Old
#6  
Senior Member - OP
Thanks Meter 51
Posts: 223
Join Date: Aug 2010

 
DONATE TO ME
i will add some pictures if a have the time
 
devein
Old
#7  
Member
Thanks Meter 9
Posts: 78
Join Date: May 2008
if I understand this correctly, this script essentially creates link to sd card directory, where previously is a directory of apps.

nice trick, but without any failsafes.
I mean, if you remove sd card you are without /data/app/ directory at all!

there should be some failsafe...

method 1:

script at startup checking:
  • if there is a symbolic link to sdcard? (check attributes of /data/app/ )
  • if directory is a symbolic link and no data exists inside (for example specific directory/file is not existent) ->point the symbolic link to /data/app2/ directory.
to make it work,
/system/app2 directory should be created:
Code:
busybox cp -a /data/app /data/app2
instead of removing it in your script:
Code:
"rm -r /data/app "
also make some specified light flash on the phone, to warn user that old backup copy is used because of sd card malfunction (i've documented a way to do this in:

http://forum.xda-developers.com/wiki/index.php?title=Xperia_X10#Leds_and_backglight
)

for example pink led:
Code:
echo 15 > /sys/class/leds/ledc:rgb1:red/brightness
echo 2 > /sys/class/leds/ledc:rgb1:green/brightness
echo 3 > /sys/class/leds/ledc:rgb1:blue/brightness
method 2:
even better way would be that sd card partition is mounted on every start on system OVER old /data/app/.

this works always in linux - you can mount over non-empty directory without a problem

so, if the sd card is not accessible - dont mount sd card apps directory and like in method 1, flash the led or something, and old apps directory would work without doing anything more

to check:
- does mounting over non-empty directory works also in android?
- what is the way to add startup script init in the system?
(possibly executed from sd card - when no card is visible, the script would not execute, right :P )
- why there is a 1.4GB limit ? is this a ext2 limit on android ?
 
wolfilein
Old
#8  
Senior Member - OP
Thanks Meter 51
Posts: 223
Join Date: Aug 2010

 
DONATE TO ME
yes doun't normaly you don't remove your sdcard
 
zdzihu
Old
#9  
zdzihu's Avatar
Recognized Developer
Thanks Meter 5157
Posts: 647
Join Date: Sep 2008

 
DONATE TO ME
Quote:
Originally Posted by devein View Post
- does mounting over non-empty directory works also in android?
- what is the way to add startup script init in the system?
(possibly executed from sd card - when no card is visible, the script would not execute, right :P )
- why there is a 1.4GB limit ? is this a ext2 limit on android ?
1. Yes
2. exec your script from either /etc/mount_iso.sh or /system/drm/DxDrm/drm.sh
3. There is no such limit, rather an advised value
 
Luhccas-X10
Old
#10  
Senior Member
Thanks Meter 20
Posts: 218
Join Date: May 2010
Location: Vitória - Espírito Santo
So... It works or not?

Tags
app2sd, xperia