Friday, October 28, 2011

[Tutorial] How to Root a Samsung Galaxy S II


Para leer esto en español, clic aquí.

This tutorial is for the "rooting beginners" and those who want to keep as close to stock as possible. CF-Root takes the kernel from an original Samsung firmware, and just adds root, busybox, and ClockWorkMod (CWM4) recovery


This is not a ROM, it is only a modified kernel. You need to have the relevant firmware already on your device. You do NOT need to wipe anything for this patch. You need to read the instructions.

Features
- The kernel is fully stock and taken from the original firmware, with just the following added:
- Root
- Busybox v1.16.2androidminimal (from CWM)
- Integrated CWM 4.0.0.2

CF-Root v4.1 and older
- Superuser 2.3.6.1
- "Secure" mode

CF-Root v4.2 and newer
- Superuser 3.0
- "Insecure" mode

Requirements
  • Odin v1.85, you can get it here or here
  • CF-Root Insecure Kernel for your Kernel version
  • Stock Kernel for your ROM version, you can get it here (optional)


Which CF Root file do I use ?

Go to Settings -> About phone -> Kernel Version. Note the string present there:

2.6.35.7-I9100XXKG1-CL349526

What matters most (KG1) in this case, is in bold. Try to find the matching file here

CF-Root-SGS2_XX_OXA_KG1-v4.1-CWM4.zip 

Instructions
  1. Unzip CF-Root-xxx-vX.X.zip
  2. (USB) Disconnect your phone from your computer
  3. Start ODIN
  4. Click the PDA button, and select CF-Root-xxx-vX.X.tar
  5. Put your phone in download mode
  6. (USB) Connect the phone to your computer
  7. Make sure repartition is NOT checked
  8. Click the START button
  9. Wait for the phone to reboot
  10. Done (if it took you more than 30 seconds, you need practise!)
To Remove the Yellow/warning Triangle (Insecure Kernel) on Boot, do this:
  1. You have to follow the previous steps to root your phone
  2. Extract the Stock Kernel
  3. (USB) Disconnect your phone from your computer
  4. Start ODIN
  5. Click the PDA button, and select the Stock Kernel (usually a .tar file)
  6. Put your phone in download mode
  7. (USB) Connect the phone to your computer
  8. Make sure repartition is NOT checked
  9. Click the START button
  10. Wait for the phone to reboot
  11. (USB) Connect the phone to your computer
  12. Unzip CF-Root-xxx-vX.X.zip (you should get a zImage file)
  13. Copy the zImage file (must be called zImage) to your phone
  14. Stop sharing SD card with computer over USB, unplug the cable, etc
  15. Applications -> CWM -> Flash kernel. Select the zImage file on your SD card.
  16. Done, you have now a rooted phone and no yellow/warning triangle.

I did this process on my phone and didn't have any problems, If you have any questions feel free to add a comment or send me a message and I will be happy to help you.

This tutorial is based on Chainfire's post at XDA-Developers

Carlos A Jimenez