Android: Uninstall Factory Applications

After I rooted my Android phone, via the steps here, my first task was to un-install the bloat-ware.  Before removing apps, I made sure to Google my phone to see what apps were safe to remove.  Here’s a sample list I referenced.

Though there are GUI apps available in the Play store, I chose to use Android Terminal Emulator (ATE).   This is a command-line tool for entering Linux commands.  Here are the key commands to use:

1.  Open ATE and give yourself administrative/super user access by typing:

  • su

2.  Navigate to the application directory and list the currently installed applications (Note that *.apx are the main application files):

  • ls /system/app
3.  To remove an app, type the following command variant:
  •  rm /system/app/(APPNAME).apk
Note:  There is no resulting prompt identifying that the file was deleted.

4. It is likely that you will receive the following message: 

  • rm failed for /system/app/com.amazon.mp3.apk, Read-only file system

If this occurs, you need to mount your /system as read-write before you can delete.  This is the command I used for my ROM:

  • mount -o,remount -t yaffs2 /dev/block/mtdblock4 /system

5.  Many .apk apps have a related *.odex file.  It is beyond the scope of this post to explain the filetypes but you can remove them after you remove the *.apk :

  • rm /system/app/(APPNAME).odex

Once you’re done with the app removals, you may notice that you have not acquired more free space.  This is because the applications’ space are still being held in the Dalvik cache.  This cache is a temporary space used by the Java virtual machine to run Android applications. No worry, you can reclaim this space by utilizing the ATE:

1. Again, open ATE and give yourself administrative/super user access by typing:

  • su

 2.  Navigate to the Davik cache:

  • cd data/dalvik-cache

3.  Clear the cache:

  • rm *

4.  Leave ATE by typing:

  • exit

5.  Reboot your device.

Android: Root Your Device

Lately, I’ve been receiving allot of “Phone Almost Out Of Memory” messages on my Android 2.2.1.  I was frequently having to delete text messages and clearing browser cache, etc.   Interestingly (and suspiciously) enough, at this time I also became eligible for my “new-every-two” phone.  I saw this as a perfect opportunity to do some rooting and other experimentations.  After all, if I bricked the phone I would just get a new one.  Here are the steps that I would advise before rooting:

1.  PREPARE YOUR BRAIN:

  • If you’ve never heard of rooting, Linux, .NET Framework, or “command line” then STOP NOW, STEP AWAY from your device, and continue no further. 

2.  PREPARE YOUR WINDOWS PC:

  • Make sure you have at least .NET Framework 2.0 installed (I used Win7 with .NET 4.0.)
  • Download the drivers for your Android device from the manufacturer’s website or, if available, the CD that came with your device.
  • Download SuperOneClick via the developers blog. (I used v2.3.3.)  If you prepare to do all the heavy-lifting instead of using a software solution then continue no further. 

3.  PREPARE YOUR ANDROID DEVICE:

  • Back up your SD card.
  • It is also advised that you back up your entire system by using Titanium Backup or similar software. I skipped this step. Like I mentioned, mine is an old phone that is headed to my graveyard of disassembled devices.
  • Enable USB Debugging mode on your Android by navigating Android: Tap Menu > Settings > Applications > Development.
  • Unmount your SD card: Tap Menu > “SD Card & Phone Storage” then “Unmount SD Card.” 

4. ROOT IT

  • Connect the device to your PC via USB.
  • On your PC, navigate to and click on SuperOneClick.exe.
  • Finally, the SuperOneClick software opens up and you then click “Root.” 

You’ve done it.  You can now get SuperUser access, uninstall bloat-ware, replace your ROM, or whatever your imagination desires.    See “Un-installing Apps.”