How to root the CDMA Hero - Hero CDMA Android Development

Ok everyone. First off do not update your phone if Sprint offers an upate. I don't think they are going to but if they do anytime soon and you update this exploit could likely be fixed. When updates are released the devs will make updates that keep root so do not update!
That said, this is a very newbie guide. This is meant for Windows but I will post instructions for linux as well (Ubuntu). I just need to warn you that I can't adb into my phone from Ubuntu so I have to do it through Windows. Don't know why it doesnt work but it doesnt. Mac users you can always (assuming you can get it to work in Ubuntu) download a live cd and boot into Ubuntu to try this. I don't have a mac (nor do I want one) so I can't give instructions (though I assume they should be relatively the same).
Step 1:
First you need to download the Android SDK. It may soumd confusing but it's not. There are tools in here that we need. You can get it from http://developer.android.com/sdk/index.html. This is a modular SDK and all the tools we need are in this download. Once downloaded you just need to extract it in a directory of choice.
The next thing we download is asroot2. This is a script that was developed that runs an exploit in Android's linux that allows us to run root. The link for that is here: http://forum.xda-developers.com/attachment.php?attachmentid=244212&d=1257621154. Unzip that file and place it in a directory of your choice. Also download http://www.androidspin.com/downloads.php?dir=amon_ra/RECOVERY/&file=recovery-RA-heroc-v1.2.3.img and place that into the same directory you extracted asroot2.
Step 2:
Connect the phone to the USB port.
Ubuntu is easy for this (again assuming it works for you). Simply open a terminal and cd into the directory that you extracted the sdk into. Then cd into the tools directory. Then run the following commands:
sudo ./adb push /directory_you_placed_asroot2/asroot2 /data/local/
sudo ./adb shell chmod 0755 /data/local/asroot2
/data/local/asroot2 /system/bin/sh
mount -o remount,rw -t yaffs2 /dev/block/mtdblock3 /system
cd /system/bin
cat sh > su
chmod 4755 su
If all goes well you should be presented with a new prompt. This is the linux terminal built into Android. This will allow us to execute all the commands we need to execute because the asroot2 script gave us root access.
In Windows it is a little more difficult. You have to first install the driver for the phone. When Windows asks you for the drivers direct Windows to the directory you extracted the SDK into. You should see a folder called usb_driver. If you are running the 32 bit version of Windows select the x86 folder. If you are using a 64 bit version then select the x64 folder. Then select the android_usb.inf file. This should install the drivers.
If running XP or lower you will need to go to the start menu and click run, then you enter cmd and press enter. If Vista or higher you will press the start button and type cmd and press enter. When you are at the command prompt you cd to the directory you extracted the sdk into. Then cd into the tools directory. Then execute the following commands:
adb push /directory_you_placed_asroot2/asroot2 /data/local/
adb shell
chmod 0755 /data/local/asroot2
/data/local/asroot2 /system/bin/sh
mount -o remount,rw -t yaffs2 /dev/block/mtdblock3 /system
cd /system/bin
cat sh > su
chmod 4755 su
Now your phone is officially rooted! We arent done yet though. Now you need to flash the recovery image. If you are still in adb shell type in exit until you are out. You should be in the directory where you extracted the recovery image. If not go there. Type in the following:
adb push recovery-RA-heroc-v1.2.3.img /sdcard/
Once that is done, type in adb shell (or sudo ./adb shell in ubuntu). If your command prompt is a dollar sign then type in su and press enter. If it is a pound sign you are good. Then type in the following:
adb shell flash_image recovery recovery-RA-heroc-v1.2.3.img
Once that is finished you are done. To reboot into recovery type in adb shell reboot recovery. You should reboot into recovery mode. Right now there is not a lot you can do but once we have some devs who make some roms then we will be well on our way to an even more awesome phone. Any questions please ask away. Also, I am sorry if this tutorial is hard to understand or badly laid out. My daughter is crawling all over me so it's hard to type or think. Good luck all and thanks to everyone who rooted this phone and made the recovery and did such a great job!

chuckhriczko said:
adb shell flash_image recovery recovery-RA-heroc-v1.2.3.img
Click to expand...
Click to collapse
Is this the right command, every time I try I get : "adb: not found"
The transfer to the sd card seemed to go fine, and I am @ root (#).
Am I missing something?

You beat me to it!!!! I was planning on laying out the steps to make sure I had my head on straight.
To continue with your guide: (The following are questions, not procedures)
1. We run a Nandroid back up to lock in our stock ROM so if we ever do something stupid, aka brick the phone, we can push this back on?
2. What comes on the SD card? Is it needing to be backed up when I go to a 16GB class 6 card?
3. Insert the new SDcard and use the ext2/swap/fat32 script
4. convert ext2 to ext3, (now ready for apps2SD?)
Anything else you can add would be nice.
Again thanks for the steps! They are clear for me.

rockcrawler said:
Is this the right command, every time I try I get : "adb: not found"
The transfer to the sd card seemed to go fine, and I am @ root (#).
Am I missing something?
Click to expand...
Click to collapse
Sounds like you need to add the directory where you have adb to be added to he path. is your adb in the same dir as the image?

rockcrawler said:
Is this the right command, every time I try I get : "adb: not found"
The transfer to the sd card seemed to go fine, and I am @ root (#).
Am I missing something?
Click to expand...
Click to collapse
You may currently be in adb shell already. If you are showing the pound sign this is likely. The command is supposed to be run outside of adb shell. Try the command below:
flash_image recovery recovery-RA-heroc-v1.2.3.img

Treefallingquietly said:
Sounds like you need to add the directory where you have adb to be added to he path. is your adb in the same dir as the image?
Click to expand...
Click to collapse
I apologize, but that went right over my head.
I have used this command to copy the image to the sd card.
Code:
adb push recovery-RA-heroc-v1.2.3.img /sdcard/
I got this output:
Code:
C:\androidSDK\android-sdk-windows\tools>adb push recovery-RA-heroc-v1.2.3.img /s
dcard/
1640 KB/s (3352576 bytes in 1.996s)
I then do the following with the noted result:
Code:
C:\androidSDK\android-sdk-windows\tools>adb shell
$ su
su
# adb shell flash_image recovery recovery-RA-heroc-v1.2.3.img
adb shell flash_image recovery recovery-RA-heroc-v1.2.3.img
adb: not found
Any help as to where I making my mistake would be greatly appreciated.

Treefallingquietly said:
You beat me to it!!!! I was planning on laying out the steps to make sure I had my head on straight.
To continue with your guide: (The following are questions, not procedures)
1. We run a Nandroid back up to lock in our stock ROM so if we ever do something stupid, aka brick the phone, we can push this back on?
Click to expand...
Click to collapse
Yes. A nandroid backup completely backs up every piece of information on your phone. It is a complete image of your phone and if it needs to be restored for whatever reason you just load up recovery and can restore it the way it was before.
Treefallingquietly said:
2. What comes on the SD card? Is it needing to be backed up when I go to a 16GB class 6 card?
Click to expand...
Click to collapse
What do you mean exactly? The only thing that gets copied to an sd card is the nandroid backup so yes, when switching to an sd card just do another backup. Or you can also copy the nandroid folder from your existing sd card to your new one.
Treefallingquietly said:
3. Insert the new SDcard and use the ext2/swap/fat32 script
4. convert ext2 to ext3, (now ready for apps2SD?)
Click to expand...
Click to collapse
Yes and no. Just run the ext2/swap/fat32 script and it should be ready for apps2sd. You can convert to ext3 if you want. Generally on normal hard drives ext3 is faster, however there has been some controversy with that on android phones. As for converting to apps2sd, right now the best way is probably the manual method which I can write up a tutorial on as well. The dream forum has some good tutorials on it as they were the first to do it. I actually need to go back and re read some of those because it's been so long since I did it. I tried the apps2sd apk but that didnt seem to work for me.

rockcrawler said:
I apologize, but that went right over my head.
I have used this command to copy the image to the sd card.
Code:
adb push recovery-RA-heroc-v1.2.3.img /sdcard/
I got this output:
Code:
C:\androidSDK\android-sdk-windows\tools>adb push recovery-RA-heroc-v1.2.3.img /s
dcard/
1640 KB/s (3352576 bytes in 1.996s)
I then do the following with the noted result:
Code:
C:\androidSDK\android-sdk-windows\tools>adb shell
$ su
su
# adb shell flash_image recovery recovery-RA-heroc-v1.2.3.img
adb shell flash_image recovery recovery-RA-heroc-v1.2.3.img
adb: not found
Any help as to where I making my mistake would be greatly appreciated.
Click to expand...
Click to collapse
Yeah. The problem is that you are trying to adb shell twice. After you adb push then just run the command adb shell flash_image recovery recovery-RA-heroc-v1.2.3.img. That should work.

chuckhriczko said:
You may currently be in adb shell already. If you are showing the pound sign this is likely. The command is supposed to be run outside of adb shell. Try the command below:
flash_image recovery recovery-RA-heroc-v1.2.3.img
Click to expand...
Click to collapse
Now I get the Following:
Code:
# flash_image recovery recovery-RA-heroc-v1.2.3.img
flash_image recovery recovery-RA-heroc-v1.2.3.img
error opening recovery-RA-heroc-v1.2.3.img: No such file or directory
#
And this outside adb shell, in the same directory where I did the push:
Code:
C:\androidSDK\android-sdk-windows\tools>adb shell flash_image recovery recovery-
RA-heroc-v1.2.3.img
error opening recovery-RA-heroc-v1.2.3.img: No such file or directory
Ideas?

rockcrawler said:
Is this the right command, every time I try I get : "adb: not found"
The transfer to the sd card seemed to go fine, and I am @ root (#).
Am I missing something?
Click to expand...
Click to collapse
yes he left out the /sdcard/in the path and if you are in teh shell you don't need the adb portion of the command.

rockcrawler said:
Now I get the Following:
Code:
# flash_image recovery recovery-RA-heroc-v1.2.3.img
flash_image recovery recovery-RA-heroc-v1.2.3.img
error opening recovery-RA-heroc-v1.2.3.img: No such file or directory
#
And this outside adb shell, in the same directory where I did the push:
Code:
C:\androidSDK\android-sdk-windows\tools>adb shell flash_image recovery recovery-
RA-heroc-v1.2.3.img
error opening recovery-RA-heroc-v1.2.3.img: No such file or directory
Ideas?
Click to expand...
Click to collapse
Ok. Most likely you dont have the recovery image in the directory. Try this. Copy the recovery image to the tools directory of the sdk. Then, outside of adb shell, (making sure you are in the tools directory of the sdk) execute the following command:
adb shell flash_image recovery recovery-RA-heroc-v1.2.3.img
This should work as long as you have the recovery image in the correct directory.

can i use the rom from modaco? or at least the themes?

magicalan said:
can i use the rom from modaco? or at least the themes?
Click to expand...
Click to collapse
No way! This rom is a GSM rom and if it works at all and does not brick your phone then it wont have the right software to make your phone work. A dev has to create a rom specially for the CDMA Hero that has the right drivers.

chuckhriczko said:
Ok. Most likely you dont have the recovery image in the directory. Try this. Copy the recovery image to the tools directory of the sdk. Then, outside of adb shell, (making sure you are in the tools directory of the sdk) execute the following command:
adb shell flash_image recovery recovery-RA-heroc-v1.2.3.img
This should work as long as you have the recovery image in the correct directory.
Click to expand...
Click to collapse
I am feeling really special, not being able to make this work, but that is the folder that it has been in all this time. I have even downloaded and pushed it several times. Proof:
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
So I am not sure where I am messing up.
Thanks for all the help and hard work on this BTW!

rockcrawler said:
I am feeling really special, not being able to make this work, but that is the folder that it has been in all this time. I have even downloaded and pushed it several times. Proof:
So I am not sure where I am messing up.
Thanks for all the help and hard work on this BTW!
Click to expand...
Click to collapse
Meh. Not hard work. Just experience. The hard work is what the rom devs do. And it is difficult at first but once you get it trust me, you get it.Okay let's try this. Go into the command prompt (not adb shell) into the folder where adb and the recovery image is. Try to execute the following command and see if it works.
Code:
adb push recovery-RA-heroc-v1.2.3.img /sdcard/
This will put the recovery image on the sdcard. If this works then we will continue.

chuckhriczko said:
Meh. Not hard work. Just experience. The hard work is what the rom devs do. And it is difficult at first but once you get it trust me, you get it.Okay let's try this. Go into the command prompt (not adb shell) into the folder where adb and the recovery image is. Try to execute the following command and see if it works.
Code:
adb push recovery-RA-heroc-v1.2.3.img /sdcard/
This will put the recovery image on the sdcard. If this works then we will continue.
Click to expand...
Click to collapse
Done.
Code:
C:\androidSDK\android-sdk-windows\tools>adb push recovery-RA-heroc-v1.2.3.img /s
dcard/
1747 KB/s (3352576 bytes in 1.873s)
C:\androidSDK\android-sdk-windows\tools>

rockcrawler said:
Done.
Code:
C:\androidSDK\android-sdk-windows\tools>adb push recovery-RA-heroc-v1.2.3.img /s
dcard/
1747 KB/s (3352576 bytes in 1.873s)
C:\androidSDK\android-sdk-windows\tools>
Click to expand...
Click to collapse
Sweetness. Ok. Now type in the following:
Code:
$ adb shell
$ cd /sdcard/
$ su
# flash_image recovery recovery-RA-heroc-v1.2.3.img
That should work. Note, don't type in the $ or the #. Those are just there to show what the command prompt should look like.

THANK YOU!!!!!
chuckhriczko said:
Sweetness. Ok. Now type in the following:
Code:
$ adb shell
$ cd /sdcard/
$ su
# flash_image recovery recovery-RA-heroc-v1.2.3.img
That should work. Note, don't type in the $ or the #. Those are just there to show what the command prompt should look like.
Click to expand...
Click to collapse
Worked Like a charm, THANK YOU!!! Just booted to the recovery image and all is well.
p.s. Might want to edit the origional instructions, one your daughter goes to bed, to include the cd to the sd card, that is where my problem was.

rockcrawler said:
Worked Like a charm, THANK YOU!!! Just booted to the recovery image and all is well.
p.s. Might want to edit the origional instructions, one your daughter goes to bed, to include the cd to the sd card, that is where my problem was.
Click to expand...
Click to collapse
If I am able to I will. I understand that the instructions were a little hard to follow for beginners which was what I wanted to avoid. Glad you got it working though. Welcome to the world of Android hacking and please enjoy your stay

I'm getting suck trying to push the recovery img out to my sdcard
Code:
C:\AndroidSDK\tools>adb push recovery-RA-heroc-v1.2.3.img /sdcard/
cannot stat 'recovery-RA-heroc-v1.2.3.img': No such file or directory
I believe I have root access:
Code:
C:\AndroidSDK\tools>adb shell
$ su
su
#

Related

getting root using MAC OS ??

Is there any step by step tutorial to get my htc magic rooted
I can only find posts where they say it is like on windows but without installing files but i have no idea how to enter that prompts on terminal
it would be much appreciated any help. I know i am not the only one interested
cesardeluxe said:
Is there any step by step tutorial to get my htc magic rooted
I can only find posts where they say it is like on windows but without installing files but i have no idea how to enter that prompts on terminal
it would be much appreciated any help. I know i am not the only one interested
Click to expand...
Click to collapse
The commands are the same. Just like Linux users can follow Windows directions but with some substitutions.
Download the SDK here: http://developer.android.com/sdk/1.5_r3/index.html
Follow the instructions here: http://developer.android.com/sdk/1.5_r3/installing.html
Once you have the SDK setup, you can follow the steps given in the rooting threads/wiki. Any time it says to enter a command you do it in your terminal (which on OSX i think is Terminal.app, use Spotlight to find it).
Hope this helps a bit.
i dont get this:
Code:
On a Mac, look in your home directory for .bash_profile and proceed as for Linux. You can create the .bash_profile if you haven't already set one up on your machine
i don't have that .bash_profile how do i create it?
thanks
Google easy to use and always there for you.
Clinton
yeah but all tutorials are made for xp or even linux.
I have tried to create it using vi command then edited with the path o the sdk tools
but when i type adb it doesn't do anything
i am stuck there
Did you check my link for your bash_profile ? This help at all?
Clinton
cesardeluxe said:
yeah but all tutorials are made for xp or even linux.
I have tried to create it using vi command then edited with the path o the sdk tools
but when i type adb it doesn't do anything
i am stuck there
Click to expand...
Click to collapse
Try reading this:
http://www.tech-recipes.com/rx/2621/os_x_change_path_environment_variable/
Sounds like the Path variable may be in a different file. It is the same on linux, I think it can be in a few places.
Irf you want to use adb without messing with your path you can do the following:
Code:
cd <android-sdk-location>/tools
./adb devices
This is convoluted so get that PATH working and everything should be nice and easy! Good luck.
I use a Mac, and when I was getting started I used the linux tutorials with no problem.
i can push the 2 files using commands to my sd. Adb devices shows my htc ok
but after i enter to fastboot mode the device is no longe shown
i type
Code:
./fastboot boot recovery-new.img
but the only thing i get is
Code:
-bash: fastboot: command not found
i am on tools directory on terminal
i think fastboot is not in the tools directory ...
i'd rather say the error is caused by that then a missing connection.
Does the phone write "FASTBOOT USB" ?
if you type "ls", can you find a file named fastboot in your directory?
cesardeluxe said:
i can push the 2 files using commands to my sd. Adb devices shows my htc ok
but after i enter to fastboot mode the device is no longe shown
i type
Code:
./fastboot boot recovery-new.img
but the only thing i get is
Code:
-bash: fastboot: command not found
i am on tools directory on terminal
Click to expand...
Click to collapse
The files have to be executable. You can do that by running:
Code:
chmod -R +x /path/to/tools
This makes all the files in the tools directory executable with ./
About the .bashrc or .bash_profile if you don't have one in your home directory you can safely make one. With the following command:
Code:
echo "export PATH=$PATH:/path/to/tools/" > ~/.bashrc
or if the file exists just do:
Code:
echo "export PATH=$PATH:/path/to/tools/" >> ~/.bashrc
Remember to restart the shell after you are done with this.
the reason adb work for you is because adb is in tools directory
fastboot does not. You have to get fastboot somewhere else
Whenever you get command not found, you can run another command to check
ls <program you ran>, and see what happened
Example
in your tools directory, where you have no problem running adb push, try doing "ls adb", without the quote
in your tools directory, where you have problem running fastboot, try doing "ls fastboot", without the quote
and you should see what's going on
BTW, this is fairly basic unix environment. If you are having trouble at this stage, you need to get yourself more familiar with unix environment, which is what osx is based on
I am sorry, but i don't really know where's good tutorial on unix
On google, i just search for "mac osx unix shell tutorial:, and come across this site
http://www.osxfaq.com/tutorials/LearningCenter/
Hope this help
Edit 1: btw, here's where you can find fastboot for MAC. Put it in your tools directory. IF you keep the filename as is, you need to type fastboot-mac whenever you see someone mention fastboot
http://www.htc.com/www/support/android/adp.html
yeah you're right fastboot is not on that tools directory. in fact i have looked into the whole sdk folder and i can't find it.
thanks
hey i managed to apply the update thanks to having fastboot-mac on tools folder
but after booting i go to terminal to apply the final step and i get this
Code:
MBdeluxe:tools cesarleon$ ./adb shell flash_image recovery /sdcard/recovery-new.img
error reading /sdcard/recovery-new.img header: Is a directory
what's wrong ?
thank you people
cesardeluxe said:
hey i managed to apply the update thanks to having fastboot-mac on tools folder
but after booting i go to terminal to apply the final step and i get this
Code:
MBdeluxe:tools cesarleon$ ./adb shell flash_image recovery /sdcard/recovery-new.img
error reading /sdcard/recovery-new.img header: Is a directory
what's wrong ?
thank you people
Click to expand...
Click to collapse
Are u sure that recovery.img got transferred properly? Maybe check the rights on it (it not read only or something). What if you mount the sdcard in OS X and copy and paste (vs push)?
If you're trying to flash the recovery image, try
Code:
adb shell mount -a
adb push recovery-new.img /system/recovery.img
adb push recovery-new.img /sdcard/recovery-new.img
adb flash_image recovery /sdcard/recovery-new.img
Hope that helps
adb shell mount -a
Click to expand...
Click to collapse
didn´t work i think the parameter a is not correct
well this is almost the last step! thank you all for your explanations
cesardeluxe said:
hey i managed to apply the update thanks to having fastboot-mac on tools folder
but after booting i go to terminal to apply the final step and i get this
Code:
MBdeluxe:tools cesarleon$ ./adb shell flash_image recovery /sdcard/recovery-new.img
error reading /sdcard/recovery-new.img header: Is a directory
what's wrong ?
thank you people
Click to expand...
Click to collapse
Very odd error message
Do this to check what your phone's sdcard looks like
Code:
adb shell ls -l /sdcard/recovery-new.img
Next, you should grab the file from your phone to your computer. This step assume you are in your tools directory
Code:
adb pull /sdcard/recovery-new.img recovery-new-phone.img
Finally, try to compare the file you have on your computer against the one you got from your phone, and see if they are the same. This assume you have your working recovery-new.img in tools directory
Code:
diff recovery-new.img recovery-new-phone.img
I have not try this diff command, and I assume it'l handle binary diff
If diff can not handle binary file, do ls and check file size. both file should match
Code:
ls -l recovery-new.img recovery-new-phone.img
If your computer and phone recovery-new.img are not the same, download to phone again
cesardeluxe said:
didn´t work i think the parameter a is not correct
well this is almost the last step! thank you all for your explanations
Click to expand...
Click to collapse
You will get Failed Mounts when u run
Code:
adb shell mount -a
You CAN ignore them.
See here: http://forum.xda-developers.com/showthread.php?p=4029461
This may not be the right way to do it but I always just downloaded the recovery to the tools directory of the android sdk. Then fire up the phone in fastboot mode and do:
./fastboot flash recovery recovery-new.img
(replacing recovery-new.img with the name of the downloaded img file.)
I'm sure there is a reason people are doing it the other way, but for myself one command to do the flash is alot easier!

[How to] [Linux] Root Hboot 2.02

For anyone having issues with running this in linux.
I used zikronix guide and modified it for use in a linux support thread. The original thread can be found here:
http://forum.xda-developers.com/showthread.php?t=829045
This is my setup:
-I made sure to show my .bashrc profile and path to my tools folder if you needed help getting that setup as well... If not please ignore.
Code:
[email protected]:~$ cat .bashrc | grep adb
alias start-adb='sudo /usr/local/android-sdk/tools/./adb start-server'
alias kill-adb='sudo /usr/local/android-sdk/tools/./adb kill-server'
[email protected]:~$ cat .bashrc | grep android-sdk
export PATH="/usr/local/android-sdk/tools/:${PATH}"
[email protected]:~$ $PATH
bash: /usr/local/android-sdk/tools/:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:
Download: http://www.wackynoodle.com/hboot202-s_off-V6.2.zip
Download (Mirror): http://sdx-downloads.com/EVO/devs/jerdog/fixes/hboot202-s_off-V6.2.zip
Now This might make things easier.
-I have this so that you are in the same enviroment that i was in so that the paths will be the same.
Code:
wget http://www.wackynoodle.com/hboot202-s_off-V6.2.zip
mkdir Evo-root
mv hboot202-s_off-V6.2.zip
cd Evo-root
unzip hboot202-s_off-V6.2.zip
- This step I just made sure that adb devices showed my device. If not get it working.
- Once adb devices showed my device properly, I simply ran the following commands.
Code:
adb push root/unrevoked-forever.zip /sdcard/
adb push root/mtd-eng.img /sdcard/
adb push pc36img/PC36IMG-ENG.zip /sdcard/PC36IMG.zip
adb push root/flash_image /data/local/
adb push root/rageagainstthecage /data/local/tmp
adb push root/amon_ra.img /sdcard/
- Then this is just changing permissions. Pretty straight forward.
Code:
adb shell
chmod 0755 /data/local/tmp/rageagainstthecage
chmod 0755 /data/local/flash_image
- Running the script. Should kick you out of adb... If not after 5 min kill the adb server and restart.
Code:
adb shell
./data/local/tmp/rageagainstthecage
- Now you should see a "#", if you do proceed. If not then run the script above again till it works.
Code:
adb shell
- If you saw that "#" run this. This can only be ran as root "#" means root.
Code:
./data/local/flash_image misc /sdcard/mtd-eng.img
Now you are going to want to reboot into the bootloader. Make sure once you do that you selet bootloader and let the PC36IMG.zip load.
Code:
reboot bootloader
After that is done reboot into the new rooted rom. Then make sure adb works again. Then run the following commands. Make sure you terminal is in the same directory this entire time there is no reason to leave the direcory we went into earlier "cd Evo-root" You directory should always be Evo-root. Thanks. The part that I found out was the second command where the entire recovery/ needed the permissions changed to be executable. As you saw in my post on that forum board.
- This will remove the PC36IMG.zip to a different name so that the bootloader won't get confused again. Then the second commands makes the directory executable recursivly. Then the third will reboot you into recovery.
Code:
adb shell mv /sdcard/PC36IMG.zip /sdcard/PC36IMG-ENG.zip
chmod -R +x recovery/
adb reboot recovery
- Now this is going to be done at the recovery screen. As long as you followed the steps above it will work fine. Should only take you about 20 mins to root this phone. Though it took me about 2 hours since no one else has been rooting using linux. I am thinking about writing a script that will root everything and alls you have to do is follow a terminal guide.... But ill see.
- Just run these commands that will allow you to flash the unrevoked-forever.zip. Once you follow the onscreen instructions of the unrevoked-forever.zip you will be able to reboot into the recovery and see the S-Off. Once that is done reboot into the rom, now we need to flash a custom recovery!
Code:
adb push recovery /
adb shell busybox --install /sbin
adb shell nohup /sbin/recovery &
- Again make sure your terminal was never closed and in the same folder. Then simply run these commands to flash the Amon_ra recovery. Since it has wimax capabilities I prefer it.
Code:
adb push root/flash_image /data/local/
adb shell
chmod 0755 /data/local/flash_image
./data/local/flash_image recovery /sdcard/amon_ra.img
reboot recovery
Now you should see the custom recovery and you should be able to flash any rom you desire!
reserved for later use
i see that they are same commands as the pc.., so would this also work with PC?
nickespi said:
i see that they are same commands as the pc.., so would this also work with PC?
Click to expand...
Click to collapse
I am guessing your talking about windows? Sure make sure adb is in your path. Though there are steps in here that are only for linux.
95% success
Well I want to thank you for this thread
It has worked for me I have root I have NAND unlocked
I can flash ROMs
The only issue I have is my radio/baseband and PRI version have been lowered
I have not been able to get thise back where they whould with either update or by using teh wimax.ADDRESS.tree.xml fix (there is no file with that)
If you have any ideas how to fix this would be much appreciated
I am unable to get higher tahn baseband 1.36.00.04.02 in ant rom
when I got teh phone it was 2.15.00.xx.xx
any help would be appreciated
100% Success
THANK YOU
My Evo
Hardware 004
Build 3.30
Hboot 2.02
Baseband 2.15.xx.xx
is now sucessfully rooted.
I did have some problems after being able to flash ROMs of not haveing PRI and Baseband updated.
On thread #787756 there are downloads that can be flashed to fix this problem if anyone else is in that boat.
zikronix sent me there for the fix...I believe he is adding it to the main thread but if it isn't there yet I wanted to add it now for anyone in my boat.
Again this method works and there is success.
Happy rooting
Hey thanx for this Linux guide. Does this steps work with the update 12.25.10 on the windows thread?
Will you update this guide?

foobar'd android

Could someone pm a link to framework-res.apk from /system/frameworks/. I am stuck in a boot loop and the drive i had that file backed up to failed.
any help would greatly be appreciated
in droid explorer it shows up as android system
http://www.mediafire.com/?63798kh3vex715o
When you are going to push it follow my instructions
Copy it to the memory/or your memory card
in adb type this
Code:
adb shell
su
cp sdcard/framework-res.apk system/framework/framework-res.apk
if its not on the main memory and its on your memory card type this
Code:
adb shell
su
cp sdcard/_ExternalSD/framework-res.apk system/framework/framework-res.apk
after you do that the phone will recognize the original framework and you will be fine.
PS: Although the root exploring app sees the framework-res.apk it may not be registered with the phone and it gets fixed by pushing it using adb shell
now remember do not do adb shell cp sdcard/whatever.apk because the phone will not allow it for some reason...... FOLLOW MY INSTRUCTIONS
OMG thank you i am going crazy with this drive i am in linux now, so i'll just push this from adb in recovery...
death1246 said:
http://www.mediafire.com/?63798kh3vex715o
When you are going to push it follow my instructions
Copy it to the memory/or your memory card
in adb type this
Code:
adb shell
su
cp sdcard/framework-res.apk system/framework-res.apk
if its not on the main memory and its on your memory card type this
Code:
adb shell
su
cp sdcard/_ExternalSD/framework-res.apk system/framework-res.apk
after you do that the phone will recognize the original framework and you will be fine.
PS: Although the root exploring app sees the framework-res.apk it may not be registered with the phone and it gets fixed by pushing it using adb shell
now remember do not do adb shell cp sdcard/whatever.apk because the phone will not allow it for some reason...... FOLLOW MY INSTRUCTIONS
Click to expand...
Click to collapse
Err no... that won't work.
Code:
adb shell
su
busybox mount -o,remount -rw /system
stop
cp /sdcard/_ExternalSD/framework-res.apk /system/framework/
reboot
Will deliver a much better (working) result...
Since we're not sure how to do this, this is what i did:
Well the system was boot-looping on the kernel level so neither instructions were accurate.
I first installed the test version CWM recovery, from there I mounted system from inside recovery and then i used these commands
Code:
adb push ./framework-res.apk /sdcard/framwork-res.apk
adb shell
cp /sdcard/framework-res.apk /system/framework/
then i rebooted and crossed my fingers till it finally booted
I thought he was doing it through recovery and he knew to mount the system already...
death1246 said:
I thought he was doing it through recovery and he knew to mount the system already...
Click to expand...
Click to collapse
And the file would have gone where?
holy **** lol I seriosuly thought I put in framework folder OMFG......
bare with me it was 6am XD
EPIC FAIL ON ME lol
F.U.B.A.R.

sh: can't open installbusybox.sh

Follwing this to install ubuntu:
http://trsohmers.com/2011/03/06/how-to-run-ubuntu-on-the-motorola-xoom/
But I get the message sh: can't open installbusybox.sh
Everything was fine up until that moment, can you help me?
You sure you're in the correct directory? According to the guide (if you're following it step by step) it should be on /sdcard, so when you go into the shell, the next command would be cd /sdcard to make sure you're in there then you can run sh installbusybox.sh
Yeah, after I do adb shell, su, cd /sdcard
Also, adb push doesn't seem to work so I had to manually put them in the SD card. It gives me an error when I try to push.
Usually the correct way to do a "push" would be to use adb push filename.ext /sdcard/ (making sure you put down the last slash to let it know you're pushing it to a directory, I tend to find it give me an error elsewise).
Another thing you can try to do is type sh ./busyboxinstaller.sh, see if that makes any differences.
The push works now with the other slash, but with the sh command, I get this error now:
mkdir: can't create directory '/system/xbin':file exists
Okay, I got STEP TWO: Installing Ubuntu. I had to install busybox from the market. Then, I can't cd to the /sdcard/ubuntu It says cd: can't cd to /sdcard/ubuntu

[Q] Using ADB from Terminal Emulator

I recently received my Transformer back after RMA-ing it for a non functioning screen. Of course, even though the problem lied with the hardware, they still unrooted and reinstalled stock firmware on it. Everything on it works, except for the USB cable that seems to be either not working, or because they installed all my apps and settings back on the tablet, something's wrong. This is a problem when it comes to rooting it again. What I'm trying to do is run the commands through the Terminal Emulator, but here is what happens:
Code:
[email protected]: /sdcard $ adb start-server
* Daemon not running, starting it on port 5038 *
* Daemon started successfully *
[email protected]: /sdcard $ adb connect localhost:5038
connected to localhost:5038
[email protected]: /sdcard $ adb push su /data/local/tmp
error: device not found
So my question is, is it even possible to do this? If not, is there another way to do it?
Thanks in advanced for any help!
adb is the android debugging bridge what it does is changes your shell from your computer to your device so you do not need to run anything that refers to adb from your device
Hmm, run Wolf's exploit but remove 'adb' from all the commands, pretend you're already in the shell. (Because you are)
Thing O Doom said:
Hmm, run Wolf's exploit but remove 'adb' from all the commands, pretend you're already in the shell. (Because you are)
Click to expand...
Click to collapse
Yeah, I've tried that too.
Code:
/system/bin/sh: push: not found
aldude999 said:
Yeah, I've tried that too.
Code:
/system/bin/sh: push: not found
Click to expand...
Click to collapse
push is an adb command not a terminal command
mrevankyle said:
push is an adb command not a terminal command
Click to expand...
Click to collapse
I understand that.
I've been trying mv with no luck:
Code:
mv /sdcard/su /data/local/tmp
failed on '/sdcard/su' - Cross-device link
Download a Recovery.zip you want, and then extract the file called 'recoveryblob' out of it. (I highly recommend Rouge XM touch)
Place it on the root of your internal storage /sdcard/.
Run this:
Code:
mv /data/local/tmp /data/local/tmp.bak
ln -s /dev/block/mmcblk0p4 /data/local/tmp
exit
reboot the tab, get back in, run this:
Code:
dd if=/sdcard/recoveryblob of=/dev/block/mmcblk0p4
reboot again, then you see a blue bar if it worked.
Then you can access CWM recovery that you just flashed with dd, and use that to install the Superuser or SuperSU .zip
Thing O Doom said:
Download a Recovery.zip you want, and then extract the file called 'recoveryblob' out of it. (I highly recommend Rouge XM touch)
Place it on the root of your internal storage /sdcard/.
Run this:
Code:
mv /data/local/tmp /data/local/tmp.bak
ln -s /dev/block/mmcblk0p4 /data/local/tmp
exit
reboot the tab, get back in, run this:
Code:
dd if=/sdcard/recoveryblob of=/dev/block/mmcblk0p4
reboot again, then you see a blue bar if it worked.
Then you can access CWM recovery that you just flashed with dd, and use that to install the Superuser or SuperSU .zip
Click to expand...
Click to collapse
Code:
mv /data/local/tmp /data/local/tmp.bak
failed on '/data/local/tmp' - Permission denied
EDIT: Also, I've tried chmod, and I get an Operation not permitted error.
This is a TF101 correct? What stock firmware is it running?
You need to get USB working again.
Thing O Doom said:
This is a TF101 correct? What stock firmware is it running?
You need to get USB working again.
Click to expand...
Click to collapse
Yes It's running completely up to date (unfortunately) 9.2.1.24.
aldude999 said:
Yeah, I've tried that too.
Code:
/system/bin/sh: push: not found
Click to expand...
Click to collapse
It might help to understand what is going on. In this case, adb push su /data/tmp becomes "cp su /data/tmp/" if you are running from the terminal. You'll need stronger linux-fu.
You might also need a few extra /'s at the end of *some* of your commands.
sent from my transformer
gee one said:
It might help to understand what is going on. In this case, adb push su /data/tmp becomes "cp su /data/tmp/" if you are running from the terminal. You'll need stronger linux-fu.
You might also need a few extra /'s at the end of *some* of your commands.
sent from my transformer
Click to expand...
Click to collapse
Yeah, I gotcha, but the only command I have that comes close to cp is mv, and all the commands are very strictly limited.

Categories

Resources