• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Root Can I install a custom recovery when my usb port is not working?

I am aware of the risks. whut are the terminal commands?

First the partition will have to be found. I forget what the command is, but there is a command to pull the list of all of the partitions that are on the disk. Then a mount point would have to be created. Basicly you
Code:
su
mkdir (a directory somwhere, perferably on root (/))
mount (I forget the proper format here, but you want to set it up as the mount would normally be set up. I think it's set up for FAT)
cd (to the directory you made and mounted)
ls (this would show you the directory's contents, which should be /mobile)
cd mobile (or MOBILE)
ls (you should see boot.img, recovery.img and what not)
cp (the location of your custom recovery) recovery.img
That should do it.
This isn't a flashed process, I haven't tested it, it should work. The main danger is in the copy and mounting parts.
 
  • Like
Reactions: trippseventeen
Upvote 0
I wiggled the male connector inside the usb port around with a dental pick. As long as I use OE cable, I can get usb connected with the cable in just the right position. Not good advice, I know; i am not responsible for any damage!(except to my own phones) but this rescued a 100% dead usb port. no charge, no usb.

Well I'm glad you got something working. You could charge the battery externally, as long as you have a custom CWR you can flash what ever you want. If you need a recovery made into a flashable file, let me know.
 
Upvote 0
Well I'm glad you got something working. You could charge the battery externally, as long as you have a custom CWR you can flash what ever you want. If you need a recovery made into a flashable file, let me know.

That would be great,i'm trying to flash CWM on my roommate's Triumph. The screen is mildly responsive on mine,the usb port doesn't work on his. We both got screwed on that deal..lol
 
Upvote 0
I have Terminal Emulator. I just need the flashable zip you referenced earlier.

Using the terminal is going the manual way of "flashing" stuff. Basically when you flash, the recovery system follows a script. If you are using TE, then you will have to do the heavy lifting.

First, get the recovery you want and extract the recovery.img

Then use the guide that I posted earlier to mount the mobile partition and load the custom recover over. You have to be very careful here as you could brick the phone. I'm thing on my phone so expressing the seriousness it's harder to express.
 
Upvote 0
Using the terminal is going the manual way of "flashing" stuff. Basically when you flash, the recovery system follows a script. If you are using TE, then you will have to do the heavy lifting.

First, get the recovery you want and extract the recovery.img

Then use the guide that I posted earlier to mount the mobile partition and load the custom recover over. You have to be very careful here as you could brick the phone. I'm thing on my phone so expressing the seriousness it's harder to express.

Ryder, is this ( /dev/block/mmcblk0p1) the correct location?

I was just thinking...
Could he also extract the script from the zip file and run it (slightly modified) with script manager or something... Just to avoid a serious mistake?
 
Upvote 0
Ryder, is this ( /dev/block/mmcblk0p1) the correct location?

I was just thinking...
Could he also extract the script from the zip file and run it (slightly modified) with script manager or something... Just to avoid a serious mistake?

The script is written for the recovery program and wouldn't work for bash. I don't know what script manager uses. If it can understand the commands used in recovery then I don't see why it wouldn't work.

As far as the partition location I would have to get back to that. I haven't turned on one of my own computers since Saturday. Kida going through withdrawls.:eek: If one would look at the updater script for the custom recovery then it will have the partition listed.
 
Upvote 0
Yeah, ok... How about this then:

Assuming he's working on a bone stock phone...

He could get root access using terminal emulator, and download the flash_image.apk (assuming it isn't already in the stock ROM) and that should greatly simplify the commands in Terminal Emulator.

yes?

Edit:
And yeah... ( /dev/block/mmcblk0p1 ) is correct.
I just checked :D
 
Upvote 0
Why wouldn't it be as simple as this:

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


Assuming recovery.img was extracted to root of SD card.

I wonder if the phone has dd_rescue. and if I'm correct that would apply the image to the mmcblk0p1. We don't need to do that, we just need to mount the partition to a directory and move the recovery image to it. That should overwrite the old recovery (which should be renamed in some way to keep as a backup) and be done.
 
Upvote 0
Ok, this works. I just changed my recovery in terminal emulator.

Extract recovery.img from the flashable zip, to the root of SD card (you can put it elsewhere but for this example, that's where I put it)

I'll explain the lines in parenthesis

In terminal emulator, type:


Su (for superuser permission)

mkdir /sdcard/mobile

(makes the directory "/mobile" on SD card)

mount /dev/block/mmcblk0p1 /sdcard/mobile

(this mounts the triumph's recovery partition to the mobile directory of SD card)

cp /sdcard/recovery.img /sdcard/mobile/image

(this line copies the previously extracted CWM recovery.img to the proper directory of mounted partition, over-writing stock recovery. Proper procedure would be to rename original first as back up)

umount /sdcard/mobile

(unmounts the recovery partition)

reboot recovery

(hopefully reboots into CWM recovery so you can check it)

Ryder, can you check my spelling and stuff? And make sure I did it right. Worked for me when I tested it.
 
Upvote 0
Ok, this works. I just changed my recovery in terminal emulator.

Extract recovery.img from the flashable zip, to the root of SD card (you can put it elsewhere but for this example, that's where I put it)

I'll explain the lines in parenthesis

In terminal emulator, type:


Su (for superuser permission)

mkdir /sdcard/mobile

(makes the directory "/mobile" on SD card)

mount /dev/block/mmcblk0p1 /sdcard/mobile

(this mounts the triumph's recovery partition to the mobile directory of SD card)

cp /sdcard/recovery.img /sdcard/mobile/image

(this line copies the previously extracted CWM recovery.img to the proper directory of mounted partition, over-writing stock recovery. Proper procedure would be to rename original first as back up)

umount /sdcard/mobile

(unmounts the recovery partition)

reboot recovery

(hopefully reboots into CWM recovery so you can check it)

Ryder, can you check my spelling and stuff? And make sure I did it right. Worked for me when I tested it.

HA, it was the spelling part that I was stuck on when My boss came around.
If it worked I would say that you did it right. I didn't think of mounting it under anything under than root (/). Thanks for the dugh moment.

Now he just needs to get it to stop vibrating.
 
  • Like
Reactions: markzombie82
Upvote 0
HA, it was the spelling part that I was stuck on when My boss came around.
If it worked I would say that you did it right. I didn't think of mounting it under anything under than root (/). Thanks for the dugh moment.

Now he just needs to get it to stop vibrating.

It did work for me, but you know how it is, trying to type your steps in a message. Easy to miss errors... Especially when using Swype.

The vibrating thing... Boot partition messed up?
It may well be a goner unless the USB port is repaired.
 
Upvote 0
It did work for me, but you know how it is, trying to type your steps in a message. Easy to miss errors... Especially when using Swype.

The vibrating thing... Boot partition messed up?
It may well be a goner unless the USB port is repaired.

If I had it I would try to repair the USB enough to get a custom recobery on it and go from there.
 
  • Like
Reactions: thangfish
Upvote 0

BEST TECH IN 2023

We've been tracking upcoming products and ranking the best tech since 2007. Thanks for trusting our opinion: we get rewarded through affiliate links that earn us a commission and we invite you to learn more about us.

Smartphones