yashsingh1/xdaforums huggingface dataset:
[G2 and Desire Z Android Development] ramainli:
Great guide. I liked it a lot more than Unforgivens just because it doesn't rely on VisionARY which might mess things up.
[G2 and Desire Z Android Development] tornado9015:
Guide worked absolutely great, no problems. I did not try the visionary method first, but for some reason I just felt safer doing it in adb.

Thank you!
[G2 and Desire Z Android Development] RaffieKol:
Sorry for the noob question...? but does this mean we have fully rooted to G2 and now we can load ROMS on it when they come out ????

Edit: Nevermind I didnt see the sticky
[G2 and Desire Z Android Development] trigeek:
You got it!
[G2 and Desire Z Android Development] androidtoy09:
Custome ROMs, custom Recovery...the whole 9 yards :D
[G2 and Desire Z Android Development] heyitsmeehd:
Thanks for posting this, it was so easy! :D
[G2 and Desire Z Android Development] imblacklife:
Thank you so very much it was a success
[G2 and Desire Z Android Development] juanshop:
this is my first rooting on an android device... im freaking out... but here i go.... if something happens i will just report my phone lost and get a new one i guess ahahah still... im scared.
[G2 and Desire Z Android Development] joackie27:
Issues

I was temp rooted before using rage and then thru Visionary. But I decided to go back to stock till we have permanent root. I perm rooted today using this method. But I'm having the following issues:

1) adb remount

- remount failed: Operation not permitted

2) when using Root Explorer in /system, toggling Mount R/W does not work

- the only way to mount it R/O is thru terminal/adb shell. Once mounted R/O, the only way to mount R/W again is thru a reboot. Issuing mount -o remount ro /system either in terminal or adb shell does not work.
[G2 and Desire Z Android Development] juanshop:
i actually changed my mind... im going to wait for a one click untended root i guess.... to scary...
[G2 and Desire Z Android Development] hiddengopher:
make sure you have debugging enabled.
[G2 and Desire Z Android Development] hiddengopher:
Not gonna happen.
[G2 and Desire Z Android Development] juanshop:
then i guess.... im going to jump in it.... wish me luck...
[G2 and Desire Z Android Development] scoreo99:
Thats the n00b route ;)
[G2 and Desire Z Android Development] the orange bandit:
LMAO, says the guy with 8 posts to the guy with 111.......;)
[G2 and Desire Z Android Development] vrav:
I got mine working too....

I tried it too, it works!!!!

download the system back to pre OTA software using this link:

http://xdaforums.com/showthread.php?t=831398

The link for the XVI editor is (this is needed in the step above):

http://www.chmaas.handshake.de/delphi/freeware/xvi32/xvi32.htm

and use rage to perm-root and s-off: (with wpthis-pre-OTA.ko)

http://xdaforums.com/showthread.php?t=834228

Then apply OTA.

and re-do rage to perm-root and s-off again: (with wpthis-OTA.ko)

http://xdaforums.com/showthread.php?t=834228

I just tested it, it works beautifully. It takes about 1 hour total!

I have root, S-OFF and OTA now.

Thanks everyone!!
[G2 and Desire Z Android Development] antdawg702:
HELP! I successfully rooted using thus method. Then when I was asleep my phone automatically installed the ota update and I lost root and visionary says I am already rooted and doesn't do anything. How do I get root back?

Edit: wrong thread sorry
[G2 and Desire Z Android Development] jijus:
my g2 is not visible to adb, but fastboot! can i do this in fastboot? then how? thanks

C:\android-sdk-windows\tools>adb shell

error: device not found

C:\android-sdk-windows\tools>fastboot devices

HT09SR210608 fastboot
[G2 and Desire Z Android Development] fastludeh22:
Guys if your s-off you've already won the battle. All you need to do is go the the clockwork mod recovery thread. Grab the recovery that says for manually flashing from fastboot. Put that img on the root of your computers c drive named recovery.img. then download rom of your choice, I suggest starting with my stock w/root rom, and put it on the root of your sdcard.

*you will have to have adb/fastboot installed and working for this next step:

boot the phone into fastboot. And on the computer type "fastboot flash recovery c:\recovery.img" when its done you will have cwm recovery. Select recovery from the menu on the phone. BACKUP first. Then wipe data and wipe cache. Then go down to flash zip from sd, select zip from sd, then select the rom u downloaded.(be sure to follow the instructions on flashing that rom in whatever rom u choose to uses thread). Once that's done, your done. Reboot and enjoy!
[G2 and Desire Z Android Development] scoreo99:
yeah that makes complete sense. Reflash your ROM back to complete factory, as we all seemed to have had an issue where visionary mucked up the original OS ROM image.

I think either way you go tho, u have to reflash back to complete factory settings from a different image on the sd card.
[G2 and Desire Z Android Development] buzmay:
Thanks a lot for this :)
[G2 and Desire Z Android Development] gn02256676:
Thank you so much for this awesome guide

Just a quick question though, I rooted it without OTA, and after root it still want to me update.

Should I update it after i rooted? if not, how do I disable it so it won't bother me?
[G2 and Desire Z Android Development] mcjerica:
Great guide, worked like a charm. Just picked up a G2 to replace my failCLIQ. This phone is pro.
[G2 and Desire Z Android Development] backache:
Thank you! I got it working from your post. Awesome! I'll be sure to donate ;)
[G2 and Desire Z Android Development] ayalah1986:
Alright see this is cool if u can temp root..... but what about us that can't even temp root anymore???
[G2 and Desire Z Android Development] ayalah1986:
another attempt gone wrong...

im trying it but im on ubuntu and its telling me that i that command is wrong anybody here knows how to run this on ubuntu?? missing my root sooo bad!!!
[G2 and Desire Z Android Development] astj1991:
jordan-asts-macbook-pro:tools jordanast$ ./adb push /users/jordanast/desktop/g2temproot/su /sdcard/su

cannot stat '/users/jordanast/desktop/g2temproot/su': No such file or directory

what am i doing wrong here? i unzipped the temp root to a folder on my desktop and labeled it g2temproot

the file that unzipped was one named g2_pc.bat , is that the correct file supposed to be in the g2temproot folder?
[G2 and Desire Z Android Development] instigator008:
You will have to downgrade/reinstall the stock firmware using the guide on this site. Visionary corrupted alot of people's installation. Use the cage method to root next time.
[G2 and Desire Z Android Development] mastermindg:
Follow this guide to install Android SDK on Ubuntu:

http://maketecheasier.com/install-android-sdk-in-ubuntu-karmic/2010/01/11

Fastboot binary:

http://developer.htc.com/adp.html
[G2 and Desire Z Android Development] mastermindg:
Does anybody know if Rage disables boot audio?

I've pushed android_audio.mp3 to /data/local alond with my boot animation and I'm not hearing anything.
[G2 and Desire Z Android Development] fastludeh22:
Exactly. I assumed that it was already installed per op requirements. Sorry guys updated my post. Once u have adb/fastboot(I think fastboot is included with sdk, but not 100% sure) follow my instructions exactly, no need to push su or anything else.

No u don't. Once your s-off you can do everything manually. No reason to ever flash pc10/downgrade unless to fully unroot to return phone.
[G2 and Desire Z Android Development] kalipedia:
The file that unzipped was g2_pc.bat? I don't know where that's coming from. If you download the file from the OP (vision-combined-root.zip), there are two folders in it: G2TempRoot and vision-perm-root. In G2TempRoot are the following files: busybox, config, rage, root, su, Superuser.apk. In the vision-perm-root folder are: hboot-eng.img, vision-perm-root.md5sum, wpthis-OTA.ko, wpthis-pre-OTA.ko.

I moved both folders (with their contents) to my desktop and proceeded from there.

Hope this helps!
[G2 and Desire Z Android Development] ZombieUsr:
I'm on visionary r12...temp rooted. How do I know if visionary already borked my G2 to root using rage?
[G2 and Desire Z Android Development] scoreo99:
you CAN temproot if you use /data/local/tmp/rage from the terminal
[G2 and Desire Z Android Development] ZombieUsr:
Any one on my q and a?
[G2 and Desire Z Android Development] Krazi Bluntz:
I new to ADB i just installed it and I got my computer to recongize the phone it is listed under the devices in cmd ... however when I type in the adb shell command it says permission denied ... I don't know what I'm doing wrong ... thank you for any help in advance
[G2 and Desire Z Android Development] mastermindg:
Krazi: which OS are you running. On Ubuntu I had to create a new udev rule for my phone.

ken@msg1:/etc/udev/rules.d$ cat 51-android.rules
SUBSYSTEM=="usb", ATTRS{idVendor}=="0bb4", ATTRS{idProduct}=="0c91",
MODE="0666"

Note: lsusb to pull vendor/product
[G2 and Desire Z Android Development] Krazi Bluntz:
I'm using Windows 7 .. after I type in the command to check the device I typed in "adb shell" and after that I got "$" sign in the next line (because its not rooted I know that but you could push files without root).. then when I type in the command to push it says permission denied or even if I type "adb" to list the commands it says permission denied .. thanks for you help
[G2 and Desire Z Android Development] fastludeh22:
Your not supposed to issue adb commands from shell. From your windows cmd you type adb push file /place/your/pushing/to
[G2 and Desire Z Android Development] Krazi Bluntz:
O thanks I feel like a dummy .. I pushed everything to my phone followed the steps in OP exactly .. now I got stuck when I wrote the

# /data/local/tmp/root

in terminal

I get

# /data/local/tmp/root
mkdir failed for /system/xbin, File exists
cp: can't stat '/system/xbin/busybox': Not a directory
Unable to chmod /system/xbin/busybox: Not a directory
/data/local/tmp/root: /system/xbin/busybox: not found
cp: not found
cp: not found
Unable to chmod /system/bin/su: No such file or directory
#

Edit: THANKS FASTLUDEH22 :D
[G2 and Desire Z Android Development] ayalah1986:
Nm lol I was answering ur q but it looks like u got it
[G2 and Desire Z Android Development] compounddj:
Problem with procedure.

Didnt see anyone else with this problem...why me?

at the step "adb shell chmod 0755 /data/local/tmp/*" i get

"Unable to chmod /data/local/tmp/wpa_supplicant: Operation not permitted"

am I the only one. Is there a solution?
[G2 and Desire Z Android Development] Krazi Bluntz:
Problem Solved :)
[G2 and Desire Z Android Development] DimensionFX:
Hi,

if i type this command $ adb shell chmod 0755 /data/local/tmp/* I don't get any message! Is there something wrong. I checked it several times all is right.

If I go to the next step and type it all in the terminal emulator I get the message permission denied.

Can anyone help me please. The Visionary+ app don't work by me it always flashed up rooting bla bla but no finishing.

thank you

Edit: ok I solved the problem... I have S-OFF but when I open a terminal and type su I get permission denied...
[G2 and Desire Z Android Development] starscalling:
well got the bastard going.

**do the ota update first**

**had to get usb drivers elsewhere - win7 issue**​
[G2 and Desire Z Android Development] mx7:
Just rooted using the steps posted by the OP.

Many thanks to all the folks that helped make this happen!
[G2 and Desire Z Android Development] johnacraft:
Make sure that both 'superuser.apk' and 'su' are in /sdcard/. If 'su' is placed in /sdcard/su/, you'll get an error.

On a separate note: once you've got perma-root, is it necessary to leave 'superuser.apk' and 'su' on the SD card, or can they be deleted?

Thanks to all for the great work.
[G2 and Desire Z Android Development] ZombieUsr:
Again anyone have an answer to my question. I am temp rooted with Visionary r12. Tried to perm root with same app. No dice. If I delete visionary....would I still have borked my phone if I do rage?
[G2 and Desire Z Android Development] fastludeh22:
Well it depends on what happened from visionary, but I bet we can fix it. First boot into fastboot. Power+vol down, tell me if its s-off. If it is follow my post a couple pages back. If its s-on follow op instructions and report back with any errors.
[G2 and Desire Z Android Development] jbaxter088:
Help! Rooting with Rage. Gone through all steps several times!!

Hey, So I've been reading the whole forum several times this weekend on how to root using the Rage method. I have done it several times now, even after clearing my phone several times. Each time I run into the same problem. After I put the final code in:

# /data/local/tmp/root

I get:

# /data/local/tmp/root

mkdir failed for /system/xbin, File exists

cp: can't stat '/system/xbin/busybox': Not a directory

Unable to chmod /system/xbin/busybox: Not a directory

/data/local/tmp/root: /system/xbin/busybox: not found

cp: not found

cp: not found

Unable to chmod /system/bin/su: No such file or directory

#

I have also gone through the Clockworkmod Recovery to fix it, as some posts have suggested but I get:

"An error occurred while attempting to run privileged commands!"

I even check in terminal: $su but I get "Permission Denied"

Please help! I would really like to know what I'm doing wrong. All files are in the SDK tools folder. I am still new to this but I am running into a wall. Either message me here or email me at jbaxter088@gmail.com. Thank You!! I would really appreciate it! :D
[G2 and Desire Z Android Development] fromCliq2G2:
I was having this problem with my G2 after a failed attempt using the Visionary Perm root method. What I did was roll my phone back to the stock out of the box 1.19.531.1 which can be found here (http://xdaforums.com/showthread.php?t=831398) The only difference is I used Terminal Emulator on my G2 instead of adb shell commands.

You will need

Hex editor, which can be found in the post mentioned above

adb setup on your computer

Stock Rom, found on the above mentioned thread

OTA update.zip file

Terminal emulator installed on your G2, available on the market

G2TempRoot.zip, found in this thread

vision-perm-root.zip, found in this thread

First download and install all the items mentioned above.

Second start following the steps at the beginning of this thread

ON YOUR PC

1) Unzip the G2TempRoot files to a folder. From a cmd window or terminal, navigate to that folder and execute these commands:

Code:

$ adb push su /sdcard/su

$ adb push Superuser.apk /sdcard/Superuser.apk

$ adb push rage /data/local/tmp/rage

$ adb push busybox /data/local/tmp/busybox

$ adb push root /data/local/tmp/root

$ adb shell chmod 0755 /data/local/tmp/*

ON YOUR PHONE:

2) Launch Terminal Emulator

/data/local/tmp/rage

Wait for the message: "Forked #### childs."

3) Menu > Reset Term - Terminal Emulator will exit.

4) Launch Terminal Emulator, it Force Closes. Launch a second time, and you'll have a root shell

Now refer to the roll back portion

ON YOUR PC

5) Download ROM and rename to PC10IMG.zip

6) Place on root of SD card //make shure to unmount usb storage after//

ON YOUR PHONE

in terminal emulator enter

dd if=/dev/block/mmcblk0p17 of=/sdcard/misc.img

ON YOUR PC

7) copy misc.img from the root of the sdcard to your computer //Copy So as to preserv a backup of misc.img on the SD card//

8) open the misc.img in the HeX editor

9) now edit the version line from somthing like

1.22.531.8

This will be whatever the version you are on currently

to

1.19.531.1

10) now save as miscnew.img

11) copy miscnew.img to sdcard

12) unmount usb storage

ON YOU PHONE (in terminal emulator)

run

dd if=/sdcard/miscnew.img of=/dev/block/mmcblk0p17

13) power off phone

14) boot into hboot by holding down vol-dwn + power

15) the phone should then scan the .zip file and ask to flash

16) after flash you will be downgraded SW and Radio

17) now flash the update to your phone

18) re-attempt the rage root method again and it should go with out a hitch.

Best of luck. What I noticed is the visionary method somehow corrupted files with in the system that made the ROM not recongize the root but emulator would. I did not use adb for the initial steps because I wasn't sure if it would work. I hope this helps anyone else that is stuck in the unrootable loop visionary may have left you in.
[G2 and Desire Z Android Development] jbaxter088:
Thanks, I will try this asap and let ya know if it works. I do have two questions. Where do I get OTA Update.zip? and should I wipe my phone again and start this from scratch or should I just go ahead where I am now. I do have S-Off but I don't have Super User Permissions.
[G2 and Desire Z Android Development] jbaxter088:
Worked great. Thanks for the tip. It was awesome.
[G2 and Desire Z Android Development] diehardfan:
I used visionary methord to permroot but it did not work, HBOOT shows S-OFF. But, clockwork mod says its not rooted.

I want to try the rage methord instead, can I just try the rage method directly straight from Temp root of this tutorial or do I need to anything else first (reflash to stock)?
[G2 and Desire Z Android Development] quierotacobell:
Nvm got it working, thank you!
[G2 and Desire Z Android Development] j.youngberg:
I got stuck pretty early in the process and I am on a Mac. After hitting "./adb push su /sdcard/su" I get this:

cannot stat 'su': No such file or directory

Any help?
[G2 and Desire Z Android Development] ZombieUsr:
I get that or su: permission denied
[G2 and Desire Z Android Development] rdunn20:
problem with adb

ive been trying to permroot this phone for awhile. ive used windows 7, vista, and xp but none make a dif. i have full sdk on all my computers and have files downloaded but when i try to push any files it tells me adb permissions denied. any help would be great. send me a pm
[G2 and Desire Z Android Development] kalipedia:
you can check out my post from earlier on in this thread, and perhaps that will help: http://xdaforums.com/showthread.php?p=9234410#post9234410
[G2 and Desire Z Android Development] diehardfan:
anyone?

Thanks
[G2 and Desire Z Android Development] neophyte8:
Follow them and don't rush the process

First of all, thank you very much for this.... i was on the same boat and frustation took over and stoped trying to find a solution untill i saw your instructions, (even though I rooted my original mytouch and nexus without problems) followed them and now I'm enjoying cyanogen's rom. Couple of things my help anybody else (noob as I am)

1- I would put the files that need to be push to the phone inside your tools folder on your Android-sdk (believe me, makes it a lot easier)

2- HeX editor is not as complicated as it seems, you only need to edit one line.

3- when its time to SYNC, just leave your phone for a while, dont rush it, better to wait 5 minutes than having to re do the entire process.

Best of lucks.
[G2 and Desire Z Android Development] ahb83:
Where can I find the OTA update.zip; is this what #17 is referring to?

[SOLVED] it just asked me for update on the phone and I accepted it. Rooted phone and now it works! visionary sucks
[G2 and Desire Z Android Development] Sleef:
Just wanted to say thanks for the ultra easy to follow instructions. Glad to be back to a native Android phone.
[G2 and Desire Z Android Development] Krazi Bluntz:
In cmd type

cd C:\android-sdk-windows\tools === Press Enter
adb devices === You should see your device listed

Then type the codes in from OP .. I had a similar problem ;)
[G2 and Desire Z Android Development] AnThNeE:
Help! I get "error: device not found" when I try to adb push. Any idea why/what I should do?
[G2 and Desire Z Android Development] ahb83:
do you have USB Debugging mode on?
[G2 and Desire Z Android Development] AnThNeE:
Yeah. It was the first thing I did.
[G2 and Desire Z Android Development] fuzeman001:
Perfect!, As a Linux expert I didn't really want to try VISIONary after the last comments on it weren't that great, I felt this method was a-lot better and I could Trust it.

I'll be sending a donation to scotty2 ASAP.
[G2 and Desire Z Android Development] jijus:
Visionary might semi brickef ur phone call tmobile ns say its stuck at htc screen, you might get another one

Using XDA App from htc Vision
[G2 and Desire Z Android Development] AnThNeE:
Nvm. I got it. Had to find and install the G2 drivers.
[G2 and Desire Z Android Development] wngmv:
Done. On the way to donate to scott2. Thanks a lot for the help! The process couldn't be easier compared to what I did to root G1 a year ago.
[G2 and Desire Z Android Development] primatage:
Worked perfectly!

Just wanted to say thanks, I had been using VISIONary (first r10 then r14), and I liked this method much better for making the move to permroot. Perfect instructions, couldn't be any simpler :)
[G2 and Desire Z Android Development] smokeymp911:
Sorry need a little bit of help here I got past the part on the computer in the terminal manager when i enter

/data/local/tmp/rage

it gives me "/data/local/tmp/rage" permission denied....

Thanks for anyone who's willing to give me some info before hand
[G2 and Desire Z Android Development] DocMAX:
does it also work on phones with QWERTZ keymap? (i have a german desire z from amazon)
[G2 and Desire Z Android Development] steviewevie:
Did this command work ok, i.e. didn't give an error message ?

$ adb shell chmod 0755 /data/local/tmp/*

And you had the asterisk on the end ? No harm in running that again.
[G2 and Desire Z Android Development] smokeymp911:
It worked fine and I checked I had the * at the end I get the error still
[G2 and Desire Z Android Development] steviewevie:
Try doing "adb shell ls -l /data/local/tmp/rage". That can't do any harm.
[G2 and Desire Z Android Development] alex_canada:
Is this a guide that I could use with a Desire Z bought in Canada from Bell?

Thanks!
[G2 and Desire Z Android Development] steviewevie:
Right now there's a separate set of forums for the Desire Z. Hopefully they'll be merged very soon with the G2 ones. But for now, check out the DZ forums regarding rooting your phone.
[G2 and Desire Z Android Development] alex_canada:
Thanks for the quick reply...will do that. I came from that forum because that one has way less info.
[G2 and Desire Z Android Development] steviewevie:
I know what you mean :rolleyes:
[G2 and Desire Z Android Development] dzerjinski:
Hi,

I tried to follow the instructions for my brand new Desire HD and got the error:

- init_module '/data/local/wpthis-OTA.ko' failed (exec format error)

Can anyone help me, please?

thanks
[G2 and Desire Z Android Development] Crey23:
HELP Cannot find device

OK...I'm beginning to think that rooting is not for me!!!! Getting a bit frustrated!!!

OK, so I installed SDK on my pc (Win XP Ver 2002 SP3), and I cannot get it recognize the device.

I tried the guide for dummies here on XDA, and I follow all the indications, server starts up, I can kill it too....but every time I try to run it I get:

"error: device cannot be found"

The line that I am writing is as follows:

c:\android-sdk-windows\tools>adb shell

and I get the error above.

When I try to see if devices are connected, and Use this:

c:\android-sdk-windows\tools>adb devices

I get:

"List of Devices attached", but there is no list!!!!!

But I can see the SDCARD from my computer....I can access the files...

Maybe I can try to pull instead of push, but I'm not sure how that would be written (line wise), not if will work.

BTW...I have never done anything like this on android....very new to this!!!!

umm.. HELP!!!

OK changed pc's,....on this one it does recognize the device, but does not allow me to push anything.....when i try:

adb push su /sdcard/su

I get adb: permisions denied

...

Thanks!
[G2 and Desire Z Android Development] jorobochi:
worked perfect for me 10x

worked perfect for me 10x
[G2 and Desire Z Android Development] steviewevie:
You're in the wrong forum, this is the G2 forum, you need the Desire HD forum.
[G2 and Desire Z Android Development] miked79928:
This worked excellent once I realized that I was typing "adp" instead of "adb".