Friday, April 27, 2012

Install Android 4.0 Cyanogenmod 9 Firmware on Galaxy S2 Phone


There is lot of information on Internet about Cyanogenmod, after-market mobile phone firmware installation. However some of this information incomplete and misleading. My first attempt to install Cyanogenmod 9 phone failed. The phone screen played the booting animation in an endless loop. Let me share my installation notes here, this might save you from pulling your hair or worse chucking the phone out of the window.
Disclaimer: Installing third-party firmware will void your phone warranty and if something goes wrong it could make your phone unusable. The installation process will wipe data/apps, Please backup everything.!
Before you get started consider backing up your phone data using Samsung Kies or Android apps such as Titanium Backup. Alternatively you can copy the data manually by connecting the phone to your computer with an USB cable.

Prerequisites: What do you need?


  1. Install Android SDK. We'll use the nifty adb program to manage the phone and debug any problems.
  2. Install phone flashing program, Heimdall on Linux or Odin utility for Windows OS.
  3. Download Clockwork Recovery recovery-clockwork-4.0.1.4-galaxys2.tar. (Please use GT-I9100G_ClockworkMod-Recovery-5.0.2.8.tar file for Samsung Galaxy S2 GT-I1900G phones.)
  4. Download latest Cyanogenmod9 from Cynogenmod download page.
  5. Download gapps-ics-20120422 from goo.im.This package provides standard Google Android applications such as Google Play (A.K.A Google Market).

Installing Clockworkmod(CWM) Recovery

This is an essential tool for our work. The Clockwork Recovery is modified version of the kernel that provides advanced features such as backup/restore phone ROM's and installing Cynogenmod updates. If you plan to dual boot your phone with different Android versions or Mozilla's Boot2Gecko.
The first step to flash ClockworkMod (CWM) onto your phone using heimdall or 0din program.
Unzip recovery-clockwork-4.0.1.4-galaxys2.tar archive and flash it with heimdall command line flashing utility for Samsung phones.


# Download clockworkmod 
$ wget http://cmw.22aaf3.com/c1/recovery/recovery-clockwork-4.0.1.4-galaxys2.tar

# Unzip it 
$ unzip recovery-clockwork-4.0.1.4-galaxys2.tar


#Connect and reboot the phone into download mode with:
$ adb reboot download

heimdall flash --kernel zImage


Please wait for the phone to reboot. If it doesn't work the first time, try again.
Now you can boot into the recovery mode by pressing Volume Up, Home and Power buttons together until Galaxy S2 logo appears on the phone screen. You can navigation the recovery mode screen by using volume up and volume down keys and power button to select an option.

Backup your Phones original ROM

Restart the phone and enter recovery mode. Select Backup/Restore menu and choose Backup. This provide a safety net, you can always restore the original ROM in case the Cyanogenmod 9 installation fails.

Installing CyanogenMod9 Android 4.0 Ice Cream Sandwich(ICS) on Samsung Galaxy S2

Connect your phone to your computer and transfer the previously downloaded files Cyanogenmod 9 and Gapps files. Restart the phone and enter recovery mode by pressing Volume Up, Home and Power buttons together. Follow the steps below to install the Android ICS on your phone.

  1. Select wipe data/factory reset
  2. Select wipe cache partition
  3. Select Advanced Menu and choose wipe dalvik cache
  4. Select Install zip from sdcard and choose update-cm-9-XXX-XXX-XXX-signed.zip file.
  5. Select Install zip from sdcard and choose gapps-ics-2012XXXX-signed.zip file. Reboot phone

That's all folks! Don't forget to share your experiences by leaving a comment here.

38 comments:

  1. Hello, with this process you lost your data/apps installed?

    ReplyDelete
    Replies
    1. Yes, you will lose all the data/apps installed.

      Delete
    2. Yes, you will lose your data/apps. You might have to back up the data to sdcard or to your computer.

      Delete
  2. Hello, I seem to be stuck on the boot screen with the yellow triangle. Thats all my phone does. Why does this happen???? i could simply do a restore but that would restore the old rom. Any advice please?

    ReplyDelete
    Replies
    1. Boot into the recovery mode by pressing Volume Up, Home and Power buttons together. Select Backup/Restore menu and choose previous backup.

      Delete
  3. Works great thanks heaps mate
    very easy instructions and Very Happy

    Regards
    Michael

    ReplyDelete
  4. Hi Arky,
    I follow this steps and I installed ICS successful, but I have problems to add APNs. Simply I can't :S. I enter APNs but don't save. I think it's problem from cyanogenmod's ROM. Are you know about another ROM can I try?

    ReplyDelete
    Replies
    1. Interesting problem, you need to talk to cyanogenmod developers about this.

      Delete
    2. hi,

      I tried reinstalling, but I have the same problem. Then, I don't know why, I rebooted my phone and now works :)

      Delete
  5. Thanks very much for the info. I have been trying to update to ICS for a while but kept getting the boot screen looping. Wiping the data made the difference and it worked a treat. Well happy now. Thanks again.

    ReplyDelete
  6. thanks. its working for me

    Umar

    ReplyDelete
  7. Great, I am glad it worked for you. The 'wipe data' makes all the difference to revive the Phone stuck in ICS bootloop.

    ReplyDelete
  8. the launcher setting disappeard from setting when i do back up data and apps?
    i repeat the procdure but same result again. otherwise its working fine. any suggestion?

    Umar

    ReplyDelete
    Replies
    1. They changed the default launcher in the new release, Cyanogenmod Forum might have more information.

      Delete
  9. How to Install Ice Cream Sandwich on Samsung Galaxy S2

    http://www.youtube.com/watch?v=YP3UWOv3jiI&feature=related

    ReplyDelete
  10. Hey

    I have a Galxy S2. Do i have to use cwm 5.0.2.8 or is 5.0.0.2 fine?

    ReplyDelete
  11. where is the commands for ODIN????

    ReplyDelete
    Replies
    1. Odin is a MS windows graphical application, there are no commands for it.

      Delete
  12. Hello i follow your tutorial but when i made
    heimdall flash --kernel zImage

    my phone is like stuck, doesn't do anything, the screen is black and if i started with (volume -) + home + power, i get a screen who says:
    Warning
    A custom OS can cause critical problems in phone and installed applications.
    ....
    at the end
    ....
    Volume up: Continue
    Volume down: Cancel (restar phone)

    If i start i get the black screen again, if i continue i get a "Downloading..." screen who says:
    ODIN MODE
    PRODUCT NAME: GT-i9100

    what can i do?

    ReplyDelete
    Replies
    1. You are in the phones download mode. Follow the instructions to install the firmware using heimdall or 0din

      Delete
  13. How do you boot into recovery mode when your phone is stuck bootlooping cyanogenmod 9 and the home button is not lit up?

    ReplyDelete
    Replies
    1. You can boot into the recovery mode by pressing Volume Up, Home and Power buttons together even when the home button is not lit.

      Alternatively, you can use Android SDK adb command 'adb reboot recovery' from your computer to put your phone into recovery mode.

      Delete
  14. My SG2 is stuck in a cyanogenmod bootloop and I can't get it to boot in recovery mode. I've tried taking the battery out and I'm sure I'm doing the right procedures, I've booted in recovery mode a few times before.
    I'm on Mac OS X so I can't really use Odin.
    Does anyone know how to fix this issue?
    Any help is greatly appreciated.

    -LeĆ³

    ReplyDelete
    Replies
    1. You will get stuck in bootloop if you don't do following steps. Try it ?

      Select wipe data/factory reset
      Select wipe cache partition
      Select Advanced Menu and choose wipe dalvik cache

      Delete
    2. i did the following and mine stuck. i cant do anything! How can i resolve this problem?

      Delete
  15. I am able to get in to download mode and and run the Odin to install GT-I9100_ClockworkMod-Recovery_X.X.X.X.tar however; after reboot the phone is stuck by Samsung Galaxy S2 GT0i9100 with the yellow triangle and exclamation mark. It will not boot in to recovery mode by pressing volume up+home+power button.

    Running Odin v3 1.85 + GT-I9100G_GB_ClockworkMod-Recovery_5.0.2.8

    I have tried this several times with the same result. Tried removing the battery and rerun the same procedure without success.

    Any ideas?

    ReplyDelete
  16. I have a mytouch 4g Q will this work for me? I'm worried, I don't want to brick my phone or mess it up. Any help? Does anyone have the recovery link and root link. Also how do I get to the root screen on an LG mytouch 4g q?

    ReplyDelete
    Replies
    1. This post deals with Samsung Phone. Don't have a LG phone you mentioned.

      Delete
  17. Thanks! Works perfect!

    ReplyDelete
  18. my cm-9 was working fine but radio fm not funtioning...how to solve this problem..

    ReplyDelete
    Replies
    1. Can you provide more information about your problem Ganesan?

      Delete
  19. Can not find recovery-clockwork-4.0.1.5-galaxys2! I can only find it in .zip format which is useless when Odin will only look for .tar,.md5

    ReplyDelete
    Replies
    1. Simon,

      I hope you'll find the file in this thread http://forum.xda-developers.com/showthread.php?t=1631934

      I think Odin accepts .tar format. Download the file and unzip it. http://androidfirmwares.net/Guide/Details/9

      Delete
  20. Simple and clean guide! Just flashed my S2 successfully without any single error!
    Thanks a lot! Keep it up :)

    ReplyDelete
  21. This comment has been removed by a blog administrator.

    ReplyDelete
  22. hmmm. not sure what went wrong. I got the endless boot animation of the cyan robot, found this blog entry, redid things in your order as you ran into that as well, now it won't go past the samsung logo it first dsiplays. this method seems to have bricked it. (bell galaxy s2). I can still do an odin mode though with the volume down instead of up so I guess I'll try that to save it.

    ReplyDelete
  23. This comment has been removed by a blog administrator.

    ReplyDelete

You can leave a comment here using your Google account, OpenID or as an anonymous user.

Popular Posts