SD Card partitioning on MTD ROMs - Samsung Galaxy S (4G Model)

Hi There
Can someone explain what he\she did to partition SD card, and make all apps get installed on it.
Please note :
1. I don't want to use Titanium backup for this usage. I don't have the paid version and I'm tired of doing this one app at a time.
2. I saw some guides on the net, but they were all for GB.
(partition the microSD on PC using minitool) -can we use ext4 on our MTD ROMs ? What is the 1st partition for ? and the 2nd ?
(install busybox and super user) - Is it still needed ? (MIUI for example has LBE as su).
(install Link2SD) - Is it always in memory ?
(reboot and put partitioned SD card)
(Define Link2SD)
3. I also saw swapper instructions but I can manage with 170MB free RAM memory I get after removing all unnecessary system apps, and I remember ppl saying then that it kills the SDCard very quickly.
If someone has a clear guide or instructions that he knows work, that will be nice.
Thanks in advance.

Step 1. Partition your SD card to have a sd-ext partition. This can definitely be ext2 or FAT16. Anything else depends on your kernel. Most of them do support ext3 and 4, but... start with something fairly basic.
Regarding recoveries:
TWRP has always failed for me on this, so I'd avoid that.
This may be doable in CWM. I've seen reference to that newer versions of CWM removed the partition option, so you might need to flash an ICS ROM with an older kernel, repartition, and then flash back to the one you want.
Also note that if you use CWM to repartition, your SD-card will be wiped. So do a backup first.
Step 2. Install Mounts2SD. Either from XDA or the Play Store. Even if you do take it from the Play Store to get update notifications, I highly suggest grabbing the recovery script from the XDA thread so that you can get back your shifted applications without needing to re-download and install M2SD, since it likes to be on internal which means... shifted off.
Step 3. Open Mounts2SD. Grant SU rights at whatever point it asks for it during step 3. Hit the menu button. Go to Application Settings. Install the Startup Script. Tell it to use the built-in busybox as well, so that you don't need to install anything or worry about it failing. Back out of the Application Settings.
Step 4. Press on the Wrench to go into the actual specific settings. I currently have forced Cache, 1% Storage Threshold, Applications are the only bit moved, the File System Check is on and using the Ext4 Driver, 128KB Deadline for Internal and 4096 with Deadline for External, and Safe Mode is disabled. But decide on what you want yourself, set it, go back to the Eye to see your current info.
Step 5. Reboot.
Step 6. Wait 1-30 minutes for it to finish moving all your stuff around.
Step 7. Unlock your phone, open Mounts2SD, and make sure everything looks pretty on that first 'Eye' info tab. If you like it then close Mounts2SD and keep going on your merry way. If you don't like it or you've done something like offload your data and now your phone is wretchedly slow, go to the Wrench, change your settings, go back to the Eye, and reboot again. Repeat until satisfied.

I thought it would be simplier.
A few more questions:
1. If I partition SD on PC, then I don't need any partitioning on recovery so it should work fine even on TWRP or advanced CWMs. Am I right?
2. Why do I need scripts for? Isn't the app enough?
3. Why should/could it possibly slow down my device? TB 'move to SD' for all doesn't slow my device what so ever.
4. How and where do I see what partition is used for what?
5. How much RAM does the app take?
6. Have you tried other apps link2sd or something CM has built in I think.?
Thanks.
sent from me

New answers to new questions.
1. Skip step 1 if you've done it on your PC. I just suggested recovery as that's easy... if you've made your sd-ext partition on the PC, step 1 is done.
2. No clue on Link2SD. I use Mounts2SD instead since it lets me set things. It probably does the same thing though and sets a init.d script that gets run during startup.
3. True. For some reason though having all your data moved to sd-ext makes our phone go to a crawl. Same if you move off the dalvik.
4. That's in Mounts2SD. No clue how you can see if you're using Link2SD.
5. For Mounts2SD, none while it's being used, since it just runs as a startup script. The app is just to control the script.
6. Not successfully. I had tried 5 or 6 different apps back a year ago or so when I first started playing with sd-ext and Mounts2SD was the best and free, so... never looked back after that. Now you can also do some system-flag tweaking if you want to donate, but the sd-ext stuff is all free.

I was able to successfully partition SD and use mount2sd on 4.3 SlimBean.
however, it was rather slow.
CM 10.1 and CM10.2 by DJL. did not allow me to partition nor did they recognize SlimBean's partition even if I replaced them kernel (to NilTMT).
I'm currently using CM10.1 which is stable as a daily driver and manually swapping apps with TB, I hate it, but this is the best combination I've come so far.
I sold my wife's SGS4G and upgraded her to SGS3 and hopefully in a year I will do the same. it had its moments, but on the bottom line it's a pretty ****ty phone with its lack of internal mem...but hey, it drove so many of us to go deeper and deeper trying to understand and made us more tecnolgical and solution oriented.

Mounts2SD worked for me on CM10.1, so not sure why it failed for you. Ah well.

A few things I have found...
Yes, you can partition on Windows, but you're really asking for trouble. It's not too bad download Ubuntu or the like and you can boot off a USB stick without touching your Windows install.
The TeamAcid kernels that I know of handle ext2/3/4 file systems. All kinds of arguments as to which are better. I personally use ext4 and don't find it obviously "slow" for the way I use my phone.
That said, what the boot scripts (which are part of a flashed "kernel" for the SGS4G) actually do with a "special" partition is another story. In some cases the first stages of booting will look for special partitions and mount them in pre-configured places. For example, the second partition of the removable card might be mounted on /sd-ext/ in many CyanogenMod ROMs. Many (most?) SGS4G ROMs don't have these "special" mount rules defined.
Moving an app to SD using the "native" approach just moves the app and none of its data to the SD card. It won't for example, move 25 MB of mail from /data/data to your microSD
Moving an app to SD (or anywhere else) doesn't keep it from generating its classes in /data/dalvik-cache -- It isn't "free" to have an app on SD as far as internal storage goes, even if it doesn't write any data.
Moving an app to SD will absolutely slow down your boot time. It does it by creating a file that contains a file system that then gets read and mounted at boot time. You can watch the parade of them getting mounted using adb logcat. It can take a minute or two to mount them all. Once mounted, that double layer of file systems shouldn't slow you down too much, since it is basically a read-only kind of thing.
Scripts are required since you need to be able to "fake out" the operating system as to where things are stored for anything (except if you just use the native app to SD method). In most cases you need new partitions mounted before the Android part of the OS starts running.
Some scripts are more robust than others.
TitaniumBackup (paid version) has a way to move data to an external partition. It works like a charm for me (64 GB Sandisk UHS-1 / Class 10 microSD). It was very tweaky for me to get it to recognize the ext4 partition the first time. It can bulk-move app data to the partition. I don't know which, if any, of the other scripts move the data to an external partition.
On my phone, an ext4 file system can be significantly faster than the internal yaffs, especially for write. Alas, it usually seems to be read that is a killer for most things in an well-written app. On my phone, yaffs can be faster than ext4 for short reads. Who knows how this would play out in real-world usage.
Other things that TitaniumBackup can do that help free up internal storage, at least in the paid version, are:
Dalvik cache cleanup
Integrate system Dalvik cache into ROM
Integrate update into ROM
Convert to system app

I can confirm Link2SD works where Mount2SD fails, which is an ext3 partitioned sd-ext on AOKP. it doesn't get any simpler than that.
sent from me

Related

[Script][A2SD]Darktremor 2.7.5.3 Beta 04 [Aria] (01/29/2011)

Introducing...
Darktremor Apps2SD 2.7.5.3 Beta 04
Date of Release: January 29, 2011
Download Current Version
Instructions - Change Log - Commands - ROM List - Developer's Guide
Darktremor Apps2SD Fan Page ----
Darktremor Apps2SD Development Group
Are you installing Darktremor Apps2SD on your phone? Here are the instructions to help you: Facebook
Are you a developer wanting to include Darktremor Apps2SD in your latest ROM? Here is the Developer Guide: Facebook
Click to expand...
Click to collapse
Update on Beta 4
It seems I'm getting mixed results with these betas. I'm not sure why this is occurring, some people have been able to get this working right while others have had a hard time with it.
Currently, I'm rebuilding the entire program. This takes a while because I have to figure out how to pack all these options into the program but make it small enough to where it will run correctly.
I will say that some of the beta features are coming back out...one of them is the search for a partition code. I suspect that code may be leading me into issues with certain platforms, so I'm going back to the 2.7.5.2 method of mounting (mmcblk0p2 or mmcblk1p2).
Also, parts of the code will use Busybox Ash (the only code that won't will be starta2sd, which will still use Bash for the time being). The startup code will definitely use Busybox Ash.
Until then, here are the links to the the last two betas and the last official release:
Version 2.7.5.3 Beta 04 - http://www.darktremor.info/files/a2sd/dtapps2sd-2.7.5.3-beta04-signed.zip
Version 2.7.5.3 Beta 03 - http://www.darktremor.info/files/a2sd/dtapps2sd-2.7.5.3-beta03-signed.zip
Version 2.7.5.2-1 - http://www.darktremor.info/files/a2sd/dtapps2sd-2.7.5.2-1-signed.zip
And, if you want past versions, you can view the repository: ftp://dtuser:[email protected] (ignore the smiley face...that's XDA doing that.)
Click to expand...
Click to collapse
Beta 04 took longer than I expected to release. I have done major changes to the code:
1. New commands: convert-ext4 - This will convert your EXT3 partition into EXT4. Just a friendly reminder on this command: Not every rom supports EXT4, so it is possible to go into a boot loop if you switch roms. Use with caution.
2. Reworked convert-ext3 (convert-ext4 gets similar code)...now a flag file is set before the reboot (no conversion is done before the reboot). At load time, the conversion is performed. This takes longer in the reboot process and you may think your phone has locked up...wait about five minutes before doing anything with the phone.
3. Repair is rebuilt...now it uses existing commands to repair the setup (reinstall, remove, cachesd, cachepart, nocache, datasd, nodata). Definitely shrinks the code.
4. Added fix_permissions program to the package. This may help with Superuser issues when using the datasd feature. It is used in reinstall, remove, datasd and nodata.
5. a2sd install is back!!! Both a2sd install and a2sd reinstall do the exact same thing.
6. Dalvik heap code has been shrunk and now creates a file called dalvikheap. Actually, the code has been doing this all along (since about 2.7.5.2, I think), but I never put the code in to use the file.
7. Low Memory Killer code has also been shrunk and uses a file caled dtset_lowmem to set the low memory killer parameter.
8. Replaced Busybox PS function with Toolbox PS. The issue with Busybox PS is that it gives a false reading when I look for android.process.acore (which is the main program when the GUI starts up). If that is present, the program thinks you are trying to run Darktremor without any command line parameters. This was because Busybox would report the process was there when, in reality, it wasn't (validated this when my phone was boot looping.) Toolbox's PS reports the correct setting. This should fix the bootlooping issues some people are experiencing.
9. New commands: usedtbusybox and usedefaultbusybox - these commands may help in diagnosing issues that is may be related to the native Busybox on your rom. a2sd usedtbusybox will use the Busybox that is packaged with Darktremor. a2sd usedefaultbusybox will turn back on the scan behavior of the program introduced in Beta 03.
10. Support for Darktremor Apps2SD version 2.7 and earlier has been discontinued. To upgrade correctly from one of those versions, use version 2.7.5.3 Beta 03b or earlier.
11. Finally fixed stalled boot issues (or at least my tests with several roms says so.)
See the change log for additional details.
You will notice that if the program runs repair and finds a problem, it will correct the issue and reboot. You will see a second reboot when the dalvik-cache clears (this is to fix timing issues with CyanogenMod...I can't control that startup as well as I can other roms). This only happens if repair is ran or you flash a new rom (as repair will realign all data). If you are upgrading from a previous version of Darktremor, you should not see the reboots.
Click to expand...
Click to collapse
This is Darktremor Apps2SD, a multipurpose program that primarily allows a user to execute applications created for the Android OS on their Secure Digital card (with the proper setup...more on that later). But, Darktremor Apps2SD is all about stability. The goal is to be able for all users of the Android OS to be able to take advantage of a method to run their applications from a secure digital card.
But just because the Darktremor Apps2SD is all about stability, doesn't mean it isn't packed with features:
- Move applications (both free and paid) to the Secure Digital card.
- Move Dalvik Cache to run either from your Secure Digital card or from your cache partition and clears the cache on demand.
- Boot Loop Protection: prevents the phone from boot looping in the event the SD card could not be mounted.
- Dalvik JIT for faster performance on Roms which support it.
- User selectable sizes for the Dalvik heap sizes, allowing a user to freely optimize their system.
- Activate a swap partition on your SD card and sets how often the swap partition is utilized.
- Automatically fixes configuration issues.
- Users can check the free space on their SD card and check the installation to make sure all is setup correctly.
- Runs ZipAlign on demand...this makes your programs load faster.
- Built in help system for easy reference of commands.
- All features can also be reversed without repartitioning your Secure Digital card.
- New logging features assists in troubleshooting issues.
- Commands to set the Low Memory Killer feature at boot time. Great for those people who are the "set it and forget it" type.
- And more...
Darktremor Apps2SD is not the same as Froyo Apps2SD. Froyo Apps2SD creates a secure folder on the FAT32 section of your SD card (this is the section that you see when you mount your phone to your computer) and stores the programs there. This is nice as you don't have to do anything special with the phone, but it isn't backwards compatible with older versions of Android (Cupcake, Donut, Eclair) and, because of the way Froyo works, older programs not designed for Froyo will automatically stay on your internal storage (unless you install a program that forces the move to your SD card).
Darktremor Apps2SD takes a different approach. Based on the original CyanogenMod works, Darktremor Apps2SD uses symbolic linking to force Android into moving your applications to the SD card. Because Android will not allow anything to be ran from the FAT32 partition on your SD card (and, in Froyo, it will only allow you to run programs from a special folder), Darktremor utilizes filesystems called EXT2, EXT3 and EXT4. Each one of these filesystems is native to Linux (the operating system running Android), which allows you to run programs from them (same as, say, a computer running Ubuntu). This method is completely compatible with all versions of Android, including Froyo. In fact, you can run both the Darktremor Apps2SD and Froyo Apps2SD at the same time.
Check out the list of Roms that either have Darktremor Apps2SD installed or are compatible with Darktremor Apps2SD. Click on the link labeled ROM List at the top of this message.
what's the difference between the two installers?
The advanced installer uses updater-script, the same method that Cyanogen uses for CyanogenMod.
The other script is the standard update-script, for compatibility with older recovery programs.
Other than that one difference, they are identical.
hi2u2 said:
what's the difference between the two installers?
Click to expand...
Click to collapse
Bump...new version released: 2.7.5.2
why is it i have to run a2sd repair just to get this to boot otherwise it chokes out
http://pastie.org/1197625
rom: ported 2.2 sensui rom on droid1
using 512ext3 partition as mmcblk0p2 with the init.d startup method(same issue with the init.rc methed, not like that would matter)
Do you have a /data/dta2sd.log file? That would help me more than the log file you sent (the adb logcat is too late in the process for me to see what Darktremor is doing).
If you have the log file, send it to me at [email protected] and I'll see if I can find out what's going on.
EDIT: Jr33 may also be able to help out on this...he's got this working in two Motorola roms, so he may have to do something special with the rom to get the program to start. It may be a similar situation that I'm running into for the Samsung Galaxy S platforms.
jamezelle said:
why is it i have to run a2sd repair just to get this to boot otherwise it chokes out
http://pastie.org/1197625
rom: ported 2.2 sensui rom on droid1
using 512ext3 partition as mmcblk0p2 with the init.d startup method(same issue with the init.rc methed, not like that would matter)
Click to expand...
Click to collapse
Just want to make sure...
I am running Liberated R010. I have partitioned the class 4 sd card, in this order...6.5GB FAT 32, about 1GB Ext2, about 32MB Linux Swap. I have copied all of my old sd card into the 6.5GB partition. I'm wanting to stick this into the phone and let it do its thing. Will the apps be moved automatically? What control will I have during and after this big moment?
Do I need to reboot with the new card or can I do the unmounted hotswap?
Sent from my (liberated) HTC Liberty using XDA App
Apps will be moved automatically if the ROM supports A2SD+ or Apps2SD (Liberated should).
Not sure what you are meaning regarding "control". The move is pretty quick and happens at the start of the boot process. Technically, the user doesn't have control of the phone at this point.
duckredbeard said:
I am running Liberated R010. I have partitioned the class 4 sd card, in this order...6.5GB FAT 32, about 1GB Ext2, about 32MB Linux Swap. I have copied all of my old sd card into the 6.5GB partition. I'm wanting to stick this into the phone and let it do its thing. Will the apps be moved automatically? What control will I have during and after this big moment?
Click to expand...
Click to collapse
No...no hotswapping. The EXT2 or EXT3 partition is mounted...you could corrupt it. You will need to reboot with the card as the mounting of the EXT2 / EXT3 partition happens during boot time.
duckredbeard said:
Do I need to reboot with the new card or can I do the unmounted hotswap?
Sent from my (liberated) HTC Liberty using XDA App
Click to expand...
Click to collapse
I did tried as you recommended and nothing changed except for the size of the SD card. The partitioned card showed as 6.6GB, (instead of the full 8ishGB) but the internal memory stayed at 185MB. I used the live ubuntu method, 6.6GB fat 32, 1GB ext2, 32MB Linux. Partition session showed as successful.
Sent from my (liberated) HTC Liberty using XDA App
Okay, try this:
From the adb shell, type a2sd reinstall.
The reason for this is that, if you were running Darktremor without the SD card partitioned, boot protection would activate and set the NoA2SD flag.
a2sd reinstall will clear the flag and move the apps to the SD card. That should fix your issue.
duckredbeard said:
I did tried as you recommended and nothing changed except for the size of the SD card. The partitioned card showed as 6.6GB, (instead of the full 8ishGB) but the internal memory stayed at 185MB. I used the live ubuntu method, 6.6GB fat 32, 1GB ext2, 32MB Linux. Partition session showed as successful.
Sent from my (liberated) HTC Liberty using XDA App
Click to expand...
Click to collapse
Now that I'm on a real keyboard, I can better explain what got me to this point. Some of this you've heard before.
I did Nandroid backup, then copied all of my SD to a safe place on my PC. Partitioned the new Class 4 SD card using Linux LiveCd, with about 6.5GB Fat32, 1GB Ext2, and 32MB Linux swap. It took a few tries, I'm not a Linux person. Once It was successful, I went back into windows and looked at the card size. It was indeed about 6.5GB.
Powered off the Aria and inserted the SD card, then powered on like normal. No obvious change, other than the SD being smaller. No change to the internal storage. Found the darktremor .zip file and copied it to the root of my SD using a card reader, reinserted the SD (with power off) and rebooted in recovery, applied your .zip. Phone rebooted fine, again no changes.
I again tried to partition the card using ROM Manager, which had previously been unsuccessful on the new card. After it had been Linux partitioned the one time, ROM Manager seemed to have worked. I'd rather have more than 512MB Ext2, though.
I am perilously close to full on my internal storage, so I'm eager to get this going. Thanks for your replies.
hey tkirton,
upon installing 2.7.5.2 and running 'a2sd check', I see that swap does not start now ('partition not present or no swap support').
I installed it by rebooting into recovery and flashing the zip, same way I have been doing up until now.
Any ideas?
So, you setup the SD card via Rom Manager and all is working, but it didn't work via Linux LiveCD, correct?
It could be the EXT2 partition. It works, but because there is no journaling, the partition is more susceptible to corruption.
You may try the LiveCD method again. This time, create a 1GB EXT3 partition and make sure you unmount the partition before removing it (force removal while it is mounted is a good way to corrupt an EXT2 partition...can also corrupt an EXT3 partition). Don't worry about going into Windows to validate...you can do that with your phone.
I don't know if there is another recovery available to you. I run GodSpeed (based on Amon_RA's recovery) on my Hero and Amon_RA on my Evo. I know the Amon_RA recovery will allow you to select your EXT2/EXT3 size.
duckredbeard said:
Now that I'm on a real keyboard, I can better explain what got me to this point. Some of this you've heard before.
I did Nandroid backup, then copied all of my SD to a safe place on my PC. Partitioned the new Class 4 SD card using Linux LiveCd, with about 6.5GB Fat32, 1GB Ext2, and 32MB Linux swap. It took a few tries, I'm not a Linux person. Once It was successful, I went back into windows and looked at the card size. It was indeed about 6.5GB.
Powered off the Aria and inserted the SD card, then powered on like normal. No obvious change, other than the SD being smaller. No change to the internal storage. Found the darktremor .zip file and copied it to the root of my SD using a card reader, reinserted the SD (with power off) and rebooted in recovery, applied your .zip. Phone rebooted fine, again no changes.
I again tried to partition the card using ROM Manager, which had previously been unsuccessful on the new card. After it had been Linux partitioned the one time, ROM Manager seemed to have worked. I'd rather have more than 512MB Ext2, though.
I am perilously close to full on my internal storage, so I'm eager to get this going. Thanks for your replies.
Click to expand...
Click to collapse
Hmmm...works for both my Hero and Evo.
Which rom are you using? If you are using /dev/block/mmcblk1p3, it should work as it was introduced in this version.
I know this is going to sound stupid on my part, but are you sure swap has been working? The reason I ask is that earlier versions of CyanogenMod 6 Nightly Builds had the swap turned off in the kernel...of course, I didn't know that until I was working on another version of Darktremor (and I had already used three different versions of CyanogenMod prior to that).
hi2u2 said:
hey tkirton,
upon installing 2.7.5.2 and running 'a2sd check', I see that swap does not start now ('partition not present or no swap support').
I installed it by rebooting into recovery and flashing the zip, same way I have been doing up until now.
Any ideas?
Click to expand...
Click to collapse
I never got any different result from any method I tried. Except that after one attempt my Tasker widgets had lost their icons. I've put a lot into Tasker lately, which may explain my internal storage getting full.
I shall reattempt the Linux and pay particular attention to the mount status. I will also go with Ext3 if it is not a conflict with darktremor. Will the phone's storage be shown in addition to my partition (185+1024)? If my ROM (Liberated Aria R010) has DT A2SD, should I still install from .zip?
Sent from my (liberated) HTC Liberty using XDA App
Try flashing this one first: http://www.darktremor.info/files/a2sd/dtapps2sd-2.7.5.1-adv-signed.zip
That is 2.7.5.1...the first release was bugged...this is release 2. I don't know which one does Liberated Rom have.
If that works, then jump up to 2.7.5.2. Make a backup so you can restore if something goes wrong.
duckredbeard said:
I never got any different result from any method I tried. Except that after one attempt my Tasker widgets had lost their icons. I've put a lot into Tasker lately, which may explain my internal storage getting full.
I shall reattempt the Linux and pay particular attention to the mount status. I will also go with Ext3 if it is not a conflict with darktremor. Will the phone's storage be shown in addition to my partition (185+1024)? If my ROM (Liberated Aria R010) has DT A2SD, should I still install from .zip?
Sent from my (liberated) HTC Liberty using XDA App
Click to expand...
Click to collapse
tkirton said:
Hmmm...works for both my Hero and Evo.
Which rom are you using? If you are using /dev/block/mmcblk1p3, it should work as it was introduced in this version.
I know this is going to sound stupid on my part, but are you sure swap has been working? The reason I ask is that earlier versions of CyanogenMod 6 Nightly Builds had the swap turned off in the kernel...of course, I didn't know that until I was working on another version of Darktremor (and I had already used three different versions of CyanogenMod prior to that).
Click to expand...
Click to collapse
I am using /dev/block/mmcblk0p2. Followed the instructions here: http://forum.xda-developers.com/showpost.php?p=7372509&postcount=9
Ok...tried it again. Here's exactly what I did: Linux liveD method partition: 6.7GB Fat32, 1GB Ext3, 32MB Linux swap. I was sure I did the mount thing as well. Did nandroid backup then copied my old card (entirely) into the new Fat32. Stuck the new card into the powered off phone and booted into recovery. Installed the zip you posted in this thread. After install (with no problems) I reboot phone and no change to the indicated internal storage capacity. I am running liberated aria r010 which is purported to include dta2sd, but disabled by default. If this is my issue, how do I enable it?
Sent from my (liberated) HTC Liberty using XDA App

[GUIDE] Prep for App2SD and why do a "Wipe data / factory reset"

I put this short guide together because I tend to see a lot of confusion regarding what a "wipe data / factory reset" does to your phone.
These are the steps you should take before loading a new ROM:
1) Download your new ROM and relevant supporting or needed files like modem, alternate kernel, etc., and place them on your internal SD.
2) Backup your applications, settings, messages, etc., with a backup tool like Titanium Backup, image specific backup tool, etc.
3) Boot into recovery and run a “wipe data/factory reset"
4) Follow the developers ROM loading instructions.
When you perform a “wipe data/factory reset” the content of the following directories are deleted :
/data
/cache
/datadata
/sd-ext
/sdcard/.android_secure
Nothing else on your SD card (internal or external) outside of these directories is modified so it is safe to leave files outside of the above mentioned directories without fear of losing them. Your external SD card and SIM do not need to be removed. The goal here is load a new or updated ROM in as much a clean environment that you can. Files left behind in these, especially cache and davlik-cache can cause some of the strangest problems. The kind that nobody can really resolve.
/cache - This is the partition where Android stores frequently accessed data and application components to make these, as implied, respond much faster as well as faster to retrieve / access.
/datadata – This directory contains the library, database, user specific configuration files as well as log files for its specific application installed in the /data directory.
/data directory is where your contacts, messages, settings and apps that you have installed go. Wiping this partition essentially restores it to the way it was when you first booted it, or how it was after your last custom ROM install.
If your ROM uses an /sd-ext partition on your SD card for data storage your /data directory is mapped to /sd-ext and wiping the /sd-ext directory will result in losing your data.
/sd-ext is used for apps moved to your SD card. Your Android OS runs natively in an ext format while your SD card has a fat32 format, which is used typically for USB storage devices, Windows computers, etc.
The sd-ext partition is an additional partition on your SD card that acts as the /data partition when used with certain ROMs that have APP2SD or data2ext enabled. It is popularly used on devices that have little memory allotted to the /data partition. A misfortune that in my experience, Captivate does not partake in. Still, users who want to install more programs than the internal memory allows can take advantage of this partition and use it with a ROM supporting this feature.
The folder named .android_secure is where apps are stored when you perform the "move from phone to SDram/SD card" operation.
Consider this, Apps2SD uses the fat32 portion of your SD card, which is obviously limiting because it isn't Androids native file system. However, if you format your SD card, or partition a part of it as a ext file system, you can trick the phone into thinking it's part of the Android OS native environment. This will allow you to move applications, widgets, even cache and davlik cache over to it.
Disclaimer! I am not responsible for any damage you may cause to your phone or SD Card if you try to enable/use sd-ext.
To enable sd-ext in ClockWork Mod (ROM Manager):
Boot into CWM
Go to Advanced
Then to "Partition SD Card"
Choose an sd-ext size
Then choose a swap size, or not. Swap is just like windows' virtual memory. The system will use it when you're running low on RAM and use it as temporary RAM storage. This is where you'll probably see an increase in speed.
Just for fun I put sd-ext at 512MB and Swap at 64MB which is probably more than plenty for the swap. The swap will assist a little with memory and with the extra space I can move my apps over to it with a program like App2SD or in most custom ROMs nowadays just use the "move to USB" option in "Manage Applications". Titanium Backup will also move apps to SD for you and I'm sure you can find plenty more in the market.
You can also use a tool like Minitool Partition Wizard:
1. Open Minitool Partition Wizard
2. Delete Existing Partition from SDCard (Backup data first!!)
3. Create Fat32 Partition
Note: Set all partitions to PRIMARY (Steps 3 - 6)
4. Create EXT2 Partition (System) about 150MB-200MB depend on ROM
5. Create EXT2 Partition (Data) about 150MB-250MB
6. Create EXT2 Partition (Cache) about 50MB
Personally I don't see a need to do any of this on either of my Captivate phones though I have played with it on my DEV phone.
And since it does play a big role and needs to be cleared at times...
Davlik-Cache - dalvik cache is a program cache area for the program "Dalvik". Dalvik is a java based virtual machine that is the base for running your (.apk) programs. In order to make access times faster (there wasn't a JIT compiler installed by default until Android 2.2), the dalvik-cache is the result of dalvik doing a optimization of the running program/s. This optimization is kept so that it is then re-used every time you use your application/s. By default, davlik-cache is located in your /data partition.
No, I'm not looking for donations. Just trying to clarify things for some.
Great info, but a "guide" assists you in doing something, this is just straight info.
While I initially intended on writing it to guide flashers into the benefits of a wipe data / factory reset, and avoiding the myriad of strange issues experienced, I can see now where it can more construed as informational. Hmmm... maybe I'll add more to it or ask a mod to change the title topic for me.
Regardless, my hope is that some people get some benefit out of it otherwise I've only wasted my time.
Thanks, I've been wondering for a while what that actually did.
Great start for a guide that should clear the boards up a bit. I vote it to be stickied after adding a bit more info on backing up, partitioning the sd card, dalvik cache, etc.
I think it is important to explain that a reset should not be done after flashing a custom ROM because it deletes the Dev's settings/data/non-system apps. Instead flashers should either reset after flashing back to stock or before flashing a custom ROM over the current custom ROM.
Cozmo1 said:
I put this short guide together because I tend to see a lot of confusion regarding what a "wipe data / factory reset" does to your phone.
When you perform a “wipe data/factory reset” the content of the following directories are deleted :
/data
/cache
/datadata
/sd-ext
/sdcard/.android_secure
/cache - This is the partition where Android stores frequently accessed data and application components to make these, as implied, respond much faster as well as faster to retrieve / access.
/datadata – This directory contains the library, database, user specific configuration files as well as log files for its specific application installed in the /data directory.
/data directory is where your contacts, messages, settings and apps that you have installed go. Wiping this partition essentially restores it to the way it was when you first booted it, or how it was after your last custom ROM install.
If your ROM uses an /sd-ext partition on your SD card for data storage your /data directory is mapped to /sd-ext and wiping the /sd-ext directory will result in losing your data.
/sd-ext is used for apps moved to your SD card. Your Android OS runs natively in an ext format while your SD card has a fat32 format, which is used typically for USB storage devices, Windows computers, etc.
The folder named .android_secure is where apps are stored when you perform the "move from phone to SDram/SD card" operation.
Consider this, Apps2SD uses the fat32 portion of your SD card, which is obviously limiting because it isn't Androids native file system. However, if you format your SD card, or partition a part of it as a ext file system, you can trick the phone into thinking it's part of the Android OS native environment. This will allow you to move applications, widgets, even cache and davlik cache over to it.
Nothing else on your SD card (internal or external) is modified so it is safe to leave files outside of the above mentioned directories without fear of losing them.
If you plan on trying several different ROM's and/or updating your favorite ROM every time a new version is released you need to invest in an application like Titanium Backup or one that comes with your ROM if it's supplied with one. MIUI includes one that works extremely well. Performing a “wipe data/factory reset" after loading your new ROM and before booting into it should provide you with a smoother transition to your newly chosen or upgraded ROM. Having a standard backup and restoral process should help you enjoy it quicker too.
Click to expand...
Click to collapse
Here is something I keep in a word file to help answer what you are also trying to answer. It is a bit shorter and simplified but it may help to polish your thread for us simpletons.
Dalvik cache is a place where the Android OS re-compiles the executable programs the first time to optimize them. It does this when you make a major change like replace the kernel/modem. Clearing the Dalvik cache will force Android OS to recompile the apps for the the new kernel/modem. This can take time on the first boot after clearing the Dalvik cache.
Also the main data Cache is used by the Android OS at run-time to write temporary files for specific reasons. You want to clear this out so it doesn't re-use the old cached data.
Manually clearing both caches allows the new kernel/modem to be installed in a "cleaner" environment. It's just preventative maintenance.
snowake said:
I think it is important to explain that a reset should not be done after flashing a custom ROM because it deletes the Dev's settings/data/non-system apps. Instead flashers should either reset after flashing back to stock or before flashing a custom ROM over the current custom ROM.
Click to expand...
Click to collapse
This actually makes perfect sense to me. I have modified my OP because of your input. Thank you very much, snowake!
Cozmo1 said:
This actually makes perfect sense to me. I have modified my OP because of your input. Thank you very much, snowake!
Click to expand...
Click to collapse
do u have more info about "format your SD card, or partition a part of it as a ext file system" or how to do that.
i have read someone format part of the sdcard (class 10)to ext 2 or 4,to make the write n read faster.is that what you mean.can u guide me to the right direction.thank in advance.
? ? ? about this......(However, if you format your SD card, or partition a part of it as a ext file system, you can trick the phone into thinking it's part of the Android OS native environment. This will allow you to move applications, widgets, even cache and davlik cache over to it.)
Cozmo1 said:
This actually makes perfect sense to me. I have modified my OP because of your input. Thank you very much, snowake!
Click to expand...
Click to collapse
I struggled with all of this my first first few flashes.
xpakage said:
...Dalvik cache is a place where the Android OS re-compiles the executable programs the first time to optimize them.
...
Also the main data Cache is used by the Android OS at run-time to write temporary files for specific reasons.
Manually clearing both caches allows the new kernel/modem to be installed in a "cleaner" environment. It's just preventative maintenance.[/I]
Click to expand...
Click to collapse
That is much more boiled down. I looked back at the "how to flash" threads and a couple good explanations on custom roms. None explain this that I found.
Cosmo, here are some more thoughts on misunderstandings I have had and seen posted. Like post above I pasted from my notes, so may be incorrect.
Bootloaders: Same for Froyo/Eclaire in both i897 and i9000 roms. GB requires new bootloaders, but i897 are apparently cross-compatible. However, issues seem to pop up on i9000 roms with GB i897 bootloaders. If flashing back to Froyo, use the full jf6 stock, not cezar's stock eclaire without bootloaders.
Using Tibu: If no useful data (i.e. Bookmarks on dolphin) then simply click data only when restoring user apps. Typically no issues when restoring user apps after switching Android versions. However, system apps should not be restored because of the rom customizations. Especially when switching to GB because it uses different directory structure. I do not seem to have issues when staying on same version and restoring foreground (user accessible) apps with data only or restoring green text color sys apps with Tibu as icon (i.e. Accounts).
Rom manager: really only need the app if flash to stock and need to flash rom directly from cwm. If so, then flash cwm (top button in menu) and choose phone. This places update.zip in /sd, which is opened after selecting "reinstall update" in stock recovery. Usually have to select it twice for it to work. This will replace ATT stock 2e recovery (blue text) with cwm 2.5 (froyo).
Voodoo color, lagfix, sound: must either be included in kernel. Lagfix simply allows user to format sd as ext4 (linux). Color balances display so less blue iodes are used and color is more realistic. Sound allows clearer sound through headphones through tweaks enabled in voodoo app. If sound is not in kernel then purchase voodoo pro in market and it will install it into the kernel (if rooted, even if stock).
Thanks for clearing that up!
- Aaron
Updated with more details.
Really, really useful. Had no idea partition options were available to this extent! Especially swap. By mini tool are you referring to Easus' program? I am definitely checking this out tonight. Thanks!
Great guide. In order to clear
/sdcard dir I master clear it after flashing to stock. Is there an alternate method besides deleting dirs myself?
snowake said:
Great guide. In order to clear
/sdcard dir I master clear it after flashing to stock. Is there an alternate method besides deleting dirs myself?
Click to expand...
Click to collapse
That is probably the safest way to do it within the phone itself. An alternate way would be to mount it to your computer:
In Windows right click the drive that was assigned to your internal SD card and then click on format. By default it'll most likely set you to Fat32 and if you click format it'll say its complete, but nothing will be deleted. Android being a Linux OS doesn't use fat. You can format it by choosing exFat, but by doing this...
!!!WARNING!!! be aware that you will lose everything on your internal SD card AND your external SD card.
Emphasis placed mainly for others that read this and might not know.
Safer and easier to do it within the phone.
snowake said:
Really, really useful. Had no idea partition options were available to this extent! Especially swap. By mini tool are you referring to Easus' program? I am definitely checking this out tonight. Thanks!
Click to expand...
Click to collapse
This one is from MiniTool, though I wouldn't be surprised if Easus owned them. I didn't investigate to confirm. You can get the free home edition of MiniTool Partition Wizard here.
Very nice infos. Deserves a sticky, although, probably in a different thread.
Some information on what "Master Clear" in Odin would also be helpful - I have never trusted my phone to 'truly' clear everything on the phone, I have found the Odin Master Clear option to be much more complete.
It is a bit odd, I do this with my PC every six months, I back everything up and format the drive and start over again (after running Spinrite on all the drives) - I do this on / around New Years and again over 4th of July weekend and I decided this past weekend to also do the same with my smart phones (4 Cappies) and tablets (Ipad and 2 Android tabs) this past weekend.
It gives me that sort of squeaky clean feeling and seems to make my devices run smoother. Maybe its all in my head, dunno *shrugs*.
One thing I can say however, I have not had a hard drive go bad on me since I started the Spinrite thing 10 years ago (I still have an 8 GB hdd in my desktop that is working!!).
Any decent update(r)-script will do this for you.
Sent from my Infuse 4G
littlewierdo said:
Very nice infos. Deserves a sticky, although, probably in a different thread.
Some information on what "Master Clear" in Odin would also be helpful - I have never trusted my phone to 'truly' clear everything on the phone, I have found the Odin Master Clear option to be much more complete.
It is a bit odd, I do this with my PC every six months, I back everything up and format the drive and start over again (after running Spinrite on all the drives) - I do this on / around New Years and again over 4th of July weekend and I decided this past weekend to also do the same with my smart phones (4 Cappies) and tablets (Ipad and 2 Android tabs) this past weekend.
It gives me that sort of squeaky clean feeling and seems to make my devices run smoother. Maybe its all in my head, dunno *shrugs*.
One thing I can say however, I have not had a hard drive go bad on me since I started the Spinrite thing 10 years ago (I still have an 8 GB hdd in my desktop that is working!!).
Click to expand...
Click to collapse
I can run some tests on Odin's master clear to confirm what it does. Initially I would believe it does the same as a "wipe data / factory reset", but testing should let us know for sure. I'll test it this weekend. Maybe sooner.
Awesome to hear that I'm not the only advocate for SpinRite and I still use it a lot though not every 6 months like you do. It's definitely worth having and using.
MikeyMike01 said:
Any decent update(r)-script will do this for you.
Sent from my Infuse 4G
Click to expand...
Click to collapse
I totally 100% agree with you, MikeyMike01. Unfortunately, not all update scripts are created equally Asides from teaching people how to script themselves or parse through it, a task I do not have the time or patience to tackle, this it probably the easiest and best way to have users try to avoid the many and strange issues posted that possibly / most likely could've been avoided by using the tools at their disposal.
On a side note... I didn't notice you got yourself an Infuse 4G. Congrats! How do you like it? I've been out of contract for almost a year now and wouldn't mind upgrading (my wife is in contract), but I haven't seen anything really worth upgrading to or that does something I really need/want that the Captivate cannot, atm. I haven't looked up any specs and reviews on the Infuse yet tho.

New to CM7

Hi all,
So last night I decided to give Cyanogenmod7 a try. I came from MIUI.us 2.1.20 - I just love MIUI, but it's a bit too demanding for the Milestone. So I have CM7 up and running, and it is a lot more snappy. But now, I'm having trouble installing some apps.
I tried installing my bank's banking app, but it didn't install - checked the market and it doesn't appear. Same thing with WhatsApp!! If it were working, I might just become a CM7 user..but it's not working.
Am I missing something? I installed after doing a full wipe, after which I installed DT A2SD scripts and then gapps-20111216 (although didn't see gmail or market etc after gapps, so installed those via apk).
What's the deal here?
Thanks.
Sent from my Milestone using Tapatalk
Ok, just wiped again, and reinstalled all. CM7 then gapps then dt a2sd. So far it's working.
Sent from my Milestone using Tapatalk
googleservicesframework.apk and vending.apk are all you need for using market. Try to reinstall them. May you success.
Ok, so now my problem is A2SD. It's not working! A2SDGUI refuses to go in, and when I do a check, I get a segmentation fault...I've never had this issue before. I've tried reinstalling DT A2SD from withing recovery and still, nothing. Please assist, I just need to get set up properly now.
Regards
Sent from my Milestone using Tapatalk
DT scripts dont work ...use an external partition (app2ext)
d.casper.b: CM7 for Milestone already comes with its own ap2ext scripts that are automatically used if there is ext partition present on your sdcard.
You should not install any 3rd party app2ext scripts as they are very likely to be conflicting with the scripts that are already there.
Thanks kabaldan.
I'll check it out.
I was even going so far as trying to use Link2SD from the market..
How'd I know if it's working? By monitoring the available internal storage?
Sent from my Milestone using Tapatalk
d.casper.b said:
Thanks kabaldan.
I'll check it out.
I was even going so far as trying to use Link2SD from the market..
How'd I know if it's working? By monitoring the available internal storage?
Sent from my Milestone using Tapatalk
Click to expand...
Click to collapse
when you will enable app2ext you will see the total space in your storage rise to 197 mb
I am not winning. I did a factory reset and flashed cm7 and gapps (not dt a2sd).
I did a test, internal storage was at 191mb, then I installed opera mobile and it went down to 182mb. Then uninstalled it again. Went into cyanogenmod settings and set install location to external. Installed opera again, but it was no different. Moving it to sd under 'manage applications' increased the internal memory again, but that's just moving the app to the FAT32 partition of the sd card.
So it's not seeming to work for me for some reason.
Sent from my Milestone using Tapatalk
EDIT: I really don't want to be a nuisance, but now, looking at the available storage using "Quick System Info", I noticed after uninstalling "Opera Mobile", 9mb was freed on internal storage & 13mb on the ext partition.
So, perhaps it is working, and since the dalvik cache is (I assume) on internal storage, the storage is still decreasing. Am I correct? If so, is there a way to also move dalvik cache to the ext partition - I had it like this on MIUI & never looked at available memory ever again.
First of all, have you really partitioned your SD card? Make sure you followed the 3rd step on this guide: http://www.mrmuh.com/2012/01/update-a-motorola-milestone-from-motorola-firmware-to-cyanogenmod-7/ . You should have your SD Card partitioned with two partitions, the first should be FAT32 that's used normally on Android, and the second EXT3 or EXT4. Obviously, make sure you have a backup of your FAT32 partition before partitioning.
Second, you should understand how the apps2ext scripts on CM7 work. Application installs that would be stored on internal memory are rerouted to the EXT3/4 partition on the SDCard. This happens at the underlying system (linux) level, Android (that runs on top of linux) is not aware of this rerouting, so, as far as Android "knows", apps that are rerouted to the EXT partition are on the phone's internal memory. That means that you should make sure that apps you need installed on the EXT partition of the SD card are shown in "Applications > Manage applications" list to be installed on the internal memory. Yep, it's confusing, but once you understand how it works and why it works that way, it makes sense.
Third, the fact that apps are rerouted to the EXT partition doesn't mean that everything about the app will live on the ext partition: it means only the main application package will live on the ext partition, application data is still stored on the internal memory. For most apps, the amount of data used for application data are much smaller than the application package, but in some apps the amount of application data from the app may often surpass the size of the app itself - for example, in my phone, Tweekdeck stores about 9Mb of data, which is about 10 times the size of the application itself (820kb) - presumably this amount of data is cached tweets, pictures, etc. But that case is usually the exception, not the rule, I've just mentioned it so you understand that using apps2ext doesn't mean your internal memory will always stay unused, it just means it will be used (way) less.
Finally, regarding the CyanogenMod Settings location setting, if you understood what I said above, you should now understand that it should actually be set to always install to "Internal", rather than external. However, there's a bug in this that you should be advised, that not all apps will respect this setting: some apps will install to external regardless of how you've configured that setting (meaning the app will use Froyo/Gingerbread native Apps2SD, hence being installed to the FAT partition of the SDCard). So, when you install a new app, check on app management if it didn't get installed to the SDCard, and move it to the internal memory if that's the case. For these kind of apps, you'll have to do it every time you update the app too.
Thanks, I edited my previos post..
I actually have 3 partitions, a FAT32, an ext2 (maybe it's ext3, but doubt it - partitioned some months ago, so my memory's hazy), and a SWAP - which I should get rid of, but am too lazy.
I understand entirely what you've said, I know that internal is really ext if working, and sd is FAT32 partition.
You see, I'm just new to this rom and have to trial and error until I understand, with miui you just flashed the rom and the a2sd scripts and didn't bother again (maybe only to move an app that installed to FAT partition). But it seems CM7 is simply just to flash the rom and you're good to go. But as I was pondering in my previous post...is there any way to move dalvik cache to ext?
Thanks for putting up with me..I'm almost there.
Sent from my Milestone using Tapatalk
d.casper.b said:
Thanks, I edited my previos post..
I actually have 3 partitions, a FAT32, an ext2 (maybe it's ext3, but doubt it - partitioned some months ago, so my memory's hazy), and a SWAP - which I should get rid of, but am too lazy.
I understand entirely what you've said, I know that internal is really ext if working, and sd is FAT32 partition.
You see, I'm just new to this rom and have to trial and error until I understand, with miui you just flashed the rom and the a2sd scripts and didn't bother again (maybe only to move an app that installed to FAT partition). But it seems CM7 is simply just to flash the rom and you're good to go. But as I was pondering in my previous post...is there any way to move dalvik cache to ext?
Thanks for putting up with me..I'm almost there.
Sent from my Milestone using Tapatalk
Click to expand...
Click to collapse
in the market you will find an app called s2e which moves app data, davlik cache to sd
also link2sd also free's up more space and makes cm7 snappier
please don't install such things to CM7 for Milestone unless you know what you are doing and you are able to resolve conflicts with the existing scripts
dalvik-cache is already moved automatically
if you want to free more space in /data, enable lib2ext to move native libraries to ext - it's mentioned in the changelog for 7.1.2 release
app data itself should not be moved as it can cause instability
d.casper.b said:
Thanks, I edited my previos post..
I actually have 3 partitions, a FAT32, an ext2 (maybe it's ext3, but doubt it - partitioned some months ago, so my memory's hazy), and a SWAP - which I should get rid of, but am too lazy.
Click to expand...
Click to collapse
Yeah, get rid of swap, there won't be any use for it (for now anyway) and it's best for you at this point to have a known working structure (two partitions, 1st FAT, 2nd ext3/4) for your SD as you're troubleshooting your problems/questions, it'll make it easier for us too as this will eliminate potential points of failure or inconsistencies. And you should really consider upgrading to a journaled filesystem, either ext3 or ext4. Using ext2 is unreliable because Android doesn't umount the ext partition cleanly on reboot or shutdown, so you may have problems with apps disappearing or misbehaving every other reboot. Using ext3/4 with journal elimitates this problem since the journal is just replayed for the uncleanly umounted partition and the filesystems behaves more consistently.
d.casper.b said:
You see, I'm just new to this rom and have to trial and error until I understand, with miui you just flashed the rom and the a2sd scripts and didn't bother again (maybe only to move an app that installed to FAT partition). But it seems CM7 is simply just to flash the rom and you're good to go. But as I was pondering in my previous post...is there any way to move dalvik cache to ext?
Click to expand...
Click to collapse
The apps2ext script built on CM7 should do this by default - you probably already have your dalvik-cache on the ext partition. To check this, go into OR, enter the console and type: "ls /sddata/dalvik-cache" . If it returns a list of files, you've already got the dalvik-cache on your ext partition. Another option is setting the option dalvik.vm.dexopt-cache-only to 1 in the file /system/build.prop . This will put all dalvik-caches (both from user apps and system apps) on the phone's internal cache partition, thus still freeing space on the internal memory but without using the ext partition, but that's not recommended if you install too many apps because the cache partition may run out space and that will spawn all kinds of weird behavior on Android. The safer route is just using the default configuration anyway (user apps dalvik-cache on sd-ext).
Another option to further reduce internal memory use is using lib2ext, that will move user apps native libraries to the ext partition, but the memory gain in this case is dependent on which apps you use and how big their native libraries (if they even have one) are. To activate it, just go into the Terminal app (with Android booted) and type:
$ su
# lib2ext
And reboot. The libraries will be moved to the ext partition during boot. Make sure you have a big enough ext partition to hold everything (apps, dalvik-cache and apps libs) - the size to recommend is very dependent on how many apps you use and how big they are, but I'd say 512Mb would be the bare minimum.
in the market you will find an app called s2e which moves app data, davlik cache to sd
also link2sd also free's up more space and makes cm7 snappier
Click to expand...
Click to collapse
DON'T! JUST DON'T! These third-party apps will cause all kinds of problems with CM7 builtin apps2ext.
EDIT: Oh well, Kabaldan already put all my rambling much more succintly than I could... I'm way too talky
well i was jus trying to help.. .anyway guys thanks i guess i won't be needing those apps anymore ...sorry for my noobness
Thank you so much guys!
It seems like it's working. I will check out lib2ext & the other suggestions tonight or over the weekend (on my way to work now).
I must say, I thought the move to CM7 would be a temporary one, but the speed gain is just what I needed, & the tweaks I thought I'd miss I am finding hidden in the settings .
Just wondering on the battery now - but I've been fiddling non-stop.
So let me play a bit more the weekend & I'll merge my ext2 and SWAP partition into one ext3 partition.
Thanks all, and kabaldan for your hard work on this rom.
Sent from my Milestone using Tapatalk
Just as I was on my way...
Everything's running fine, A2SD works. But now, I partitioned my SD card with a 2nd partition (ext3, it was ext2), but now widgets are not loading. Checked the apps install location, and it's 'internal', ie. ext3. I never had this before. I think maybe it's due to the filesystem now?
EDIT: Ok, ext2 is doing the same. I can't keep starting from scratch the whole time guys.
EDIT2: It's now suddenly working! Just have a Fat32 and an Ext3 partition. But I don't understand because it's been setup like this twice before with no success. I'll hold thumbs!
PS, CyanogenMod is quite up my alley now, speed is awesome and I'm happy.
Sent from my Milestone using Tapatalk

Low memory

I'm running the **SMS* 3.02 by RSK team on my HTC Desire, the rom works great (I wanted the Amaze Cam) but I seem to run out of internal memory really quickly, ROM has only been on (again) for a week and I'm down to 25mb, all apps have been moved to SD.
I do have quite a few apps installed, but surely being on SD internal memory should be empty. The phone has a 16Gb SD card with a 2Gb ext partition created through recovery.
How to I get the memory back? I suspect it's going to be full in a day or 2, leading me to another full wipe
What i did to make more mem is using ''ram manager'' on the market and kill apps running in the background.
Thanks, I'm not sure how killing running apps is going to free phone storage space, though
I suspect I need to find a data2sd rom, ideally with the new cam
getting closer, I notice my Dalvik cache is ~170Mb, so taking up all that space. I installed 2 market apps to move it, the first, S2E just does nothing when IO tell it to move the cache. The second, a2sdgui, exits with the following message
"cannot start for one of these reasons
1. your phone is not rooted (it obviously is to be running custom roms?)
2. A2SD scripts could not be found o
3. No EXT partition found
Did you create a partition on your SD CARD? Does your custom rom support APP2SD (normally is natively included)?
Make sure.
Otherwise, I would suggest to try another rom to see what happen.
frosty68 said:
getting closer, I notice my Dalvik cache is ~170Mb, so taking up all that space. I installed 2 market apps to move it, the first, S2E just does nothing when IO tell it to move the cache. The second, a2sdgui, exits with the following message
"cannot start for one of these reasons
1. your phone is not rooted (it obviously is to be running custom roms?)
2. A2SD scripts could not be found o
3. No EXT partition found
Click to expand...
Click to collapse
Don't assume that because you are running a custom ROM means your phone is rooted - the 2 have absolutely nothing to do with each other. Check that you have superuser installed, and if you do run terminal emulator and type the command su. If you're rooted you should get asked if you want to allow superuser privileges to the app. If it doesn't ask then either you've allowed (and remembered) the permission before or you're not rooted.
If an app's telling you you're not rooted then it's possibly right - always good to be sure.
Thanks, phone definitely rooted, and superuser installed (and titanium backup, which I've just used)
can't see mention of apps2sd on the rom page, though I was running a pretty old version.
Decided to do a full wipe, repartition the SD card and install a later version which has dalvik-cache to sd-ext, hopefully this will solve the problem of it filling.
Showing 174MB free right now, (+8.6Gb)
I take it if the cache does fill again I can just wipe it with no ill effects?
I wipe all my cache periodically with this:
https://market.android.com/details?...sMSwxLDEwMiwiY29tLmFhYy5jYWNoZW1hdGUuZGVtbyJd
I normally free up to 20 MB.

Firerats + Data2ext Complete Installation Guide: Now works with Sense roms!

This thread serves as a guide to install both firerats and data2ext mods on a single rom and have them work simultaneously.
I do not take any credit for the creation of any files mentioned or attached, nor methods for the installation of each individual mod, nor roms, gapps, or otherwise mentioned content. All credit goes to those who created each mod, rom, gapps, and the methods for installing each individually. I only claim responsibility for my own research and the order and hierarchy of steps below that combine these incredible feats of development into a working system of internal storage expansion and space management.
Even though it is impossible to brick your phone using the guide below, I am not responsible if you break your device, because you have willfully chosen on your own to void your warranty by rooting your phone and installing the mods mentioned below.​
To make firerats work with data2ext simultaneously, follow these over-detailed instructions EXACTLY. This is written so that anyone who has never held a smartphone in their lives can understand and do this right the first time, so those of you that know what you're doing, sorry about the length, but it should be pretty easy for you.
Note: I've uploaded some pertinent files from the following steps and added all links to all files needed so you don't have to go find them yourself. I did not include any roms, gapps, or the freespace app from the Play Store(just download from your phone, or from the link in step 6d). Links for all necessary files are in their respective steps below. The only links to a rom or gapps are for ICS. Otherwise you'll have to find and use your own downloaded roms and the correct gapps for your rom. If you would rather use the links below to download the files instead of using the ones I provided, be my guest.
I've updated this guide to make installation much easier and work with Sense roms!​
Now on to the good stuff!!
Steps 1 through 7a are written for you to collect the files necessary, and to prepare your phone, sd card, and recovery for the correct method of installation of the collected files.
Steps 8 through 10 are to install the mods.
Preparation
1. Be sure to start from scratch!!! This means an UNPARTITIONED, FULLY WIPED sd card, fully wiped and rooted phone, and fully wiped recovery. Fresh file downloads for roms, gapps, and other mods you like wouldn't hurt either. If your phone is not rooted, go here, it's the best and easiest root method I've found.
1a. If you already have a partitioned sd card, insert it into your computer via a microsd adapter or other means(you cannot use your phone for this; it will not recognize that it's partitioned), delete the partitions and wipe the card using partition management software on your computer. I recommend EASEUS Partition Manager 9.1.1 Home Edition(Windows users only). If you use this program, after you delete partitions on your sd card, you will be left with unallocated space. Create a partition that takes up the entire unallocated space and set it as a Primary and FAT32 file system(remember, only do this to your sd card, NOT THE C: DRIVE!!!!).
2. Boot to recovery(hold down home, press and release power, then release home once recovery shows up)
2a. Be sure you have a recovery that supports flashing unsigned .zip files. If your recovery does not support flashing unsigned .zip files, flash a rom and then the corresponding gapps that are signed(cyanogenmod roms and gapps are the easiest way to go), boot into rom, sign in, download rom manager from Market/Play Store, open rom manager, flash clockworkmod recovery, and boot to recovery.
3. Make sure you are using latest 5.5.0.4 recovery, found here.
3a. If you are not already using the 5.5.0.4, flash the 5.5.0.4.zip in your current recovery(or follow the instructions from step 2a if you cannot flash unsigned .zip files) and reboot back into recovery.
4. In your new recovery, make sure you wipe everything, and go to advanced>partition SD card. Choose whatever size you want to have as internal storage(the 'M' means Megabyte, if you didn't already know...). I use 1024M or 2048M(i.e. 1Gb or 2Gb), depending on what mood I'm in, but it works with any of them. Then choose 0M swap size and wait for it to process.
5. Wipe everything once again(just to be safe), including sd-ext, and place your rom and preferred gapps on sd card, along with any other flashable modifications you like to use(I use the sd card speed boost, which can be found here. 2048Kb works best for my card, a 16Gb Class 4).
Note: For ICS users only! I use official, larger ICS gapps, found here(download the one next to 4.0.X, the link will be: '20120429'). The smaller gapps, as well as the current best ICS rom, can be found in whoshotjr2006's thread, here.
6. Make sure you have the latest firerats(1.5.8), which can be found here.
6a. Don't use any of the alphas or betas. Just 1.5.8. Download only the recovery-v1.5.8-CustomMTD_S.zip and boot-v1.5.8-CustomMTD_S.zip and place on sd card. Create a .txt file named 'mtdpartmap' and type 'mtd XXX XX'. These X's represent the size in numbers that you want your /system and /cache partition sizes to be, and therefore will not actually be used. See step 6b or 6c, depending on what rom you'll be using, for information on how to determine the correct partition sizes/numbers to use. DON'T KEEP THE X's IN THE FILE! REPLACE THEM WITH THE NUMBERS YOU WILL USE AFTER YOU DETERMINE WHAT YOUR /SYSTEM AND /CACHE SIZES SHOULD BE!
6b. For ICS users: If you are using the official, larger gapps, type 'mtd 190 60' into the text file and save to sd card. If you are using smaller gapps, type 'mtd 190 30'. Proceed to step 7.
6c. For Non-ICS users: To find out what numbers to replace the X's with in your mtdpartmap.txt, first wipe everything and install only the rom and gapps you'll be using this mod with. Then boot into rom, sign in, and follow step 6d. After you do this, however, you will need to repeat steps 5 and 6a, then proceed to step 7.
6d. You can download 'freespace' from the Play Store, which needs root access, and will show you the total size and space remaining for each of the /system, /data, /cache, /sdcard, and /ext partitions, so you can change the numbers in your mtdpartmap file to what you want the /system and /cache to be that best suits the rom you want to flash. The first number after 'mtd' is for the /system partition, the second number is for /cache. You can't change the /data, because it is dependent on what you set the system and cache sizes to, and will be set to what you partitioned the sd card to anyways. Also, keep at least a 5Mb allowance over what you need for both /system and /cache partitions as you will run into force closing problems if there is no breathing room, especially for the /cache partition.
7. The data2ext thread and .zip file can be found here.
7a. Download the unCoRrUpTeD_data2extV2.2.zip at the bottom of the post and place on sd card. DO NOT FLASH!!!
Summary of what should be accomplished after following steps 1 through 7a: You should now be using CWM Recovery 5.5.0.4, have a partitioned sd card, wiped everything, and placed the boot-v1.5.8-CustomMTD_S.zip, recovery-v1.5.8-CustomMTD_S.zip, unCoRrUpTeD_data2extV2.2.zip, mtdpartmap.txt, the rom and correct gapps, as well as any other mods you want to use onto your sd card. If all of this is true, move to step 8. If not, go back and find what you missed.
The Installation Process
8. Flash recovery-v1.5.8-CustomMTD_S.zip, then under mounts and storage, wipe /system, /cache, and /data in that order.
8a. Reboot to recovery(go to advanced>reboot recovery).
9. Flash rom, gapps, and whatever other mods you have or like, then flash boot-v1.5.8-CustomMTD_S.zip, then unCoRrUpTeD_data2extV2.2.zip, and reboot.
Note: the firerats installation thread for the HeroCDMA says to flash boot-v1.5.8-CustomMTD_S.zip after anything that changes the kernel specifications, but the unCoRrUpTeD_data2extV2.2.zip does not change these. The thread also says that adb is necessary to reboot; it's not. After wiping /system, /cache, and /data, just go to advanced>reboot recovery. It will work just fine, I promise. Newer recoveries don't need to use adb for this step.
10. Reboot immediately after signing in for data2ext to take effect.
That's it! You're all done! Set up your phone the way you want and start installing apps!
Summary of steps 1 through 10: By now, you should be using 5.5.0.4 recovery, have a partitioned sd card, have placed all necessary files, your rom, gapps, and other mods onto your sd card, flashed the correct files in the correct order and rebooted, signed in, and rebooted after signing in. You should now be looking at the home screen(or lockscreen) of your rom, and if you check storage from settings, you should see internal storage showing the size you partitioned the sd card to be in step 4.
Hopefully this wasn't too confusing...good luck!
If you have any questions, don't hesitate to post in this thread!
Thanks, great guide! Wish I had it back when I had my first experience...
Speaking as per my own experience:
I ended up using the latest Firerats (dunno if its an alpha or beta) since I found myself flashing different ROM's and ROM updates quite a bit, for me it didn't require the use of a boot flash, rom works fine for me (spare some thoughts on this?, maybe just not required for the Alpha/Beta as abandoned work)...
Side note:
If you dont want to download an app to flash from the market to find out the space your rom is going to use for /system (at least, and for fresh install only), simply unzip your ROM and GApps to the same directory and right click and view the properties, this is its uncompressed size, and using a 4Mb buffer my self (Id recommend 8Mb just to be safe for most), Its normally right on the money for SOD or Size On Disk...
Hammerfest said:
Thanks, great guide! Wish I had it back when I had my first experience...
Speaking as per my own experience:
I ended up using the latest Firerats (dunno if its an alpha or beta) since I found myself flashing different ROM's and ROM updates quite a bit, for me it didn't require the use of a boot flash, rom works fine for me (spare some thoughts on this?, maybe just not required for the Alpha/Beta as abandoned work)...
Side note:
If you dont want to download an app to flash from the market to find out the space your rom is going to use for /system (at least, and for fresh install only), simply unzip your ROM and GApps to the same directory and right click and view the properties, this is its uncompressed size, and using a 4Mb buffer my self (Id recommend 8Mb just to be safe for most), Its normally right on the money for SOD or Size On Disk...
Click to expand...
Click to collapse
What version of firerats are you using? And I agree with you about the unzip method, and would have included that, but I wanted it to be as easy as possible for people who don't know what they're doing, and usually, 'an app for that' is the best way to go. Not saying it isn't easy to unzip, check the size, and rezip, I just thought an app that checks it for you would have less possibility of confusion. It does make the process a bit longer, yes, but at least people don't have to mess with the file at all.
On my own side note: After the several hours spent writing, rewording, adding, changing, and moving things around in this guide, I'm pleased to say it's 100% complete. No further changes that I can see happening.
goliath714 said:
What version of firerats are you using? And I agree with you about the unzip method, and would have included that, but I wanted it to be as easy as possible for people who don't know what they're doing, and usually, 'an app for that' is the best way to go. Not saying it isn't easy to unzip, check the size, and rezip, I just thought an app that checks it for you would have less possibility of confusion. It does make the process a bit longer, yes, but at least people don't have to mess with the file at all.
On my own side note: After the several hours spent writing, rewording, adding, changing, and moving things around in this guide, I'm pleased to say it's 100% complete. No further changes that I can see happening.
Click to expand...
Click to collapse
I think 1.59 alpha... after a system crash a few months ago, i havent had the need to re-bookmark the firerats mediafire folder... I really should, and seeing as most file share hosts are closing down or restricting free access to files I really should re-download and archive them... god knows how many things I have lost because of the MAFIAA fiasco's...
Yeah that might be a good idea. Personally I've never used any alphas or betas so I really don't have any input for them lol
Sent from my HeroC using XDA
Bumping my own thread...lets get some more views for this thing! If you haven't tried it yet, or have questions about it, or simply don't know what it does, send me a message or post on this thread! It's really a very useful mod for those of you that use or like installing lots of apps...
Thanks for the guide to this. The only problem I may seem to have is that when I follow all your steps at 11b this is what I get:
mke2fs 1.41.12 (17-May-2010)
/dev/block/mmcblk0p2s apparently in use by the system; will not make a filesystem here!
Is that correct? Or am I doing something wrong?
I see no reason to use both scripts combined. The data2ext you can have 2048mb/2gb That should be more than enough space for all your apps. Although this is a good write up I see a lot of conflict with using both mods together. One or the other should do. I'd recommend data2ext. You can create a 2048 partition and it will run just fine on a class 4 or better sd. Anything lower and you might suffer glitches like screen freezing, apps missing,lock up's and reboots. If you have a stock sd or a higher capacity sd but without a class rating or class 2 then I recommend firerats mod. Also you could very well run both of these mods and have not one problem whatsoever so it just user experience and preference I'm referring to.
#Root-Hack_Mod*Always\=LTE
Hmoobphajej said:
Thanks for the guide to this. The only problem I may seem to have is that when I follow all your steps at 11b this is what I get:
mke2fs 1.41.12 (17-May-2010)
/dev/block/mmcblk0p2s apparently in use by the system; will not make a filesystem here!
Is that correct? Or am I doing something wrong?
Click to expand...
Click to collapse
You have to unmout the partition first.
#Root-Hack_Mod*Always\=LTE
App2sd
Yea, I got that too, is it not working for you.
If not, add "/system/etc/init.d/40data2ext --enable" That made it work for me. Don't add "".
after reboot and the memory still hasn't change then go back in to terminal manager and add the above line and then reboot, should work then, never got firerats to play nice with the script, so i just use data2sd
laie1472 said:
I see no reason to use both scripts combined. The data2ext you can have 2048mb/2gb That should be more than enough space for all your apps. Although this is a good write up I see a lot of conflict with using both mods together. One or the other should do. I'd recommend data2ext. You can create a 2048 partition and it will run just fine on a class 4 or better sd. Anything lower and you might suffer glitches like screen freezing, apps missing,lock up's and reboots. If you have a stock sd or a higher capacity sd but without a class rating or class 2 then I recommend firerats mod. Also you could very well run both of these mods and have not one problem whatsoever so it just user experience and preference I'm referring to.
#Root-Hack_Mod*Always\=LTE
Click to expand...
Click to collapse
That's all true, but the reason I combined both is to customize the /system and /cache partitions, while still allowing my 2gb data partition to work. This way I have control over what size I want each partition to be.
goliath714 said:
That's all true, but the reason I combined both is to customize the /system and /cache partitions, while still allowing my 2gb data partition to work. This way I have control over what size I want each partition to be.
Click to expand...
Click to collapse
You can still achieve that without the combination of both mods.
#Root-Hack_Mod*Always\=LTE
In step 11 you said to reboot into rom immediately after flashing data2ext2-v7.zip and open terminal emulator. But terminal emulator isn't preinstalled in my rom. Is it ok to install it from play store after I flash data2ext2-v7.zip or this is not right?
fforward72 said:
In step 11 you said to reboot into rom immediately after flashing data2ext2-v7.zip and open terminal emulator. But terminal emulator isn't preinstalled in my rom. Is it ok to install it from play store after I flash data2ext2-v7.zip or this is not right?
Click to expand...
Click to collapse
You can install from the market
Sent from my HERO200 using xda app-developers app
ajrty33 said:
You can install from the market
Sent from my HERO200 using xda app-developers app
Click to expand...
Click to collapse
Thanks a lot!
laie1472 said:
You can still achieve that without the combination of both mods.
#Root-Hack_Mod*Always\=LTE
Click to expand...
Click to collapse
How? The firerats mod allows you to change the /system and /cache partition sizes, but from what I can find, data2ext only applies the /ext partition to the /data partition to make the phone utilize the /ext partition as /data, and doesn't allow for modification of the /system and /cache partitions.
Updated
Edit: Updated again to fix minor wording issues and make links much prettier!
Can I use twrp recovery on this firerats. Or is it only the provided cwm recovery ?
Sent from my HERO200
So I flashed this data2ext on my desire, the phone recognized my ext partition as internal memory, but, I can't install any apps, I always get the message "application not installed".
Any ideas?
dankdank11 said:
Can I use twrp recovery on this firerats. Or is it only the provided cwm recovery ?
Click to expand...
Click to collapse
Firerats has nothing to do with recovery. It's about resizing partitions. Recovery functions on a level above, so whatever you do with firerats won't affect it. TWRP is a great recovery program.
Tux2609 said:
So I flashed this data2ext on my desire, the phone recognized my ext partition as internal memory, but, I can't install any apps, I always get the message "application not installed". Any ideas?
Click to expand...
Click to collapse
Try again. Go through the instructions verbatim, as outlined. I wouldn't deviate in any way.

Categories

Resources