[Guide] How to do OTA on stock rooted Mi A1 - Xiaomi Mi A1 Guides, News, & Discussion

Scenario
You are rooted with systemless SuperSU.
You have untouched /system partition.
You have unlocked bootloader.
What you'd need
fastboot and adb from platform-tools.
tissot_images_xxx.tgz - Stock ROM for your current version (before the OTA).
cfar_xiaomi_mi-a1_tissot_xxx.zip - CF-Auto-Root package for your current version (before the OTA).
SR5-SuperSU-v2.82-SR5-xxx.zip or a later version
How to install OTA
Uninstall FlashFire if it's installed. It hijacks OTA installation but fails as the device is not (yet?) supported.
Start the OTA installation. (Settings > About phone > System update)
Restart the device. You'd get into a boot loop because of the patched boot image.
Hold down the power + volume down buttons to get into Fastboot mode.
Code:
fastboot getvar all
to find out the current active slot.
Extract boot.img from tissot_images_xxx.tgz.
Code:
fastboot flash boot_x boot.img
where x is the current active slot.
Code:
fastboot reboot
You'd see the update engine screen for a bit, and then it'd reboot again.
Once you're back in Android, you should see that you're on the latest version. (Settings > About phone)
How to root for both slots
Wait for "Finishing Android update..." to complete (if it's still not done yet).
Code:
adb reboot-bootloader
to get into Fastboot mode.
Code:
fastboot getvar all
to find out the current active slot.
Code:
fastboot set_active x
where x is the inactive slot.
Extract boot.img from cfar_xiaomi_mi-a1_tissot_xxx.zip.
Code:
fastboot boot boot.img
You'd see nothing happen for a while. Just be patient. It'd reboot automatically and it'd take a while.
WARNING: Do not flash this image. If you accidentally flash it, you can reflash the stock boot.img.
Click to expand...
Click to collapse
Once you're back in Android, you should see that you're on the old version. (Settings > About phone)
Install FlashFire.
Code:
adb push SR5-SuperSU-v2.82-SR5-xxx.zip /sdcard/
(adjust the filename accordingly).
Code:
adb shell "su -c 'echo BINDSBIN=true > /data/.supersu'"
to install SuperSU in SBIN mode. Recommended.
Run FlashFire. Add "Flash ZIP or OTA" action and select the SuperSU zip. Select Slot A.
Add "Flash ZIP or OTA" action and select the SuperSU zip. Select Slot B.
Wait for "Finishing Android update..." to complete (if it's still not done yet).
Hit the flash button. Wait while FlashFire does its job. Be patient. It might reboot a few times. Do not interrupt the process.
Code:
adb reboot-bootloader
to get into Fastboot mode.
Code:
fastboot getvar all
to find out the current active slot.
Code:
fastboot set_active x
where x is the inactive slot.
Code:
fastboot reboot
and you're done.
If you want to read this in Markdown: https://gist.github.com/teohhanhui/98810ee282292157e8290e7e3ed87537
References / Credits
Guide on how to root mi A1 all future updates
Root new OTA updates [September Update]

Related

Need help preparing Xoom for official updates

Hey folks,
I´ve ran my MZ601 xoom on EOS builds over the last 1,5 years.
Obviously its unlocked and rooted. Currently its running CWM Recovery 4.0.0.4
Now I want to go back to stock to install the latest official updates to get the updated drivers for the UMTS radio/modem module.
After that I want to unlock and get root again to use any of the lastest custom Roms again.
Switching to a touch based recovery would be nice too.
I surfed around a bit and I´m rather confused which steps I need to perform in order to do this.
I guess I need to remove root and lock the bootloader again before I can install official updates ?
Could someone please toss me in the right direction? Maybe some step-by step list?
You'll presumably want Build H.6.1-38-1 for Retail Europe from here.
Returning to stock:
Extract the files from the link above to your adb/fastboot directory if you have one. If you don't have one I've uploaded them for you here.
Connect your Xoom to your PC then open command prompt from your adb folder. (Hold shift > right click on adb-fastboot folder > click Open Command Window Here)
Type adb devices and hit enter, if no devices are listed then ensure USB debugging is switched on in Settings > Development > and tick USB Debugging, then try again.
If it still doesn't appear then download Motorola USB drivers here and try again.
If fine then run:
adb reboot bootloader​Then run the following to flash the stock image:
fastboot flash boot boot.img
fastboot flash system system.img
fastboot flash recovery recovery.img
fastboot flash userdata userdata.img
fastboot erase cache
fastboot oem lock​
Flashing userdata.img is going to remove all your files so back everything up first.
This should unroot your Xoom anyway, not entirely sure if the lock is required to receive updates, but it's simple to unlock again.
Once booted and through initial setup you should receive several over the air updates. (I believe the stock image is Android 3.2)
Unlock:
Connect your Xoom again and open command window in the adb-fastboot folder as before.
Run:
adb reboot bootloader
fastboot oem unlock
fastboot reboot​You'll now be unlocked.
Install Touch Recovery and Root:
Next download ClockworkMod Touch recovery from here, rename it to just recovery.img for simplicity, and copy the image to the adb-fasboot folder.
Download Xoom Universal Root from here.
Copy that file to your sdcard.
Then run:
adb reboot bootloader
fastboot flash recovery recovery.img​(assuming you renamed it)
Once verified, reboot by holding Volume up and Power. (Keep connected to PC and keep command prompt open)
Important: When you see the Motorola logo wait about 3 seconds and hit volume down. You should see 'Android Recovery' in the top left corner, now press volume up to enter recovery.
From recovery go, Install zip from sdcard > choose zip > and select Xoom-Universal-Root.zip
Important: After the root flashes do not reboot.
Run:
adb remount
adb shell mv /system/recovery-from-boot.p /system/recovery-from-boot.p.old
adb shell mv /system/etc/install-recovery.sh /system/etc/install-recovery.sh.old​Then select reboot in ClockworkMod recovery and boot as normal.
If you are unable to use adb in recovery, then you can enable this through Windows by doing the following:
Whilst in recovery and connected to your PC, open Device Manager, find your Xoom, usually under 'Other devices'.
Then right click on your Xoom > Update driver software... > Browse my computer for driver software > Let me pick from a list of device drivers on my computer > Pick your Xoom (either one if there's two shown)
Windows should confirm the driver installed then adb should work in recovery.
Finally, run:
adb reboot recovery​If ClockworkMod touch recovery is still there then all is good!
Hopefully I've made sense! Any questions, just ask.
Repeat of downloads:
Download Motorola USB Drivers (Device Manager) here.
Download ClockworkMod Touch recovery here.
Download Xoom Universal Root here.
Wow, what a detailed guide
Thank you sir
No problem!
Let me know how it goes, hopefully shouldn't have any problems.
Resetting worked great :good:
Right now I´m in an OTA marathon
all that unlock, root and recovery stuff sounds familiar so I don´t expect any problems.
Thanks so far :good:
alecbond said:
From recovery go, Install zip from sdcard > choose zip > and select Xoom-Universal-Root.zip
Important: After the root flashes do not reboot.
Run:
adb remount
adb shell mv /system/recovery-from-boot.p /system/recovery-from-boot.p.old
adb shell mv /system/etc/install-recovery.sh /system/etc/install-recovery.sh.old​Then select reboot in ClockworkMod recovery and boot as normal.
Finally, run:
adb reboot recovery​If ClockworkMod touch recovery is still there then all is good!
Click to expand...
Click to collapse
Ok, so this is not working
after I flash touch recovery and do thta reboot thing I can enter touch recovery, thats fine.
Flashing universal root, fine.
THEN,
adb remount
adb shell mv /system/recovery-from-boot.p /system/recovery-from-boot.p.old
adb shell mv /system/etc/install-recovery.sh /system/etc/install-recovery.sh.old
gives me error since in recovery mode there ist no adb connection
Whatever when I choose to reboot the system, recovery warns me that it will get overwritten by boot and ask me to disable this.
Shall I do this?
EDIT: Nevermind, I decided to be a little brave and just confirmed that message.
Now touch clockwork seems to be persistent and I´m a happy Xoomer again
Sorry, I had meant to reply during my lunch break.
Edit: Realised the time on the second of your posts, so wouldn't have been much help on my lunch anyway
Well I believe I just learned something new!
Either that or I'd forgotten it asked.
I assume it disables the action rather than deletes those files.
My method was just so you can use the reverse rename in future to re-enable the overwrite on boot.
In future, not that you'll necessarily ever need this information, you can enable adb in recovery through windows by doing the following
When in recovery and connected to your PC, open Device Manager, find your phone, usually under 'Other Devices'.
Then right click > Update driver > Browse my computer > Let me pick from list > Pick your phone (either one if there's two shown)
Should confirm driver installed then adb should work.
I didn't include the above previously as I couldn't remember having to do it personally.
Glad to hear all is well though!
alecbond said:
You'll presumably want Build H.6.1-38-1 for Retail Europe from here.
Returning to stock:
Extract the files from the link above to your adb/fastboot directory if you have one. If you don't have one I've uploaded them for you here.
Connect your Xoom to your PC then open command prompt from your adb folder. (Hold shift > right click on adb-fastboot folder > click Open Command Window Here)
Type adb devices and hit enter, if no devices are listed then ensure USB debugging is switched on in Settings > Development > and tick USB Debugging, then try again.
If it still doesn't appear then download Motorola USB drivers here and try again.
If fine then run:
adb reboot bootloader​Then run the following to flash the stock image:
fastboot flash boot boot.img
fastboot flash system system.img
fastboot flash recovery recovery.img
fastboot flash userdata userdata.img
fastboot erase cache
fastboot oem lock​
Flashing userdata.img is going to remove all your files so back everything up first.
This should unroot your Xoom anyway, not entirely sure if the lock is required to receive updates, but it's simple to unlock again.
Once booted and through initial setup you should receive several over the air updates. (I believe the stock image is Android 3.2)
Unlock:
Connect your Xoom again and open command window in the adb-fastboot folder as before.
Run:
adb reboot bootloader
fastboot oem unlock
fastboot reboot​You'll now be unlocked.
Install Touch Recovery and Root:
Next download ClockworkMod Touch recovery from here, rename it to just recovery.img for simplicity, and copy the image to the adb-fasboot folder.
Download Xoom Universal Root from here.
Copy that file to your sdcard.
Then run:
adb reboot bootloader
fastboot flash recovery recovery.img​(assuming you renamed it)
Once verified, reboot by holding Volume up and Power. (Keep connected to PC and keep command prompt open)
Important: When you see the Motorola logo wait about 3 seconds and hit volume down. You should see 'Android Recovery' in the top left corner, now press volume up to enter recovery.
From recovery go, Install zip from sdcard > choose zip > and select Xoom-Universal-Root.zip
Important: After the root flashes do not reboot.
Run:
adb remount
adb shell mv /system/recovery-from-boot.p /system/recovery-from-boot.p.old
adb shell mv /system/etc/install-recovery.sh /system/etc/install-recovery.sh.old​Then select reboot in ClockworkMod recovery and boot as normal.
Finally, run:
adb reboot recovery​If ClockworkMod touch recovery is still there then all is good!
Hopefully I've made sense! Any questions, just ask.
Repeat of downloads:
Download Motorola USB Drivers (Device Manager) here.
Download ClockworkMod Touch recovery here.
Download Xoom Universal Root here.
Click to expand...
Click to collapse
Hey, you did a great guide! Would you mind if I put that in the FAQ Thread?
"We think so supersonic and we make our bombs atomic" - Eagle Fly Free (Helloween)
Sent from my Nexus 10 using Tapatalk HD
XxLordxX said:
Hey, you did a great guide! Would you mind if I put that in the FAQ Thread?
Click to expand...
Click to collapse
No problem, I'd be honored!

[GUIDE] Installing the lastest LineageOS 15.1 Official (and microg fork)

I managed to install it, it got really tricky. The thing is that the new Lineageos releases somehow fail the verification on twrp and the old lineageos recovery. I found out after hours of investigating that you need the *new* Lineageos recovery to flash the new lineageos. I know, it's pretty absurd.
I extracted the boot.img from lineage-15.1-20180724-nightly-tissot-signed.zip extracting the payload.bin from the zip and using this tool https://androidfilehost.com/?fid=818070582850510260.
You can download the boot.img I extracted myself here: https://drive.google.com/file/d/1QftMHTXrINAOfr3Pcaqyux9nHRnGTnKl/view?usp=sharing
Put the phone on fastboot mode, connect via usb and type:
Code:
fastboot boot boot.img
while pressing the volume-up button to enter the Lineageos recovery.
From there do a factory reset, wipe system, and now you can flash lineage-15.1-20180724-nightly-tissot-signed.zip.
To flash it, it gets tricky. First of all you can't flash from the sdcard because it shows up an error. So you go to update, and press install from ADB or something like that. Now you have the phone on adb sideload mode.
Download https://developer.android.com/studio/releases/platform-tools. Adb from XDA's "Minimal ADB and Fastboot" doesn't work for some reason.
Unzip the file, open a command prompt on that folder and type:
Code:
adb devices
It has to show up as something like this:
Code:
List of devices attached
* daemon not running; starting now at tcp:5037
* daemon started successfully
xxxxxxxxxxx sideload
Where xxxxxxx is the phone id.
Then you can proceed to flash. Just type:
Code:
adb sideload lineage-15.1-20180724-nightly-tissot-signed.zip
Wait until it completes, it seems to freeze at 50% or so but wait some minutes until the progress bar on the recovery finishes and reboot.
Now you should be booting lineageos and set up it as usual. I hope this guide helped, took me some hours to figure it all out.
To install su addon, download it from https://mirrorbits.lineageos.org/su/20180718/addonsu-15.1-arm64-signed.zip, place the zip in your internal storage, download this recovery https://basketbuild.com/filedl/devs...ewolf/Recovery/tissot/twrp-3.2.2-1-tissot.img (thx nicknitewolf) and boot it via fastboot:
Code:
fastboot boot twrp-3.2.2-1-tissot.img
From there flash the su addon as usual and enjoy. Probably this method works also for opengapps/mindthegapps, i didn't have time to test it.
Rather, just use Abhishek's recovery image and twrp (V3.2.3) installer zip and get the job done.
Once you've installed the official LineageOS 15.1: Can you then update your system from Settings -> System -> About phone -> LineageOS updates without needing to ever flash something from TWRP again?

October security patches for LEO-DLXX

I've captured the ota file for the october security patch on my LEO-DLXX. Instructions for install follow.
0. Unlock Bootloader
1. Download https://drive.google.com/file/d/1TwtOBmz-01a2EjLFdFnbGi8pqOGEeOCa/view (not my file) and https://mega.nz/#!Cu5giA6A!BoflaUUy2DnhYFa1hO9_l-G83DYGCFSq6mwiYgenxDc and oreo-recovery.img from https://forum.xda-developers.com/watch-2/development/recovery-unofficial-twrp-3-1-0-0-touch-t3631364
2. Extract the SawShark.rar file into a new folder. Delete the two scripts as they do some weird stuff. Extract the sawshark.zip file into the same folder, and you will now have 3 .img files. Run the following commands to flash them:
Code:
fastboot flash boot boot.img
fastboot flash recovery oreo-recovery.img # TWRP
fastboot flash system system.img
Don't worry if you see something about "sparse header magic invalid number" or similar, flashing will continue anyway. When the flashing completes, reboot the device into recovery with the power button and the instructions on screen. Note that the display says "short press to select, long press to go to next item" however, its the other way round. Tap the power button until is shows reboot-recovery, then long-press to select.
3. TWRP will load. Make sure ADB is working and run
Code:
adb push update.zip /data/ota_package
adb reboot bootloader
fastboot flash recovery recovery.img # Stock Recovery
and reboot the device into recovery again.
4. The update should install. If it doesnt, probably you need /cache/recovery files there, but i dont have them any more.

[Guide] How to root GloDroid 12 on the PinePhone64

This should work on any version of GloDroid for the PinePhone but I've only tested it on 12.
You'll need:
Magisk 24.1
GloDroid 12
adb
fastboot
Steps:
1. adb root
2. adb shell
3. Backup boot.img:
dd if=/dev/block/mmcblk2p5 of=/sdcard/boot.img
4. Backup recovery_boot.img
dd if=/dev/block/mmcblk2p3 of=/sdcard/recovery_boot.img
5. Install Magisk 24.1
6. Patch both files in Magisk
7. Transfer both files onto computer
8. Boot into bootloader:
adb reboot bootloader
9. Flash recovery_boot:
fastboot flash recovery_boot mrecovery_boot.img
10. Flash boot.img:
fastboot flash boot mboot.img
11. Reboot phone:
fastboot reboot
Enjoy!
I tried to install to my pinephone64 going to try your link this time...
*edit*
I flashed it with a phone instead of a computer, put up a fight, but I got it. The build is two days old, Tiramisu.....
How can i put my PinePhone on adb state?

General P11 plus 616f installation rom gsi + root

Start by downloading the official stock rom. If you had a problem with the installation or just want to go back to the original usage
Flash SP Tools
- download the latest version of Android sdk platform-tools
- Put in the platform-tools folder your boot.img and vbmeta.img that you have copied from your previously downloaded official rom.
- Then download the generic system image you want to install, put it in the platform-tools folder and rename it GSI.img
- Put your smartphone in developer mode, in the settings press 7 times on the build number
- In the menu Options for developers that appeared, you must enable OEM unlocking, enable USB debugging
- Connect the smartphone to the computer, in Configuration usb choose Connection sharing via usb
accept the requested authorization on your smartphone,
- In the platform-tools folder enter the command
adb reboot bootloader
fastboot flashing unlock Press VOL+ to confirm
fastboot flashing unlock_critical Press VOL+ to confirm
fastboot --disable-verification flash boot boot.img
fastboot --disable-verify flash vbmeta vbmeta.img
fastboot -w
fastboot reboot fastboot The tel switch to FastbootD mode and wait for a moment before entering the following command
fastboot delete system
fastboot delete-logical-partition product_a
fastboot --disable-verity --disable-verification system flash Gsi.img Wait for a moment
fastboot -w
fastboot bootloader
fastboot delete user data
fastboot reboot
Lenovo then logo rom gsi and install
evolutionx rom
Releases · ponces/treble_build_evo
Script and patches for building PHH-Treble Evolution X - ponces/treble_build_evo
github.com
rom lenovo and flashtool 616f
https://mirrors.lolinet.com/firmware/lenovo/Tab_P11_Plus/TB-J616F/TB-J616F_S240155_230210_ROW_SVC.zip
https://mirrors.lolinet.com/firmware/lenovo/Tab_P11_Plus/flashtool/MTK_Flash_Tool_v5.2104_P522.zip
Last tested rom that works
https://private.projectelixiros.com/thirteen/gsi/ProjectElixir_3.6_gsi-13.0-20230223-1108-OFFICIAL.img.xz
Root lenovo 616f
Install the Magisk app to your phone and install
In the Options menu, enable both the Preserve Force Encryption and Recovery Mode options.
Choose Select and Patch a file.
Browse to the extracted boot.img file and select it.
Magisk will now load the boot.img file and start patching.
Then the patched patched boot image file will be saved as magisk_patched.img in Internal Storage Downloads.
The file will be named as magisk_patched.img.
Transfer the magisk_patched.img file to the platform-tools folder.In the platform-tools folder enter the command
adb reboot bootloader
fastboot flash boot magisk_patched.img
fastboot reboot
successfully rooted
Magisk 25.2
https://github.com/topjohnwu/Magisk/releases/download/v25.2/Magisk-v25.2.apk
Can you make a video to review that rom on p11
It has only one flaw,
The PC does not recognize the tablet, it can only be charged, files cannot be transferred and adb does not work either.

Categories

Resources