Flash files via Adb? - LG G6 Questions and Answers

Well. My issue is that I already unlocked my Oreo US997 bootloader. The thing is that everytime I try to install TWRP it does noting but erasing my data. What I want to know is if there is a way to flash files or .zip roms via adb. I really want to try custom Roms but I can't without recovery. Any idea about it?

Related

[Q] Need help flashing clockwork recovery!

hi there, so my question is really simple.
I know how to flash a recovery .img via terminal (on my mac), but just can't seem to be able to permanently flash the .zip downloaded via ROM Manager. I reboot my phone in recovery, apply update from sdcard, new recovery replaces older one just for the time being because the next time I reboot my phone in recovery, the new recovery is just gone I am stuck with the older one.... the only way I have been able to update my recovery so far is by flashing it via terminal, I mean the update.zip must be there for a reason.... if I could just flash it without having to use the terminal, it'd be brilliant
So anyone knows how to permanently flash the .zip downloaded via ROM Manager without logging on to a terminal on a computer?
.Zips from ROM Manager are supposed to be 'temporary' ones. Only IMG files can be flashed permanently.
Have a look at the following thread. Should help you out!
http://forum.xda-developers.com/showthread.php?t=1245018
Thanks
So I guess I am just gonna have to download and flash the .img file every time I want to permanently flash a recovery image.
Yes, but I personally don't think that Recoveries is one thing that needs to be updated on a very frequent basis. (I am still on 3.2.0.0)
I agree, not something I'd upgrade on a regular basis. I only updated in order to get rid of the off-mode charging bug which I had in my old recovery and had been annoying me for months! Flashed with Unrevoked, now everything's working perfectly.
thanks for this information

[Q] Going to be modding a RAZR M in a few hours...

Was wondering if there was any sort of process I should be aware of or anything like that.
From what I understand, I have to have the phone rooted, then run Motopocalypse, and then from there I'll have an unlocked bootloader. From there, I install a custom recovery (going for TWRP) via fastboot, and then choose a custom ROM/Kernel and Gapps to flash.
Now at that point, I'm wondering if I can use a flash drive over USB OTG to flash the files, or if I have to adb push them over.
From there, I simply setup the phone and everything should be fine?
I have experience with custom ROMs on Nexus devices and a few Samsung devices; never really messed with any Droid devices though.
espionage724 said:
Was wondering if there was any sort of process I should be aware of or anything like that.
From what I understand, I have to have the phone rooted, then run Motopocalypse, and then from there I'll have an unlocked bootloader. From there, I install a custom recovery (going for TWRP) via fastboot, and then choose a custom ROM/Kernel and Gapps to flash.
Now at that point, I'm wondering if I can use a flash drive over USB OTG to flash the files, or if I have to adb push them over.
Click to expand...
Click to collapse
Well, the easiest method is to have the files you want to flash on a MicroSD care and have that in the phone. Personally, I copy the files over to the phone before wiping anything, and then install from the MicroSD card. TWRP will see it as 'external1'.
Coronado is dead said:
Well, the easiest method is to have the files you want to flash on a MicroSD care and have that in the phone. Personally, I copy the files over to the phone before wiping anything, and then install from the MicroSD card. TWRP will see it as 'external1'.
Click to expand...
Click to collapse
Ah, yeah totally forgot about just being able to do that

I'm a nervous noob.

This is a pretty specific question and i'm not sure this is the correct place to ask this but i recently installed the stock rom (Via Zip) on this thread: http://forum.xda-developers.com/showthread.php?t=2527806 . I flashed just the rom NOT including the bootloader (Because i don't know what it does) and the .97 radio because there seems to be some issues with it. Now, everything is working perfectly as it did before. What i'm wondering is after today's random new 4.4 factory image and ota update from Google (I think its krt16s); i know they are probably going to compile a flashable zip, and if they do what exactly do i need to do?
I'm extremely weary when i do these kind of things, the last time i flashed any sort of rom was on my OG RAZR. Would i have to install that new bootloader? (Also what exactly does it do) And would i have to wipe?
I can make the radio judgement on my own but i'm just not entirely sure.
If anyone could answer my questions that would be wonderful, i'm also sorry for posting this here, i'm not allowed to post in that thread because i'm "new" to the site.
Thanks!
you dont have to sorry as you are in the right section for asking questions.
You can either wait for a day or two for someone to post a flashable zip file. If someone do post it; all you have to do is copy it to your phone. Reboot to recovery mode; make sure you have cwm recovery installed. From there choose "install zip" > install zip from sdcard, choose the flashable zip. Once it finishes installing, clear cache partition and reboot. You will not lose anything in the phone.
If you want to install the new krt16s stock update. First, copy all of your files (pictures/music/data etc...) to your computer. This will wipeout everything. Download the image file. Open it with winrar or 7zip. Extract all the files to a folder. Connect your phone to the computer and reboot it to bootloader. Run the "flash-all.bat" file from the extracted files. Wait for it to finish. It will update everything (kernel, bootloader and the new 4.4)
You should know what something is before flashing them wildly, that's the easiest way for people to brick their phone by flashing something incompatible with their devices. Bootloader is the main program that boot first when you turn on to phone to make selftest and boot normally into the operating system kernel, with Nexus you can use it boot into recovery and flash images to partitions as well. It's very recommended to update it along with new Android version or you may run into issues. You should already know this since you had to access the bootloader screen to boot into the CWM recovery.
Stick with using CWM for now and flash the flashable zips. Just make a full backup of your device you can always restore it later. Just know that unless you flash radio separately (aka baseband), roms generally and should not come prepackaged with the baseband, so it is not affected when you flash a different rom, you have to upgrade it manually.
When you flash a new Android version, usually its recommended to do a factory reset in your recovery to avoid issues.
Installing factory image takes a few more steps and required using fastboot, but if you want to check the link in my sig. Also I recommend switching to TWRP recovery, but that's just me.
badboy47 said:
you dont have to sorry as you are in the right section for asking questions.
You can either wait for a day or two for someone to post a flashable zip file. If someone do post it; all you have to do is copy it to your phone. Reboot to recovery mode; make sure you have cwm recovery installed. From there choose "install zip" > install zip from sdcard, choose the flashable zip. Once it finishes installing, clear cache partition and reboot. You will not lose anything in the phone.
If you want to install the new krt16s stock update. First, copy all of your files (pictures/music/data etc...) to your computer. This will wipeout everything. Download the image file. Open it with winrar or 7zip. Extract all the files to a folder. Connect your phone to the computer and reboot it to bootloader. Run the "flash-all.bat" file from the extracted files. Wait for it to finish. It will update everything (kernel, bootloader and the new 4.4)
Click to expand...
Click to collapse
I see, me personally, I'm not very fond of using adb; I haven't used it at all prior to yesterday. I may try this out, but should someone post the new kernel, boot loader, 4.4 and radios would that be the same as flashing the factory image?
This probably seems like a really stupid question but I wouldn't be smart to try to download the ota directly from the phone (via check for updates) would it?
joshvader8 said:
I see, me personally, I'm not very fond of using adb; I haven't used it at all prior to yesterday. I may try this out, but should someone post the new kernel, boot loader, 4.4 and radios would that be the same as flashing the factory image?
This probably seems like a really stupid question but I wouldn't be smart to try to download the ota directly from the phone (via check for updates) would it?
Click to expand...
Click to collapse
You need to learn to use adb and fastboot if you want to be able to do advance things with the phones, or just avoid flashing too much, because once you run into trouble (especially due to using toolkits), you will not know how to recover your device.
If you want your device to be stock and able to receive OTA updates, in addition you also need your stock rom to be an "odexed" version, some roms are "deodexed" which will not receive OTA. You also need to have stock recovery, which CWM isn't.
eksasol said:
You need to learn to use adb and fastboot if you want to be able to do advance things with the phones, or just avoid flashing too much, because once you run into trouble (especially due to using toolkits), you will not know how to recover your device.
If you want your device to be stock and able to receive OTA updates, in addition you also need your stock rom to be an "odexed" version, some roms are "deodexed" which will not receive OTA. You also need to have stock recovery, which CWM isn't.
Click to expand...
Click to collapse
Thank you! One more question, let's say I revert back to my nandroid back up. I backed my ROM up on Android 4.3 rooted and unlocked with CWM. If I flashed the 4.4 factory i image what exactly would happen? Would I boot into 4.4 absolutely stock? Or would I end up with 4.4 unlocked etc...?
Thank you for the help I really appreciate it. ☺
joshvader8 said:
Thank you! One more question, let's say I revert back to my nandroid back up. I backed my ROM up on Android 4.3 rooted and unlocked with CWM. If I flashed the 4.4 factory i image what exactly would happen? Would I boot into 4.4 absolutely stock? Or would I end up with 4.4 unlocked etc...?
Thank you for the help I really appreciate it. ☺
Click to expand...
Click to collapse
When you flash factory image (using fastboot method), it will wipe your entire device and all user data, and you will boot into stock. Except if you do it manually you can prevent datas from wiping, follow these steps and pay attention to the red texts.
Sometimes apps data from older version can cause issues with newer version though, so a clean install is always best.
But if you have custom recovery, you can flashable stock roms, such as this one by fireb33, it's essentially the same as stock. Get the "odexed" version which is required to get OTA updates. Some peolpe say they can get OTA with custom recovery, but I have never tried that. The safest bet is to use fastboot to restore to stock recovery. You could also use custom recovery to flash OTA update packages to update versions that way.
As for backing up, people tends to call the backup "nandroids". After you do backup, if you're doing something that required the device to be wiped, you need to copy the backup to your pc. The CWM nandroids are usually located in 'clockworkmod' folder, but if you don't see it, search in "/data/media". I do not use CWM so I don't know what it allows you to back up, but generally "boot" (which is the kernel), system, and data partitions. It will not restore everything to stock such as your radio (baseband) or recovery.
I highly recommend switching to TWRP recovery, it will make flashing a lot easier.

[Q] File recovery From Bootloop'ed Nexus 4

Hi,
I Need help .
I have nexus 4 with stock ROM and stock recovery.
Two days after OTA update to Lollipop, the phone got stuck on boot-loop.
The problem is that on the phone i have a very important voice recording of a cop that says he will lie in court.
The court time is coming and i need that recording!
Everywhere i looked, no one has an idea how to recover a boot-loop'ed phone.
The 2 options that people recommended are:
1. RE-Flash the ROM.
Maybe it wont delete the files.
2. Wipe everything and hope that the file is recoverable with one of the software's.
A. What do you recommend?
B. Did someone try any of the recovering software's with any luck of actually recovering?
Your bootloader is locked, correct?
ashyossi said:
Hi,
I Need help .
I have nexus 4 with stock ROM and stock recovery.
Two days after OTA update to Lollipop, the phone got stuck on boot-loop.
The problem is that on the phone i have a very important voice recording of a cop that says he will lie in court.
The court time is coming and i need that recording!
Everywhere i looked, no one has an idea how to recover a boot-loop'ed phone.
The 2 options that people recommended are:
1. RE-Flash the ROM.
Maybe it wont delete the files.
2. Wipe everything and hope that the file is recoverable with one of the software's.
A. What do you recommend?
B. Did someone try any of the recovering software's with any luck of actually recovering?
Click to expand...
Click to collapse
If your bootloader is unlocked you can try flashing TWRP recovery which has a built in file manager and mtp function to copy files to computer. You can also try to "dirty flash" another lollipop rom which will not wipe the data, but may not work.
Yeah, this is the only option, however, this can only happen if his bootloader is unlocked
lolcakes203 said:
Yeah, this is the only option, however, this can only happen if his bootloader is unlocked
Click to expand...
Click to collapse
unfortunately, the bootloader is locked.
what are the chances that "Dirty Flash" wont delete the files?
and what rom should i flash? the same build or maybe try to flash kitkat insted...?
ashyossi said:
unfortunately, the bootloader is locked.
what are the chances that "Dirty Flash" wont delete the files?
and what rom should i flash? the same build or maybe try to flash kitkat insted...?
Click to expand...
Click to collapse
Unfortunately, as far as I know you can't flash any Rom's while your bootloader is locked. You need either fastboot or a custom recovery to flash a custom ROM and both need an unlocked bootloader.
theminikiller said:
Unfortunately, as far as I know you can't flash any Rom's while your bootloader is locked. You need either fastboot or a custom recovery to flash a custom ROM and both need an unlocked bootloader.
Click to expand...
Click to collapse
and flushing the same STOCK rom that i got as OTA should work or does it only work with custom ROM's?
i've looked again.
seems that the bootloader is unlocked!
so, should i flash a TWRP recovery?
ashyossi said:
i've looked again.
seems that the bootloader is unlocked!
so, should i flash a TWRP recovery?
Click to expand...
Click to collapse
Yes, after you've flashed twrp you should be able to access your files from a computer if you're booted in recovery.
soooooo.....
i flashed the TWRP Recovery.
very easy. no errors.
and it shows as the storage is completely empty! as if someone in all this time wiped everything...
so now, what recovery software do you know/used/heard of?
ashyossi said:
soooooo.....
i flashed the TWRP Recovery.
very easy. no errors.
and it shows as the storage is completely empty! as if someone in all this time wiped everything...
so now, what recovery software do you know/used/heard of?
Click to expand...
Click to collapse
When the storage is completely empty, are you booted in recovery, the bootloader or just trying to boot normally? When you say it's empty, do you actually see the device on your computer? If so, is it completely empty with no folders or files or anything, or just stock stuff?
Can you check mount and make sure all the storage volumes are mounted? It's usually blank when they are all manually unmounted.

Is it OK to clean flash Factory Image in TWRP?

I want to make a clean Install of factory image (Android 8.0 Oct) on my Nexus 6P with TWRP.
Should wipe Dalvik, Data, System and Internal storage, then move the stock zip file (That I downloaded from google's web) from my computer to my phone and just install in TWRP? Will it work?
Device is unrooted, only has an open boot loader, I just want to make a clean install of Android 8.0
If you wipe your internal all your downloads and your factory image are gone.
Sure you can flash the unpacked *.img with twrp, but don't try to flash the bootloader or radio with twrp.
If you really want a clean start and wipe everything, then you should flash the factory image with fastboot. This will update your bootloader and radio too.
coremania said:
If you wipe your internal all your downloads and your factory image are gone.
Sure you can flash the unpacked *.img with twrp, but don't try to flash the bootloader or radio with twrp.
If you really want a clean start and wipe everything, then you should flash the factory image with fastboot. This will update your bootloader and radio too.
Click to expand...
Click to collapse
Hi coremania, I have a few questions towards this method.
1. If the stock image is stored in either external SD card OR USB OTG, even then will there be any problem installing the the stock rom back using TWRP?
2. If the boot loader is unlocked, should one has to re-lock it first before reinstalling the stock rom either thru' TWRP or thru' Fasboot commands?. and finally,
3. Is it not advisable to flash the stock rom from the full factory image using TWRP rather than Fastboot?
(As I think it is easier to flash thru TWRP than typing those ADB commands in Fastboot).
Thank you for your inputs.
AndroMani said:
Hi coremania, I have a few questions towards this method.
1. If the stock image is stored in either external SD card OR USB OTG, even then will there be any problem installing the the stock rom back using TWRP?
2. If the boot loader is unlocked, should one has to re-lock it first before reinstalling the stock rom either thru' TWRP or thru' Fasboot commands?. and finally,
3. Is it not advisable to flash the stock rom from the full factory image using TWRP rather than Fastboot?
(As I think it is easier to flash thru TWRP than typing those ADB commands in Fastboot).
Thank you for your inputs.
Click to expand...
Click to collapse
If you decide to flash and test some stuff the bootloader should be always unlocked. If anything will went wrong and your bootloader is locked you're mostly f***ed. Never relock your bootloader until you want to sell your device.
I mostly use flashfire to flash stock and custom roms, TWRP is ok too, but it's easier to keep root and TWRP with flashfire by flashing stock images. Do not flash bootloader and radio with flashfire, never ever !!! There are TWRP flashable zips for bootloader and radio here on XDA, you only should use these with TWRP, but the safe way for bootloader and radio is fastboot for sure. Fastboot is the safest way for flashing stock,
but not absolutely necessary, you have to decide this for yourself.
Edit: to your first question, I never flashed with USB otg on the n6p, but I think yes it should be fine.
I hope someone here can help answer this question. I also want to flash factory image version 8.1.0 on my nexus 6P. But somehow my phone is not recognized by any computers I tried to plug it in. When I plug in the usb cable to the phone, it doesn't pop up the usb notification to choose MTP for file transfer. Then I try with Developer tab in Settings to choose it manually (USB debugging is enable) but it still doesn't work. My laptop has been updated with android usb drivers and other stuffs. I have a second phone (Oneplus 1) and it's recognized by my laptop the moment I plug it in. Please suggest any solutions to fix this. Thanks everyone.
sinjok said:
I hope someone here can help answer this question. I also want to flash factory image version 8.1.0 on my nexus 6P. But somehow my phone is not recognized by any computers I tried to plug it in. When I plug in the usb cable to the phone, it doesn't pop up the usb notification to choose MTP for file transfer. Then I try with Developer tab in Settings to choose it manually (USB debugging is enable) but it still doesn't work. My laptop has been updated with android usb drivers and other stuffs. I have a second phone (Oneplus 1) and it's recognized by my laptop the moment I plug it in. Please suggest any solutions to fix this. Thanks everyone.
Click to expand...
Click to collapse
Check your cable, or try a different with different port.
In the Dev options you can reset the debugging options, i guess a reboot is necessary afterwards.
coremania said:
If you decide to flash and test some stuff the bootloader should be always unlocked. If anything will went wrong and your bootloader is locked you're mostly f***ed. Never relock your bootloader until you want to sell your device.
I mostly use flashfire to flash stock and custom roms, TWRP is ok too, but it's easier to keep root and TWRP with flashfire by flashing stock images. Do not flash bootloader and radio with flashfire, never ever !!! There are TWRP flashable zips for bootloader and radio here on XDA, you only should use these with TWRP, but the safe way for bootloader and radio is fastboot for sure. Fastboot is the safest way for flashing stock,
but not absolutely necessary, you have to decide this for yourself.
Edit: to your first question, I never flashed with USB otg on the n6p, but I think yes it should be fine.
Click to expand...
Click to collapse
Thank you for the clarification. So, far I have not faced a situation to flash my custom recovery either thru' TWRP or thru Fastboot. Instead, I am using my Nandroid backups taken from TWRP and using it to restore my system after I try a custom rom OR upgrade my system with the latest Magisk version for a systemless root. So far there are no issues. But, I wanted to be aware of the methods to go back to stock (without any user installed apps/data) if need be. I read in some forums that we need to re-lock the unlocked bootloader if we want to go back to stock rom using fastboot. Otherwise, the system will not be installed alright and might cause a bootloop.
That's why I wanted to clarify.
Thanks again for your inputs.
AndroMani said:
Thank you for the clarification. So, far I have not faced a situation to flash my custom recovery either thru' TWRP or thru Fastboot. Instead, I am using my Nandroid backups taken from TWRP and using it to restore my system after I try a custom rom OR upgrade my system with the latest Magisk version for a systemless root. So far there are no issues. But, I wanted to be aware of the methods to go back to stock (without any user installed apps/data) if need be. I read in some forums that we need to re-lock the unlocked bootloader if we want to go back to stock rom using fastboot. Otherwise, the system will not be installed alright and might cause a bootloop.
That's why I wanted to clarify.
Thanks again for your inputs.
Click to expand...
Click to collapse
You don't need to ever relock your bootloader. If you want to try stock and use TWRP try SuperXe 8.1. It's just flaahable stock with some extras you can opt out of your not intereseted.
AndroMani said:
Thank you for the clarification. So, far I have not faced a situation to flash my custom recovery either thru' TWRP or thru Fastboot. Instead, I am using my Nandroid backups taken from TWRP and using it to restore my system after I try a custom rom OR upgrade my system with the latest Magisk version for a systemless root. So far there are no issues. But, I wanted to be aware of the methods to go back to stock (without any user installed apps/data) if need be. I read in some forums that we need to re-lock the unlocked bootloader if we want to go back to stock rom using fastboot. Otherwise, the system will not be installed alright and might cause a bootloop.
That's why I wanted to clarify.
Thanks again for your inputs.
Click to expand...
Click to collapse
I can't confirm the relock and unlock method to go back to stock. Senseless to me.

Categories

Resources