[HOWTO] ClockworkMod Recovery & TWRP - Upgrade/Downgrade (Touch/Non-Touch Recovery)

Search This thread

PorchSong

Senior Member
Nov 28, 2007
533
315
Denver
[HOWTO] ClockworkMod Recovery & TWRP - Upgrade/Downgrade (Touch/Non-Touch Recovery)

IF YOU TRASH YOUR PHONE USING THIS PROCEDURE, THEN IT IS A VERY GOOD INDICATION YOU ARE AN IDIOT AND SHOULD NOT BE FLASHING ANY ROMS NOR PARTICIPATING ON THESE FORUMS. . . . JUST SAYIN'. . . .

Please be VERY careful when using this method as you can brick your phone. Make sure you triple check the file you downloaded is the right size and placed in the right area, but most importantly that the command lines you type are exactly right. If you are not comfortable using this method, then please do not and go find a flashable version of these recoveries.

I've posted a procedure to format/'flash' your recovery while on your phone in one of the threads on here and was asked by a Forum Mod to make a quickie guide to be placed as a sticky on the dev boards so others might benefit.

Anyway, here is a very quick and easy way to change your ClockworkMod recovery with a couple of command lines.

The TWRP link is in the second post.

Now for the ClockworkMod Instructions:

1. First, go here and look up your ClockworkMod recovery that pertains to your phone: http://www.clockworkmod.com/rommanager
2. Download the .img file for your phone and save it on your computer.
3. Rename the .img file to recovery.img and save it to your internal sd card of your phone. For example: recovery-clockwork-6.0.1.4-hercules.img ------> recovery.img
4. Open up Terminal Emulator on your phone and type the following 2 commands:

su
dd if=/sdcard/recovery.img of=/dev/block/mmcblk0p22


(please note the second command is a one line command with spaces between "dd & if=" and ".img & of=")

If your Rom identifies your internal sdcard as /emmc instead of /sdcard, then make the adjustment to command line (dd if=/emmc/recovery.img) instead of what is posted above.

That simple.

You can also issue these commands from adb shell if you are connected to your computer.

If Terminal Emulator does not have Superuser or SuperSU permissions for root privileges then make sure it does. You can also go from NON Touch CWM to Touch CWM using this and vice versa. Simply make sure you have the right recovery for your phone and rename it to recovery.img.

As for explanations:

dd if= command is a common Unix program whose primary purpose is the low-level copying and conversion of raw data.

dd stands for "data description"
if stands for "input file"
of stands for "output file"

the = is the location of the data you are using. ie. /sdcard/recovery.img

the /dev/block/mmcblk0p22 is the location/partition of the recovery on your phone.

So essentially you are doing a low level rewrite of the recovery image on your phone via command lines.

***Also, the best way to remember this command line is to not to. Copy the command line and save it to your own personal contact info in Google under Notes and then you will have it with you wherever you go. You really do not want to mess with getting it wrong. You could brick your phone if you mess things up.

Anyway, I hope this helps. . . . it really is very easy to execute without fault.
 
Last edited:

PorchSong

Senior Member
Nov 28, 2007
533
315
Denver
Works with TWRP too.

This also works with changing to and from TWRP. Download the image (for our phones it's TWRP 2.3.1.1) rename it to recovery.img and follow the above instructions and you are good to go.

Follow this link to get the image file: http://teamw.in/project/twrp2/101

***I attached the old TWRP 2.2.2.0 is case you run into problems with the newer versions not restoring backups properly or renaming backups correctly.***
 

Attachments

  • openrecovery-twrp-2.2.2.0-hercules.img
    6.6 MB · Views: 2,023
Last edited:

noellenchris

Inactive Recognized Developer / Retired Moderator
May 11, 2007
2,604
890
Marlton, NJ
Excellent Thread, I hope Dev's requiring specific CWM versions can link to your post.

Thanks for your efforts.

Noellenchris
XDA Forum MOD
 

BIGWORM

Forum Moderator
Staff member
Just thought I'd point out a small bug with the Touch Recovery. If you flash one of the newer ICS roms like Darkside Evolution through the Touch Recovery, once booted, the ROM WILL NOT SLEEP through time out. I've confirmed this with 2 separate ICS roms. Flashing non-touch recovery through Rom Manager fixes this problem.
 

PorchSong

Senior Member
Nov 28, 2007
533
315
Denver
What is wrong with ROM Manager? I use it to go between Touch and normal all the time and it works flawlessly.

For some people Rom Manager doesn't work. On the T-Mobile SGH-T989 Galaxy SII, Rom Manager will only allow you to go to 5.0.2.6 not 5.0.2.7. And, I think you have to upgrade Rom Manager to go to Touch. I bought Rom Manager, and don't use Touch Recovery, so I am not sure.

I like to use the command structure verses program because I know it works, it's fast, and I can see the results if an error occurs.
 

SiNJiN76

Senior Member
Sep 14, 2009
3,993
626
Oh yeah...this was really simple...Thanks...went from Touch back to Non Touch.
 

albanianbrotha

Senior Member
Feb 24, 2010
85
1
I get a write error: No space left on device. 1001+0 records in 1000+0 records out 512000 bytes transferred in 0.132 secs.

I reboot into recovery and it's still on 5.0.2.6

Edit: so i closed the terminal and I ran it again, and now my phone won't turn on. I get a USB device in windows called QHSUSB_DLOAD. I hold the power button, and the device disappears, but it won't turn on. I let go of the button, the same device reappears.
 
Last edited:

hobakill

Senior Member
Oct 24, 2011
121
13
chicago
Edit: so i closed the terminal and I ran it again, and now my phone won't turn on. I get a USB device in windows called QHSUSB_DLOAD. I hold the power button, and the device disappears, but it won't turn on. I let go of the button, the same device reappears.

hate to be the dude that tells you this but i'm pretty sure qhsusb_dload is magic windows talk for "hard bricked phone." had that problem a while back. however all is not lost - these guys have a great reputation for Lazarus-ing dead phones.
 

albanianbrotha

Senior Member
Feb 24, 2010
85
1
hate to be the dude that tells you this but i'm pretty sure qhsusb_dload is magic windows talk for "hard bricked phone." had that problem a while back. however all is not lost - these guys have a great reputation for Lazarus-ing dead phones.

Haha no worries bro. I mean worries that it failed for no reason, but I already sent it in, he just got it today. Same person you linked. Definitely trying to install ics again when i get it. Plus I think the ota ics for tmo came out yesterday or something? Probably a better experience than what was already out there with the radio and stuff.
 

PorchSong

Senior Member
Nov 28, 2007
533
315
Denver
the files from the CWM site are not .img for me, they are .ndif is it the same procedure?

No! Do NOT use this procedure with that file extension!

What recovery are you trying to install? And for what phone? I briefly ran my cursor over the various files and the download links are either .img or .zip files. I did not see .ndif file extension.

PM me if you need additional help.
 

fresherthanU

Senior Member
May 10, 2012
125
51
Northwest/burbs, IL
Would you happen to have the .img file for 5.0.2.7??

Edit* Nvm.. a quick google search and I was able to find it. You are a life saver.. I tried updating my recovery to the 6.0.1.2 Hercules port and for a couple days, it was working great up until an hr. ago. Nothing would flash and it would just hang in recovery... so I found this thread and thankfully I was able to downgrade back down to 5.0.2.7.

If you were local, I would take you out and get you piss drunk for helping me save my device. Cheers!!!!
 
Last edited:

PorchSong

Senior Member
Nov 28, 2007
533
315
Denver
Would you happen to have the .img file for 5.0.2.7??

Edit* Nvm.. a quick google search and I was able to find it. You are a life saver.. I tried updating my recovery to the 6.0.1.2 Hercules port and for a couple days, it was working great up until an hr. ago. Nothing would flash and it would just hang in recovery... so I found this thread and thankfully I was able to downgrade back down to 5.0.2.7.

If you were local, I would take you out and get you piss drunk for helping me save my device. Cheers!!!!

You're welcome, I'm glad I could help you. But, the link to the .img files is in the OP instructions. . . .
 

wonker51

Member
Jul 14, 2012
47
1
Unfortunately this method did not work for me... I have tried many ways to update my CWM and none of them worked, it is almost hopeless for me
 

Top Liked Posts

  • There are no posts matching your filters.
  • 44
    [HOWTO] ClockworkMod Recovery & TWRP - Upgrade/Downgrade (Touch/Non-Touch Recovery)

    IF YOU TRASH YOUR PHONE USING THIS PROCEDURE, THEN IT IS A VERY GOOD INDICATION YOU ARE AN IDIOT AND SHOULD NOT BE FLASHING ANY ROMS NOR PARTICIPATING ON THESE FORUMS. . . . JUST SAYIN'. . . .

    Please be VERY careful when using this method as you can brick your phone. Make sure you triple check the file you downloaded is the right size and placed in the right area, but most importantly that the command lines you type are exactly right. If you are not comfortable using this method, then please do not and go find a flashable version of these recoveries.

    I've posted a procedure to format/'flash' your recovery while on your phone in one of the threads on here and was asked by a Forum Mod to make a quickie guide to be placed as a sticky on the dev boards so others might benefit.

    Anyway, here is a very quick and easy way to change your ClockworkMod recovery with a couple of command lines.

    The TWRP link is in the second post.

    Now for the ClockworkMod Instructions:

    1. First, go here and look up your ClockworkMod recovery that pertains to your phone: http://www.clockworkmod.com/rommanager
    2. Download the .img file for your phone and save it on your computer.
    3. Rename the .img file to recovery.img and save it to your internal sd card of your phone. For example: recovery-clockwork-6.0.1.4-hercules.img ------> recovery.img
    4. Open up Terminal Emulator on your phone and type the following 2 commands:

    su
    dd if=/sdcard/recovery.img of=/dev/block/mmcblk0p22


    (please note the second command is a one line command with spaces between "dd & if=" and ".img & of=")

    If your Rom identifies your internal sdcard as /emmc instead of /sdcard, then make the adjustment to command line (dd if=/emmc/recovery.img) instead of what is posted above.

    That simple.

    You can also issue these commands from adb shell if you are connected to your computer.

    If Terminal Emulator does not have Superuser or SuperSU permissions for root privileges then make sure it does. You can also go from NON Touch CWM to Touch CWM using this and vice versa. Simply make sure you have the right recovery for your phone and rename it to recovery.img.

    As for explanations:

    dd if= command is a common Unix program whose primary purpose is the low-level copying and conversion of raw data.

    dd stands for "data description"
    if stands for "input file"
    of stands for "output file"

    the = is the location of the data you are using. ie. /sdcard/recovery.img

    the /dev/block/mmcblk0p22 is the location/partition of the recovery on your phone.

    So essentially you are doing a low level rewrite of the recovery image on your phone via command lines.

    ***Also, the best way to remember this command line is to not to. Copy the command line and save it to your own personal contact info in Google under Notes and then you will have it with you wherever you go. You really do not want to mess with getting it wrong. You could brick your phone if you mess things up.

    Anyway, I hope this helps. . . . it really is very easy to execute without fault.
    5
    Works with TWRP too.

    This also works with changing to and from TWRP. Download the image (for our phones it's TWRP 2.3.1.1) rename it to recovery.img and follow the above instructions and you are good to go.

    Follow this link to get the image file: http://teamw.in/project/twrp2/101

    ***I attached the old TWRP 2.2.2.0 is case you run into problems with the newer versions not restoring backups properly or renaming backups correctly.***
    1
    Thanks for the instructions! Thanks even more for explaining the command lines.
    1
    Give this a try

    If you want a simple way to flash the Touch Recovery then give this a try. I will be adding the Hard Recovery as well in the next release.

    SGSII T989 Root Toolkit
    http://xdaforums.com/showthread.php?t=1650908
    1
    I updated the OP for TWRP (second post). Please note that the new TWRP 2.3.0.0 is NOT restoring backups properly--it seems to factory reset your backups upon reboot (asking you to sign back into your Google account and all your apps are gone). But, your backups made with 2.3.0.0 are still good and can be restored with 2.2.2.0. So, I attached TWRP 2.2.2.0 to the second post. Just download and rename to recovery.img and follow instructions. Again, make sure you save it to the root directory of your internal sd card and enter the command precisely to avoid bricking.