install recovery using adb - LG Optimus 4X HD

Windows users should already have :
<<adb drivers>>
{
"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"
}
and
<<usb drivers>>
------------------------------------------------------------------------------------------------------------------------------------------------------
so u did root. u unlocked bootloader. u flashed a recovery and u installed a new rom. one day u start "digging" things to see if u can delete all the unwanted files so u make the phone faster and accidentally u deleted an important file and now it cant boot and it cant go into recovery. you are wondering what you CAN do now ! The answer is : Everything !
You can either go back to stock rom or
you can re-flash the recovery and then reinstall the rom.
1. Download the platform tools for your machine ( windows , linux or mac-os ). Here i have the adb fastboot for you.
2. Copy the recovery image to a location on your computer thats easier for you. The recovery image should have .img extension. If it is in a zip file, extract the .img file from it before proceeding.
3. Connect the phone to the pc and open cmd inside the fastboot folder you downloaded ( windows ). The others not on windows must use cd [path to their desktop,inside the platform tools where they see the adb file].
** If you are on a boot loop but the pc gets to recognize the phone even for a second then
4. Type
i) adb reboot-bootloader
ii) fastboot flash recovery recovery.img ( the command is: fastboot flash recovery [recovery image path/filename] )
5. When its done , reboot. Hold Volume down and power button to see if u get in recovery mode. :highfive:
Install the rom now the way you already know. There are many guides for that so i won't make a new.
cheers :good:
**Windows users can use this fastboot to unlock bootloader too. Lite fastboot commands guide provided here
**Linux users don't even need to download it , they can just directly download it from their terminal
I hope this thread helps a little those that dont know what to do when they delete an important file. *Pictures coming soon*

Related

[GUIDE] How to get back the stock kernel of Nexus 5 (LMY47I)

Hi everybody,
This is my second post at XDA and as an answer to my first post (List of Lollipop 5.1 custom kernels for the Nexus 5) This post guides you how get back the stock kernel (LMY47I).
Always remember: You flash at your own risk! This post is only for the Lollipop build LMY47I!
There are two ways to get the stock kernel back, the first with a custom recovery like TWRP or CWM and the second with FASTBOOT (UNLOCKED BOOTLOADER is imortant)
1. Download the STOCK-KERNEL.ZIP in the attachments and extract it (for example with WINRAR or 7-ZIP). Then you have two files. The only one you need is the Kernel.zip file! Copy it to your phone, then switch to the custom recovery navigate to the Kernel.zip file and flash it. Now reboot the phone. The stock kernel was succesfully flashed.
2. Download the STOCK-KERNEL.ZIP in the attachments and extract it (for example with WINRAR or 7-ZIP). Then you have two files. The only one you need is the boot.img! If you haven't downloaded the Android SDK yet download it now! Switch to folder where you installed the SDK and navigate to "platform-tools". Copy the boot.img file into it. Now reboot your phone into FASTBOOT (Bootloader) with POWER Button + VOLUME DOWN and connect your phone to your PC wait until the drivers are installed if you get an error install the latest Google drivers. Open CMD navigate to "platform-tools" and type: "fastboot flash boot boot.img". Reboot your Phone and disconnect the USB-Cable. The stock kernel was succesfully flashed.
Error
Can't flash the zip, says "Unable to execute"
falcon.prj said:
Can't flash the zip, says "Unable to execute"
Click to expand...
Click to collapse
What is the name of the .zip that you tried to flash?
some custom kernels also modify/replace other files in the system partition, so is flashing just boot.img enough to return to stock kernel then?
Wakamatsu said:
What is the name of the .zip that you tried to flash?
Click to expand...
Click to collapse
Kernel.zip
And the problem was with TWRP, sorry
and thanks!
iamelton said:
some custom kernels also modify/replace other files in the system partition, so is flashing just boot.img enough to return to stock kernel then?
Click to expand...
Click to collapse
Nope. So this thread is kinda pointless. You need to reflash your rom after hellscore, code blue, elementalx and probably franco (not used franco since kitkat)
From hells thread -
{
"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"
}
Sent via tapatalk from my cataclysm'd Lollipooop Nexus 5

[GUIDE] Installing/Flashing Treble ROMs

I am not responsible for people bricking their devices because they haven't made a backup.
Click to expand...
Click to collapse
{
"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"
}
Downloads
TWRP For P10 lite: HERE
ADB & Fastboot: HERE
The first step is to make a backup.
2. Download your Treble ROM, i recommend a GSI ROM.
In my case I'll be using Havoc-OS
Download: https://forum.xda-developers.com/project-treble/trebleenabled-device-development/rom-havoc-os-8-1-t3819050
3. Go into TWRP and do a FACTORY RESET and then reboot into fastboot.
4. The only thing you need to do now is flash the ROM, so get your downloaded ROM & extract the .img file from it (if there is no .img file and you see other files, flash via twrp).
On your PC open the fastboot command prompt and type
fastboot -u flash system <YourImageFileHere>
Click to expand...
Click to collapse
After just type : "fastboot reboot" and wait until your phone boots into the system. You may need to flash google apps afterwards.
It is normal for the phone to reboot a couple times so be patient.
Congratz, your phone is not running a treble ROM with your stock ROM's vendor.
Click to expand...
Click to collapse
Video:
I just need backup Boot, System and data if i want go back to stock?
Bad idea to factory reset with TWRP, it doesn't do it clean enough.
You could get in serious problems by doing it, such as random apps crashing, sd unmounting and worse.
Safer option is to factory reset and wipe cache with stock recovery after every system flash.
I'm telling this from my own experience, I don't want people to mess up like I did :highfive:
Ret-Zero said:
I just need backup Boot, System and data if i want go back to stock?
Click to expand...
Click to collapse
Yes that should be enough, vendor stays the same anyway.. I recommend flashing roms designed for kirins cpus btw because there is a higher chance it will work

How to block bootloader on xt1799-2

I will try to describe exactly what I did. I warn you that if you want to repeat this, then do everything at your own risk!
Original message
1. The cleanest installation possible​
We do a COMPLETE cleanup and format the DATA in TWRP not lower than version 3.4... then reboot into bootloader and connect to the PC with a good cable. Run Fastboot on the PC in the command line in turn enter the following commands:
fastboot devices
fastboot erase all
fastboot reboot bootloader
2. Install motoXT1799-2_GLOBAL_2021.02.20_oreo.zip​
Use the firmware from here: motoXT1799-2_GLOBAL_2021.02.20_oreo
3. Install Magisk​
The latest version of Magic-v22.0.apk must be installed and Magisk-v22.0.zip
4. Go to the developer menu​
In the developer menu, we give permissions to unlock the OS bootloader, as well as give permission to debug via USB.
5. Run adb Fastboot on the command line​
The phone must be connected to the PC via USB. We enter the command adb devices on the smartphone, a dialog box should appear to allow debugging this device or something like that, respectively, we give permission.
Next, we reboot into the bootloader with the command adb reboot bootloader
6. Blocking​
Previously, we copy the stock recovery.img to the folder with adb Fastboot
Enter the commands:
fastboot flash recovery recovery.img
fastbo fastboot flashing lock
We reboot into the system.
7. Delete Magisk as unnecessary​
To do this, go to the program select delete see two items select first "restore partitions or something like that" then delete.
8. Do a factory reset​
If everything is done correctly, we get a device with Oreo Android 8.1.0 as if it came out of the factory.
{
"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"
}

How To Guide Root X7 Max(RMX 3031) on Rui 2.0 and 3.0

Prerequisites:
Bootloader unlocked (Unlock Guide, Video Tutorial)
Magisk Manager
ADB and Fastboot tools (Download, Setup Guide)
Steps:
For Rui 2.0
Goto TWRP (Download link and Install Guide) or any other custom recovery (ofox)
Rename Magisk-v25.2.apk to Magisk-v25.2.zip
Flash Magisk-v25.2.zip and reboot
For Rui 3.0
Get boot.img and vbmeta.img from export firmware (Download, Convert to SP tool guide)
Use magisk to patch the boot image:
{
"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"
}
Connect the device to the PC via USB Cable.
Now transfer the patched boot file(magisk_patched.img) and vbmeta.img from your device to the platform-tools folder on your PC.
Inside the same folder, right-click on an empty area while pressing the ‘Shift’ key.
Select the option ‘Open PowerShell window here.
Or you could also head over to the platform-tools folder on your PC, type in CMD in the address bar, and hit Enter. This will launch the Command Prompt.
Type in the below code to make sure the device is successfully connected (an alpha-numeric code suggests successful connection):
Code:
adb devices
Now type in the below code to boot your device to fastboot/bootloader mode:
Code:
adb reboot bootloader
Next, type the below code to flash the patched boot image file:
CSS:
fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img
fastboot flash boot magisk_patched.img
fastboot reboot
Credits:
Thanks to @ManshuTyagi for TWRP and @topjohnwu for Magisk
PS: I have tested this on only RMX 3031, and it may work on GT neo(CN) (RMX 3357) without any edits. If it works for you, please let me know, will update the post accordingly.
and how to update RUI 3 afterwards without a full wipe?
good day, any guide on how to obtain the Boot.img and vbmeta.img file

Question Failed rooting Android 13, unable to flash-all factory image, error in screen shot.

Hello all,
I recently got my motherboard replaced after the pixel 5a died. The problem was covered under the extended warranty. Phone works just fine when I received it back. I tried rooting it using magisk to patch the boot.img file. After fastboot flash boot file.img, my phone would say device is corrupt and unable to start.
I downloaded the factory image from google. Tried using flash-all to completely restart the process. Used latest platform-tools (downloaded today). Bootloader is unlocked. I keep getting this error during the flash-all process and my phone is unable to boot. I'm still able to access fastboot. Where am I going wrong?
{
"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"
}
Here is larger screen shot of the entire flash-all process.
The issue is a known bug with latest SDK platform tools. Download and install platform-tools ver 33.x and you'll be fine.
Cheers!
flash stock rom via chrome browser , then patch boot.img and flash again to root , i am in lastest version a13 and root work fine
Typhus_ said:
The issue is a known bug with latest SDK platform tools. Download and install platform-tools ver 33.x and you'll be fine.
Cheers!
Click to expand...
Click to collapse
This is the fix, download platform-tools 34.0.0
Typhus_ said:
The issue is a known bug with latest SDK platform tools. Download and install platform-tools ver 33.x and you'll be fine.
Cheers!
Click to expand...
Click to collapse
This was my problem. I used 33 and it worked fine, thanks. Anyone know when it'll get fixed for 34?
when flash patched boot.img and is corrupt!!! Than Patch the recovery.img and flash it to Recovery Partition, you must start the device with Buttons-Combo in Recovery-Mode to start the System with Root!!! think you have no Recovery-Mode on this Method, you must Flash recovery.img new to use Recovery-Mode!!!

Categories

Resources