Can't flash recovery file - LineageOS Questions & Answers

Hi,
I'm trying to install LineageOS on Xiaomi Redmi Note 7. Everything worked fine until I tried to flash a recovery file. After typing this command: fastboot flash recovery recovery_name.img it says it can't find a file with that name. I tried putting a path before the name, but then it says access denied. Any help?
Thanks

Nextros said:
Hi,
I'm trying to install LineageOS on Xiaomi Redmi Note 7. Everything worked fine until I tried to flash a recovery file. After typing this command: fastboot flash recovery recovery_name.img it says it can't find a file with that name. I tried putting a path before the name, but then it says access denied. Any help?
Thanks
Click to expand...
Click to collapse
You never used the windows command window before?
Type dir to see files and folders
Type cd <name> to change folder till you see .img file

kurtn said:
You never used the windows command window before?
Type dir to see files and folders
Type cd <name> to change folder till you see .img file
Click to expand...
Click to collapse
I was thinking about navigating to the folder where I saved it, but didn't try it as I was in a car. Anyway, it worked. Thanks.

Related

Wiped Phone Now Can't See SD Card On Lappy, PLEASE HELP

I used Team win Recovery Project to wipe my phone Galaxy Nexus, and now when I plug the phone in to the lappy it doesn't show the sd card. Freaking out here cause I can't copy over a zip file to flash a ROM... please help...
The GNEX doesn't have an actual sdcard, so when you wiped the phone i'm guessing you wiped the virtual sd card.
You will have to adb push a rom to your phone.
One the top of the first Q&A page jubakuba has a guide that has a panic section in it.
The guide also shows how to install adb/fastboot and gives you the commands.
try flash the stock img via fastboot using the following line to avoid wiping ur sdcard
fastboot update ***.zip
then wipe data via CWM and enjoy
xskordeal said:
try flash the stock img via fastboot using the following line to avoid wiping ur sdcard
fastboot update ***.zip
then wipe data via CWM and enjoy
Click to expand...
Click to collapse
sorry, complete DOLT here. Where would I input the command?
If you don't know about adb/fastboot, do as suggested in first post. All is explained in the guide.
How to get to a MS-DOS prompt or Windows command line
TheDodgey said:
sorry, complete DOLT here. Where would I input the command?
Click to expand...
Click to collapse
Click Start.
Click Run.
Type cmd or command and press enter.
gpfnzl said:
If you don't know about adb/fastboot, do as suggested in first post. All is explained in the guide.
Click to expand...
Click to collapse
ok, following your instructions, and the instructions of the link, I have install ADB and can use cmd, however when I type adb shell, I get an error returning "device not found"
I see a lot of threads stating to make sure usb debugging is on, it was before I wiped the phone, but obviously I cant get to any settings at the moment.
on the verge of crying now, and noone likes to see a grown man cry
FIXED
I ran the push command whilst in recovery and it worked
not sure that it mattered, but I did change the zip file name to ROM.zip, and whilst in recovery, ran the comand "adb push ROM.zip /sdcard/ROM.zip
Just thought I would put that in there for other dopes like me that might come across this problem
Thanks to all for your help!
LOL
Normally if you can't see your device listed you haven't installed the drivers correctly.(or the correct drivers)
Also you have to open a command prompt window in the same folder as fastboot.exe and adb.exe
To do this in Windows 7:
Click the windows start button (bottom left hand corner)
In the search bar at the bottom type: cmd
At the top of the search list you will see the program cmd.exe right click and copy it.
Paste it into the same folder that has fastboot.exe and adb.exe
Now you can open the cmd window and type the command:
adb devices
Hit ENTER and if you have installed drivers correctly, the serial number of your phone will be listed.
If not, uninstall the drivers, download a new set of drivers from jubakuba or efrants guide and reinstall.
---------- Post added at 11:58 AM ---------- Previous post was at 11:53 AM ----------
TheDodgey said:
FIXED
I ran the push command whilst in recovery and it worked
not sure that it mattered, but I did change the zip file name to ROM.zip, and whilst in recovery, ran the comand "adb push ROM.zip /sdcard/ROM.zip
Just thought I would put that in there for other dopes like me that might come across this problem
Thanks to all for your help!
Click to expand...
Click to collapse
didn't need to change the name of the rom zip. Just needed to type the full name of the .zip file.
Good to see it worked, and the tears have stopped

[Q] ROM install SDCard USB issues.

So, my problem is that I have recently unlocked the bootloader on my HTC One X using my Mac and the very helpful guide provided on this YouTube link
http://youtu.be/8Y3VbFJIwWU
No problems with the process in that video and I've gotten to the end with the phone bootloader definitely.
My problem is that I've then attempted to install a custom ROM from the SD card. Again, this seems to work fine, but upon reboot I'm immediately hit with a continual pop-up 'unfortunately, the process com.android.phone has stopped' with the only option to press ok. It loops continuously.
I suspect I may have to reinstall the ROM onto the SD card, but this is my problem. I cannot get my phone's USB access to work on my Mac as I am stuck with the above pop-up preventing me. I can't seem to access it via Recovery either.
Can I use fastboot to 'flash' over the *.img or *.zip of a new ROM to get it onto the SD card? Stuck with a phone I can't use otherwise. :crying:
Thanks.
Mount usb storage from the recovery.
Sent from my HTC One X using xda app-developers app
or while in recovery type
Code:
adb push rom.zip sdcard/
Thanks for that, athulele . :good:
I have tried that. On a Mac, for USB access requires that I use software called 'Android File Transfer' rather than the way Windows would do it. That software doesn't kick in via Recovery mounting. So, I'm going to need a different approach.
Since I have Windows installed via Bootcamp, I think I'll try to connect the phone up via Windows and see whether I can access the SD card via USB using that route.
Any other help is most welcome.
you do not need that file, just boot into recovery and type the command above... it's the easiest way
matt95 said:
you do not need that file, just boot into recovery and type the command above... it's the easiest way
Click to expand...
Click to collapse
Having booted into recovery, using Terminal on my Mac and typing
adb push sentinelrom_v4_30_endeavoru.zip sdcard/
gives the following message:
-bash: adb: command not found
Am I doing something wrong here?
well, have you got the sdk installed on your mac?
matt95 said:
well, have you got the sdk installed on your mac?
Click to expand...
Click to collapse
I've now downloaded the sdk for mac. It's a adt bundle folder with many files inside. I've installed 'Eclipse' but I'm still getting the same message as before from the Terminal. What else do I need to do here?
Im not into macs .... but don't you need to enter sudo commands before the adb/fastboot commands ?
no, he only needs to navigate to the adb directory with the terminal and then type
Code:
./adb push rom.zip sdcard/
matt95 said:
no, he only needs to navigate to the adb directory with the terminal and then type
Code:
./adb push rom.zip sdcard/
Click to expand...
Click to collapse
Hi matt95
I'm grateful for the help you are giving me here. I've found the adb file within the following downloaded directory path:
act-bundle-mac-x86_64-20130219 - sdk - platform-tools - adb
When I changed directory in Terminal to this path and ensured the specific rom.zip was also in that path, Terminal is still giving me this:
./adb push sentinelrom_v4_30_endeavoru.zip sdcard/
-bash: ./adb: No such file or directory
I must be doing something not right. Please help further.
that's strange, could you provide me the platform-tools folder and the rom.zip folder? i'll write down what you exactly have to write...
matt95 said:
that's strange, could you provide me the platform-tools folder and the rom.zip folder? i'll write down what you exactly have to write...
Click to expand...
Click to collapse
Folder contents as described.
Thanks.
ok now i need their directory, for ex. /User/yourusernane/Docuemnts/ecc ecc......
matt95 said:
ok now i need their directory, for ex. /User/yourusernane/Docuemnts/ecc ecc......
Click to expand...
Click to collapse
/Users/srafferty73/Downloads/adt-bundle-mac-x86_64-20130219/sdk/platform-tools
and
/Users/srafferty73/Downloads/adt-bundle-mac-x86_64-20130219/sdk/platform-tools/sentinelrom_v4_30_endeavoru
Thanks.
ok, now open the therminal ans type
Code:
cd /Users/srafferty73/Downloads/adt-bundle-mac-x86_64-20130219/sdk/platform-tools
./adb push (drag the rom.zip into terminal) sdcard/
now it should work
matt95 said:
ok, now open the therminal ans type
Code:
cd /Users/srafferty73/Downloads/adt-bundle-mac-x86_64-20130219/sdk/platform-tools
./adb push (drag the rom.zip into terminal) sdcard/
now it should work
Click to expand...
Click to collapse
Slowly making progress. Latest Terminal message after doing that reads 'error: device not found'.
I am using ClockworMod Recovery v5.8.2.7 and have clicked on 'mount /sdcard'. I have tried to 'mount USB storage' but am getting an error message which reads 'E: Unable to open ums lunfile (No such file or directory).'
What should I do next?
Thanks.
fingerbob said:
Slowly making progress. Latest Terminal message after doing that reads 'error: device not found'.
I am using ClockworMod Recovery v5.8.2.7 and have clicked on 'mount /sdcard'. I have tried to 'mount USB storage' but am getting an error message which reads 'E: Unable to open ums lunfile (No such file or directory).'
What should I do next?
Thanks.
Click to expand...
Click to collapse
Flash a newer recovery.
Mr Hofs said:
Flash a newer recovery.
Click to expand...
Click to collapse
I managed to find a copy of ClockworkMod Recovery v5.8.4.0 and flashed this as advised. This has somehow enabled the USB facility on my phone to start working again and I can replace the ROM I've downloaded onto it.
I just tried reinstalling the ROM I had again, but once again got the original message stated in my first post. I'm about to now try a different ROM to see if that makes any difference.
:good:

[Q] how to root htc one?

What is the easiest method to root HTC one that is on 4.2.2?
cis314 said:
What is the easiest method to root HTC one that is on 4.2.2?
Click to expand...
Click to collapse
Here's what you're looking for...it's your only option if you don't want to mail it anywhere:
http://forum.xda-developers.com/showthread.php?t=2473644
Sent from my HTC6500LVW using XDA Premium 4 mobile app
cis314 said:
What is the easiest method to root HTC one that is on 4.2.2?
Click to expand...
Click to collapse
I finally got my htc one rooted and flashed plenty of roms so far I had a lot of stupid issues with rooting but guys on here were very helpful even tho I had to ask questions over and over again to troubleshoot problems. Easiest way was to dl rumrunner and get s-off and bootlader loaded. Them just flash a recovery. My buggiest prob was getting all files on my comp into a separate folder and opening a cmd from that folder. Also remember to always run stuff on ur comp as an administrator!
how did you flash recovery? I am having such a hard time flashing recovery!
cis314 said:
how did you flash recovery? I am having such a hard time flashing recovery!
Click to expand...
Click to collapse
put recovery.img in adb folder
open cmd prompt
type fastboot flash recovery nameofrecvovery.img
andybones said:
put recovery.img in adb folder
open cmd prompt
type fastboot flash recovery nameofrecvovery.img
Click to expand...
Click to collapse
Easier to just type "fastboot flash recovery (drag recovery.img here)"
that way you can save the recovery on your desktop or wherever. I wish adb/fastboot could be ran from anywhere and not just the adb folder though.
exzacklyright said:
Easier to just type "fastboot flash recovery (drag recovery.img here)"
that way you can save the recovery on your desktop or wherever. I wish adb/fastboot could be ran from anywhere and not just the adb folder though.
Click to expand...
Click to collapse
if you set it up correctly it can be, I can put the .img in my C folder, open a cmd and run commands, but it would still need the adb file.
so put the recovery whereevere your adb.exe is..
you can even make a folder called apktool in c: (thats what I have, that has adb.exe, fastboot, smali, baksmali, etc)
andybones said:
if you set it up correctly it can be, I can put the .img in my C folder, open a cmd and run commands, but it would still need the adb file.
so put the recovery whereevere your adb.exe is..
you can even make a folder called apktool in c: (thats what I have, that has adb.exe, fastboot, smali, baksmali, etc)
Click to expand...
Click to collapse
Adding the path to the adb.exe (and fastboot.exe) directory, to the environment variables, allows you to run ADB and Fastboot from any directory.
In Windows, right+click "Computer", select "Properties", click on "Advanced System Settings". On the "Advanced" tab select "Environment Variables" . In the bottom window find the "Path" string and add the path to ADB directory to the end.
The Paths in the string are separated by a semi-colon, so for example, I've added the path to my platform-tools directory like such:
;c:\android-sdk\platform-tools
This can also be done in Linux and Mac OS X, environment variables are stored in a hidden text file in the home folder. You can also adde it by typing the the PATH command in a terminal. Just Google it. Only takes a minute and saves time by not having to "CD" to your ADB directory every time.
EDIT: This Tut. has nice screen shots
http://forum.xda-developers.com/showthread.php?t=757233

Trying to flash Oxygen OS to my Oneplus 3

Hi there,
I'm having trouble flashing the latest community build to my OP3 from my mac. I followed the instructions below from the lifehacker website to install ADB;
"Download this zip file containing the scripts.
Extract the zip and place the Android folder on your Desktop.
Open a new Terminal window.
Enter cd Desktop/Android
Enter ./ADB-Install-Mac.sh"
Following this, when entering the ./adb sideload command I get the message "-bash: ./adb: No such file or directory"
Everything I have downloaded has been saved onto my desktop, the command I am using is "./adb sideload Oneplus.crdownload".
Does anyone know how I can get round this? I flashed an update to my nexus 7 years ago from my old windows laptop and didn't come across this problem.
I've tried searching the from for a solution but couldn't find what I'm doing wrong.
Thank you in advance!
"./adb sideload Oneplus.crdownload" looks like an incomplete download file in Chrome. Are you sure the file download was successfully?
Hi there,
Thanks for the quick response, I cant be sure, however just downloaded it again and tried the command "./adb sideload OnePlus3Oxygen_16_OTA_007_all_1610310039_bc5bc09fd 9af4ceb".
I still get the same response.

errror: cannot load 'recovery.img'

I am in the bootloader trying to load twrp. Typed fastboot flash recovery recovery.img
command prompt says error: cannot load 'recovery.img'
myflyman said:
I am in the bootloader trying to load twrp. Typed fastboot flash recovery recovery.img
command prompt says error: cannot load 'recovery.img'
Click to expand...
Click to collapse
It means it can't find the recovery.img on your PC.
Did you check the file extension?
Windows has ist disabled by default, so you might have renamed it to recovery.img.img
I put the file on the desktop? Why can't it find it? Frustrating
I opened properties and it does have permissions granted. Not sure why it opens with Windows explorer? Can that be right?
I'm lost. Between the proper TWRP version not available and the path not visible, just gotta be an easier softer way.
Is the name of the file you have placed on the desktop recovery.img?
The correct format would be fastboot flash recovery <name of file>.img
Rename the file to recovery (do not add any .img extension) and use the same command fastboot flash recovery recovery.img
You can also flash the recovery by typing in this command:
"fastboot flash recovery" and then drag the twrp.img into your cmd prompt.
Another way is typing the first letter of your recovery name and then hit the 'tab' key in cmd prompt, it will automatically fill out the name for you (make sure you open cmd prompt inside where the recovery img is, thus hold shift in the folder, right click and click open terminal.)
Hope this helps, goodluck.
Wow, thanks a million friend. Having the best days of my life learning and growing in tech experience. It is possible with your and others guidance. Much appreciative. I'll give er a go here shortly and keep you posted.
myflymavn said:
Wow, thanks a million friend. Having the best days of my life learning and growing in tech experience. It is possible with your and others guidance. Much appreciative. I'll give er a go here shortly and keep you posted.
Click to expand...
Click to collapse
For the command in your first post to work, two things are essential. One is naming the .IMG file correctly, as the others have pointed out. The other is to place the .IMG file in the same folder as your adb tools.
If it is in a different folder, then the exact path to the .IMG file has to be typed in the adb command or you can drag the file to the command prompt window as someone pointed out.
Shift right click in the folder where the file is and open the command prompt from there. That way you don't need to mess with the path.
You must place if your image file is recovery.img you must place "fastboot flash recovery.img.img" and done
Same problem when using Windows 10, find that open command prompt pathway to find files is not fastboot that is some other like user/ best , copy your recovery Img to that folder and you can flash now.
Frexx4 said:
You must place if your image file is recovery.img you must place "fastboot flash recovery.img.img" and done
Click to expand...
Click to collapse
Don't confuse people with recovery.img.img and missing the partition to flash.
The correct usage is "fastboot flash recovery recovery.img" if your TWRP is named recovery.img
The clarifications on the prepage are clear.

Categories

Resources