Question Installing GSI on Moto G Stylus 5G (2021) - Moto G Stylus (2021)

In a moment of weakness, I finally allowed my G Stylus to update to Android 12, and my stability has been a nightmare since then. I have been reading through many guides here and elsewhere to getting a GSI installed.
So far, I have unlocked the bootloader and followed the instructions for installing TWRP using adb/fastboot for my device. When try to flash a GSI, the partitions in TWRP don't look like anything I've seen in guides. The options it shows me are:
-Boot
-Dtbo
-Persist
-Super (system system_ext product vendor)
-Install Recovery Ramdisk
I tried installing on Super, as I found a thread mentioning it should contain both vendor and system. However, when I flash the img for a gsi to it, it will only boot to bootoader. I can get it into TWRP recovery but the screen is entirely unresponsive, even attempting to power off prompt's a restart. I was able to use Moto's Rescue program to get it back in working order, but each time this happens I have to start over at square one.
I tried with a GSI for crDroid on my first attempt, and then LineageOS on a follow-up attempt, both I had the same issue.
I'm new to Android modding, so I could really use some guidance through getting this set up. I've extensively referenced guides on here and elsewhere, but I've struggled with parsing and figuring out what I need to do in this case. Currently my device has TWRP installed but I'll be doing nothing else until I know what the best way forward is. I'd be happy to provide additional info.
Edit: Just found the dedicated 5G section. Sorry about this.

I am not sure why people use TWRP and a GSI/crDroid /w LineageOS rom.
All you need to do is install the magisk module L Speed
Remember this phone has 2 boot partitions....1 is secured (even if you have the bootloader unlocked and your rooted) So if you trip the SafetyNet your going to have bootloading issues and boot loops

Not sure what the previous comment was about, what does safetynet have to do with anything? It fails the second you unlock the bootloader.
First, you'll want to make sure to have installed at least one OTA update so both your slots are occupied. You could also install copy-partitions from a custom recovery. Otherwise your phone might brick if it ever switches to slot b.
Download and extract the official firmware for your device that matches what is installed
lolinet mirrors - firmware, software, iso etc.
lolinet mirrors - powered by h5ai
mirrors.lolinet.com
And reflash your vbmeta partition(s) from fastboot to disable verity
Code:
fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img
fastboot --disable-verity --disable-verification flash vbmeta vbmeta_system.img
Then you need to reboot into fastbootd (you can also get into it from a custom recovery)
Code:
fastboot reboot fastboot
From there you can erase your system, install the GSI, wipe data, and reboot
Code:
fastboot erase system
fastboot flash system GSI_system.img
fastboot -w
fastboot reboot

Related

LineageOS 15.1 generic boot image

Has anybody tried this... If so does it work? https://www.xda-developers.com/lineageos-15-1-resurrection-remix-available-project-treble/
Feel free to give it a try!
Flash the system image from TWRP, reboot to recovery, then flash Gapps (if desired). Keep a backup factory system image handy if needed.
@Telperion I wish I could... Unfortunately I don't have the pixel 2. I am very much thinking about buying one though.
I'm sure it works, there's just not been much need to run a custom ROM. I'm on P DP1 and there's not yet a P GSI so I'd have to downgrade to 8.1 before flashing.
Telperion said:
Flash the system image from TWRP, reboot to recovery, then flash Gapps (if desired). Keep a backup factory system image handy if needed.
Click to expand...
Click to collapse
When I tried installing TWRP on my Pixel 2 a few days ago, I found the ui does not respond to screen touches.
It might be simpler to just use fastboot flash a GSI.
Note that to get a GSI to work on the Pixel 2, you also need to adjust the contents of the "vbmeta" partition, which can be done using "fastboot".
There are details about it here https://github.com/phhusson/treble_experimentations/wiki
Can confirm lineage, resurrectionremix and aosp gsi by phh all work, although the twrp bug jamuir mentions did occur for me. I got around this by just flashing the gsi through the bootloader and not twrp. If you want to flash some gapps after flashing system and vbmeta (needed for pixel2), just fastboot boot twrp.img instead of rebooting to recovery. Here are basic steps I followed:
clean flash phone or do a factory reset from twrp, then boot to bootloader
fastboot flash system system-arm64-ab.img
fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img #from factory image
#and if you want gapps
fastboot boot twrp.img
adb push opengapps.zip
flash your gapps
You'll get the "vendor mismatch" warning we've all come to know and love, as well as a "Hardware Overlay Picker stopped working" message on startup. Other than that, they all work.
I understand the premise of project treble, but I wonder what's the implication for custom rom developers. I'm probably mistaken, but it seems like they could just do a one-size-fits-all build for all devices now?
The twrp "not responding to touch" bug happens when you reboot into recovery straight from system using the advanced reboot menu. To prevent this, simply power off the device, and use the button combination to boot into twrp, voila, touch is now working.

Lineage OS 16/17/GSI Install Guide for LG G7 ULM

UPDATE: I kept finding bugs in josh1x's rom, so i installed the LOS17 GSI instead. Guide for that outline in reply #11
Figured this out and thought i'd write a simple tutorial that covers stock (i was at 20e) to lineage. You'll need the LG USB Drivers and adb/fastboot. There are a couple other things to download through out the tutorial and the unlock tutorial in step 1.
LG USB Drivers 4.2.0
ADB/Fastboot
LGUP with partition DL
Note: I was able to reach download mode and fastboot at any point in this process and even when it went wrong (kernel crashes, boot loops etc) while figuring out this tutorial. I found that i could just hold vol down or up in a bootloop with the usb connected to get to the mode i wanted.
Typical combos:
-Download mode: power off phone with usb disconnected. hold vol up and plug in cable
--NOTE: after wiping laf_a and boot_b, you must switch to slot b to access download mode (run command: fastboot -ab)
-fastboot: power off phone with usb disconnected, hold vol down and plug in cable. or adb reboot bootloader
--NOTE: after wiping laf_a and boot_b, you can only access fastboot from slot a by holding vol up on boot (for 20e/21d, on 11g vol down still works).
-Recovery: power off. hold power and vol down, when you see the white LG G7 logo temporarily release just the power button. Continue to hold power and vol down till you get to the option menu. Select Yes three times.
Guide:
1. Follow the universal unlock method here.
1.5. You need to zero out laf_a and boot_b before flashing 21d/20e to maintain fastboot access. Use adb to run the following commands
Code:
dd if=/dev/zero of=/dev/block/bootdevice/by-name/laf_a
dd if=/dev/zero of=/dev/block/bootdevice/by-name/boot_b
1.75. Enable usb debugging (should already be done). Open LGUP and connect to your phone. dont close it. If you open it after booting to DL mode it wont recognize it
2. 21d ULM firmware (here) must be flashed to use the latest twrp (20e works as well). The 11g twrp cannot install lineageos. I would imagine the EU firmware could be flashed as well, but I used ULM.
Code:
Boot into fastboot
fastboot -ab
Boot into download mode
Use the lg up linked in this post to flash 20e/21d without laf_a and boot_b with partition dl mode
3. Format userdata to decrpyt your file system so TWRP can access it. Then flash TWRP; boot_twrp-june.img can be found here. It's from Josh1x's post here. Note: this TWRP is non persistant.
Code:
Boot to bootloader
fastboot format userdata
fastboot flash boot_a boot_twrp-june.img
fastboot flash boot_b boot_twrp-june.img
Select restart in fastboot
Boot to recovery
4. Obtain the latest lineage build here. This is from Josh1x's post here. I attempted to flash gapps at this point and it failed, see the next steps.
Code:
Wipe everything
Transfer lineageos to your phone and install it
Restart normally
5. Gapps
Code:
Reboot to bootloader
fastboot flash boot_a boot_twrp-june.img
fastboot flash boot_b boot_twrp-june.img
Reboot to recovery
Transfer opengapps 9.0 to your phone and install.
Reboot to bootloader
6. We need to flash the stock lineage boot image (here) again now that we are done. The file was obtained with this method
Code:
fastboot flash boot_a boot.img
fastboot flash boot_b boot.img
Restart normally
if you have magisk, it would be magisk_patched_boot.img (here). this one was made from the above image with magisk on my phone.
Code:
fastboot flash boot_a magisk_patched_boot.img
fastboot flash boot_b magisk_patched_boot.img
Restart normally
Any time you want to flash something via twrp you will have to flash twrp via fastboot again (hence the non persistance), do your stuff in twrp, and then reflash the boot img (it will not boot if you dont do this or use josh1x's boot file). Just like steps 5-6 for gapps.
I am so glad to be off of stock, enjoy guys and girls!
Bugs (from my ULM phone)
-flash doesnt work in the camera. also probably why gcam crashes (gcam works on an EM phone somehow)
-brightness slider is calibrated incorrectly compared to stock. way too bright when set to 0%
NOTE: using ULM vendor fixed the flash and brightness, but gcam still doesnt work. This would make it the most functional rom for this phone at this point (vibrate does work).
Being that since day1 of g710pm/ulm could be boot unlocked, all ypu had to do is flash the eu firmware and go to lineage frlm there due to twrp incompatibility.
I have not tested it, but does being on lineage based off EU blobs, do you still get full LTE and/or volte.
If sprint users have switched to eu/lineage do you have full lte/ril compatibility.
Ah crap I didn't know that. I tried unlocking through LG when I got it a couple months ago and that didn't work of course. At that time the phone was working well (not going on a background apps killing spree), so I didn't bother. I couldn't find anything on here at the time for unlocking, but I obviously missed that.
LTE and wifi are working fine. Maybe that has something to do with me never flashing the EU rom to install lineage? Anyways, I couldn't find a volte toggle, but I'd assume it is working. I'm on Verizon and I believe they are killing their cdma network, so I'll find out.
Would this work on sprint phones? There is a warning at the end of the unlocking guide about sprint phones loosing fastboot when upgrading to ulm pie.
does it work for EM too ? because i dont have any boot for linage to make it boot after i flash gapps also magisk bootloops too
Emanel000000 said:
does it work for EM too ? because i dont have any boot for linage to make it boot after i flash gapps also magisk bootloops too
Click to expand...
Click to collapse
If it boots on the lineage bootimg before flashing twrp again for Gapps, then yes, if you get that bootimg and flash it again after using twrp it will boot again.
Though I'm not sure why josh1x's boot img wouldn't work for your phone. That's what he used on his EM model after all.
Have you tried the other twrps?
sirbow2 said:
If it boots on the lineage bootimg before flashing twrp again for Gapps, then yes, if you get that bootimg and flash it again after using twrp it will boot again.
Though I'm not sure why josh1x's boot img wouldn't work for your phone. That's what he used on his EM model after all.
Click to expand...
Click to collapse
nonono i meant like magisk from the stock rom it was bootlooping so that means those images works for EM model too ? (bootimg and magisk) ... also i saw a guy saying gcam works on the lineage and i installed it and didnt work it was crashing if i would install camera2 api module from magisk will it work or ?
Emanel000000 said:
nonono i meant like magisk from the stock rom it was bootlooping so that means those images works for EM model too ? (bootimg and magisk)
Click to expand...
Click to collapse
oh yea. i see, yes, they might as they are from the lineage rom.
Emanel000000 said:
... also i saw a guy saying gcam works on the lineage and i installed it and didnt work it was crashing if i would install camera2 api module from magisk will it work or ?
Click to expand...
Click to collapse
It wont let me install that camera2 module. Says incompatible device. I tried the gcam patch and that didnt work either.
Also, flash does not work properly on the included camera. It flashes for the focus, but then doesnt for actually taking the picture.
sirbow2 said:
oh yea. i see, yes, they might as they are from the lineage rom.
It wont let me install that camera2 module. Says incompatible device. I tried the gcam patch and that didnt work either.
Also, flash does not work properly on the included camera. It flashes for the focus, but then doesnt for actually taking the picture.
Click to expand...
Click to collapse
i installed everything and now gcam somehow works its perfect thank you so much i couldn't do it without your guide
Emanel000000 said:
nonono i meant like magisk from the stock rom it was bootlooping so that means those images works for EM model too ? (bootimg and magisk) ... also i saw a guy saying gcam works on the lineage and i installed it and didnt work it was crashing if i would install camera2 api module from magisk will it work or ?
Click to expand...
Click to collapse
Emanel000000 said:
i installed everything and now gcam somehow works its perfect thank you so much i couldn't do it without your guide
Click to expand...
Click to collapse
Sweet man, so just to clarify, you have a 710EM and what firmware did you flash before lineage? 21dulm or 21d EM?
I think im going to try Andy's lineage GSI.
Edit: Update 2: dont use the vendor in this post. I patched the ULM vendor, but vibrate and gcam are still an issue with a GSI. links here: https://forum.xda-developers.com/showpost.php?p=81563763&postcount=41 Also, using the ulm vendor on Josh1x's rom fixed everything but gcam.
I ended up moving to the GSI. I tried Deepflex's lineage 16 GSI but it was buggy and not working correctly. AndyYan's lineage 17 rom is working much better. Camera flash even works and the brightness slider is correct. List of all GSIs
If starting from stock, follow this new guide after doing the fastboot format userdata command in step 3 of the original guide in post #1
1. Flash vendor_gsi image (sourced from aosp trebble g7 EM this thread)
Code:
fastboot flash vendor_a vendor_gsi.img
fastboot flash vendor_b vendor_gsi.img
The above is the only file used from the source i linked above. I had to use a different twrp (the one from the existing thread wouldnt go past the lock screen after first reboot) so i tried the one below which worked, but only with the vbmeta img from josh1x's lineage 16 rom.
2. Flash vbmeta from josh1x's LOS16 rom (as mentioned before). File attached.
Code:
fastboot flash vbmeta_a vbmeta.img
fastboot flash vbmeta_b vbmeta.img
3. Flash latest twrp 3.3.1 (sourced from this thread). If you have magisk, here's the version i patched.
Code:
fastboot flash boot_a twrp_20b.img
fastboot flash boot_b twrp_20b.img
4. Flash GSI of whatever flavor you want. needs to be amd64 and for the A/B (bvN) partition type. I used this one
Code:
fastboot flash system_a system.img
fastboot flash system_b system.img
5. Reboot while wiping data (shouldnt wipe internal "sdcard", didnt for me). Should boot into lineage now.
Code:
fastboot -w reboot
6. For gapps, just reboot into recovery (none of that non persistant boot stuff), and flash the beta android 10 gapps from here
Note: I had to resize the system partition for the LOS17 rom for this as it didnt fill the entire filesystem when it was flashed. Go to the TWRP terminal and run mount to find the device path for /system and then run resize2fs /device/block/whatever.
sirbow2 said:
Sweet man, so just to clarify, you have a 710EM and what firmware did you flash before lineage? 21dulm or 21d EM?
I think im going to try Andy's lineage GSI.
Click to expand...
Click to collapse
i just had 20c for em it doesnt matter the version
sirbow2 said:
I ended up moving to the GSI. I tried Deepflex's lineage 16 GSI but it was buggy and not working correctly. AndyYan's lineage 17 rom is working much better. Camera flash even works and the brightness slider is correct. List of all GSIs
If starting from stock, follow this new guide after doing the fastboot format userdata command in step 3 of the original guide in post #1
1. Flash vendor_gsi image (sourced from aosp trebble g7 EM this thread)
Code:
fastboot flash vendor_a vendor_gsi.img
fastboot flash vendor_b vendor_gsi.img
The above is the only file used from the source i linked above. I had to use a different twrp (the one from the existing thread wouldnt go past the lock screen after first reboot) so i tried the one below which worked, but only with the vbmeta img from josh1x's lineage 16 rom.
2. Flash vbmeta from josh1x's LOS16 rom (as mentioned before). File attached.
Code:
fastboot flash vbmeta_a vbmeta.img
fastboot flash vbmeta_b vbmeta.img
3. Flash latest twrp 3.3.1 (sourced from this thread). If you have magisk, here's the version i patched.
Code:
fastboot flash boot_a twrp_20b.img
fastboot flash boot_b twrp_20b.img
4. Flash GSI of whatever flavor you want. needs to be amd64 and for the A/B (bvN) partition type. I used this one
Code:
fastboot flash system_a system.img
fastboot flash system_b system.img
5. Reboot while wiping data (shouldnt wipe internal "sdcard", didnt for me). Should boot into lineage now.
Code:
fastboot -w reboot
6. For gapps, just reboot into recovery (none of that non persistant boot stuff), and flash the beta android 10 gapps from here
Note: I had to resize the system partition for the LOS17 rom for this as it didnt fill the entire filesystem when it was flashed. Go to the TWRP terminal and run mount to find the device path for /system and then run resize2fs /device/block/whatever.
Click to expand...
Click to collapse
Thanks. You're process got my audio working on GSI. Not sure what incorrect image I was installing or what the issue was.
Just need to disable the LED notification and get vibration working.
EM devices vendor partition differ slightly compared to ULM devices, so camera issues and such will happen since you are using a slightly different blob.
There was a post of someone getting ULM to work with twrp so if someone can flash ULM and modify the vendor to load without encryption check and dmverity disabled then backup the vendor img.
Use that new vendor img will fix minor issues for ULM based devices on new gsi's.
loonycgb2 said:
EM devices vendor partition differ slightly compared to ULM devices, so camera issues and such will happen since you are using a slightly different blob.
There was a post of someone getting ULM to work with twrp so if someone can flash ULM and modify the vendor to load without encryption check and dmverity disabled then backup the vendor img.
Use that new vendor img will fix minor issues for ULM based devices on new gsi's.
Click to expand...
Click to collapse
thats what i was kind of thinking the issue was. thats over my head though.
sirbow2 said:
thats what i was kind of thinking the issue was. thats over my head though.
Click to expand...
Click to collapse
Ask someone from the thread of flashing ulm 20d to backup their vendor if they havent flashed to EM firmware or lineage yet
loonycgb2 said:
EM devices vendor partition differ slightly compared to ULM devices, so camera issues and such will happen since you are using a slightly different blob.
There was a post of someone getting ULM to work with twrp so if someone can flash ULM and modify the vendor to load without encryption check and dmverity disabled then backup the vendor img.
Use that new vendor img will fix minor issues for ULM based devices on new gsi's.
Click to expand...
Click to collapse
loonycgb2 said:
Ask someone from the thread of flashing ulm 20d to backup their vendor if they havent flashed to EM firmware or lineage yet
Click to expand...
Click to collapse
Oh, so all we have to do is get it to boot through twrp (or just a boot with root?) and then dd it? I could probably just flash the 21d ULM kdz again and do that?
sirbow2 said:
Oh, so all we have to do is get it to boot through twrp (or just a boot with root?) and then dd it? I could probably just flash the 21d ULM kdz again and do that?
Click to expand...
Click to collapse
Once you got twrp running with stock then do the normal thing of format userdat to decrypt it then flash the no dmverity zip mentioned in the thread or magisk then backup vendor via twrp or dd...
That will give you a usable vendor for lineage and such.
All josh1x or whoever did to the EM vendor was modify fstab to remove the force encrypt so that way decrypted roms would work.
sirbow2 said:
I ended up moving to the GSI. I tried Deepflex's lineage 16 GSI but it was buggy and not working correctly. AndyYan's lineage 17 rom is working much better. Camera flash even works and the brightness slider is correct. List of all GSIs
If starting from stock, follow this new guide after doing the fastboot format userdata command in step 3 of the original guide in post #1
1. Flash vendor_gsi image (sourced from aosp trebble g7 EM this thread)
Code:
fastboot flash vendor_a vendor_gsi.img
fastboot flash vendor_b vendor_gsi.img
The above is the only file used from the source i linked above. I had to use a different twrp (the one from the existing thread wouldnt go past the lock screen after first reboot) so i tried the one below which worked, but only with the vbmeta img from josh1x's lineage 16 rom.
2. Flash vbmeta from josh1x's LOS16 rom (as mentioned before). File attached.
Code:
fastboot flash vbmeta_a vbmeta.img
fastboot flash vbmeta_b vbmeta.img
3. Flash latest twrp 3.3.1 (sourced from this thread). If you have magisk, here's the version i patched.
Code:
fastboot flash boot_a twrp_20b.img
fastboot flash boot_b twrp_20b.img
4. Flash GSI of whatever flavor you want. needs to be amd64 and for the A/B (bvN) partition type. I used this one
Code:
fastboot flash system_a system.img
fastboot flash system_b system.img
5. Reboot while wiping data (shouldnt wipe internal "sdcard", didnt for me). Should boot into lineage now.
Code:
fastboot -w reboot
6. For gapps, just reboot into recovery (none of that non persistant boot stuff), and flash the beta android 10 gapps from here
Note: I had to resize the system partition for the LOS17 rom for this as it didnt fill the entire filesystem when it was flashed. Go to the TWRP terminal and run mount to find the device path for /system and then run resize2fs /device/block/whatever.
Click to expand...
Click to collapse
Nevermind
I tried using the vendor from ULM 20e and it doesnt work, i even tried flashing dm verity right after. How would one modify the vendor partition anyways?

How to flash GSIs on devices with dynamic super partition

Code:
* Disclaimer
* I am not responsible for bricked devices, dead SD cards, thermonuclear war,
* or you getting fired because the alarm app failed. Please do some research
* before flashing GSI! YOU are choosing to make these modifications, and if
* you blame me in any way for what happens to your device, I will laugh at you.
* BOOM! goes the dynamite
- make sure you have your stock rom by hand, and in case youre also using a new mediatek device make sure you also have mtk-bypass utility and sp flash tool by hand just in case or any other way of restoring your stock rom
you cant have magisk patched boot image installed unless you have also flashed a different product img
- under developer options enable oem unlocking
- adb reboot bootloader
- fastboot flashing unlock
- fastboot flashing unlock_critical
- fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img
- fastboot --disable-verity --disable-verification flash vbmeta_system vbmeta_system.img
- fastboot reboot fastboot
- fastboot delete-logical-partition product (DONT DO THIS IF YOU WANT TO FLASH MAGISK. IF YOU DO THEN FOLLOW THIS GUIDE REGARDING MAGISK AND PRODUCT PARTITION https://forum.xda-developers.com/t/tutorial-magisk-on-gsi-on-devices-with-dynamic-partition.4311045/)
- fastboot flash system system.img (must be arm64 A/B)
- fastboot reboot recovery
- format in TWRP (https://forum.xda-developers.com/t/unofficial-twrp-3-5-2-for-infinix-zero-8-x687.4303243/)
enjoy your GSI experience
note that im not responsible for any bricked devices
do this at your own risk
tested on infinix zero 8 X687
Your device MUST have an unlockable bootloader.
Your device MUST be Project Treble compatible. That means your device meets one of the following criteria:
Your device LAUNCHED with Android 8.0 Oreo or a newer version (eg. Android 8.1 Oreo) AND is Google Play certified. (If you rooted your device/flashed another custom ROM and somehow ended up with your device being listed as uncertified in Google Play, then don’t worry. We’re only concerned about the status of the device as it was shipped.)
Your device UPGRADED to Android 8.0 Oreo or a newer version AND was made Project Treble compatible by the manufacturer. See this article for a list of such devices.
Your device does not meet either of the above criteria but DOES have access to an unofficial way to be made Treble compatible. Again, refer to this article for a list of such devices.
Your device is free of any heavy modifications such as the Xposed Framework, SuperSU, or Magisk. You can re-install these afterward, but please be sure you are using the stock boot/ramdisk before proceeding.
Sarticle said:
Your device MUST have an unlockable bootloader.
Your device MUST be Project Treble compatible. That means your device meets one of the following criteria:
Your device LAUNCHED with Android 8.0 Oreo or a newer version (eg. Android 8.1 Oreo) AND is Google Play certified. (If you rooted your device/flashed another custom ROM and somehow ended up with your device being listed as uncertified in Google Play, then don’t worry. We’re only concerned about the status of the device as it was shipped.)
Your device UPGRADED to Android 8.0 Oreo or a newer version AND was made Project Treble compatible by the manufacturer. See this article for a list of such devices.
Your device does not meet either of the above criteria but DOES have access to an unofficial way to be made Treble compatible. Again, refer to this article for a list of such devices.
Your device is free of any heavy modifications such as the Xposed Framework, SuperSU, or Magisk. You can re-install these afterward, but please be sure you are using the stock boot/ramdisk before proceeding.
Click to expand...
Click to collapse
thats complete bs
your device must be launched with android 10 or newer to be able to have dynamic partitions.
google play certification has nothing to do with it.
and if you flash product partition you might get away without reinstalling magisk or xposed
can anyone shed light on whether or the super partition is shared between the slots? in other words, if I flash a boot image to super partition in twrp, will it flash only to that slot's super (slot B in my case is messed up) or will it flash to both slots? I am only trying to flash to slot B super partition in hopes of restoring /system_ext, /product, and /odm. any help is greatly appreciated
thirtythr33 said:
can anyone shed light on whether or the super partition is shared between the slots? in other words, if I flash a boot image to super partition in twrp, will it flash only to that slot's super (slot B in my case is messed up) or will it flash to both slots? I am only trying to flash to slot B super partition in hopes of restoring /system_ext, /product, and /odm. any help is greatly appreciated
Click to expand...
Click to collapse
super partiton only has system, vendor and product a/b partitions
boot isnt on super partition
kusti420 said:
super partiton only has system, vendor and product a/b partitions
boot isnt on super partition
Click to expand...
Click to collapse
ok the reason I ask is I am given the option to flash my backup boot image to super in twrp flash image screen, that's why I asked, and since twrp is reporting that I'm missing system_ext, product, and odm, that flashing to super would fix that, a long shot but I'm desperate.
so to be clear is it shared between slots or does each slot have it's own super? (or the partitions found in it)
kusti420 said:
- make sure you have your stock rom by hand, and in case youre also using a new mediatek device make sure you also have mtk-bypass utility and sp flash tool by hand just in case or any other way of restoring your stock rom
also stock recovery must be installed
and you cant have magisk patched boot image installed
- under developer options enable oem unlocking
- fastboot flashing unlock and then fastboot flashing unlock_critical
- fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img
- fastboot --disable-verity --disable-verification flash vbmeta_system vbmeta_system.img
- fastboot reboot fastboot
- fastboot delete-logical-partition product
- fastboot flash system system.img (must be arm64 A/B)
- fastboot reboot
- format in TWRP (https://forum.xda-developers.com/t/unofficial-twrp-3-5-2-for-infinix-zero-8-x687.4303243/)
or if you dont have a custom recovery then you can just factory reset in stock recovery
enjoy your GSI experience
note that im not responsible for any bricked devices
do this at your own risk
tested on infinix zero 8 X687
Click to expand...
Click to collapse
this is all done on pc right? is everything in order?
JordanPahlevi said:
this is all done on pc right? is everything in order?
Click to expand...
Click to collapse
yes its done on pc and everything is indeed in order
Flash gsi with twrp can't ?
Blacxx said:
Flash gsi with twrp can't ?
Click to expand...
Click to collapse
you can only do it in twrp if you rebuild the whole super partition with the gsi of your choice and flash that
Android prevents apps or pretty much anything from mounting the system.
Stephanie_Sy said:
Android prevents apps or pretty much anything from mounting the system.
Click to expand...
Click to collapse
mounting isnt the problem, it mounts just fine, but its read only, thats the problem
How did you port twrp for infinix zero 8? I need one for infinix note 10
My phone is Techno kd7.
My phone Dynamic Partition Android, I have installed TWRP Recovery but can't flash gsi img because the system is IMG partition 1700 MB and gsi img 1800 up. Please give me a solution sir
Parvej789 said:
My phone is Techno kd7.
My phone Dynamic Partition Android, I have installed TWRP Recovery but can't flash gsi img because the system is IMG partition 1700 MB and gsi img 1800 up. Please give me a solution sir
Click to expand...
Click to collapse
follow the tutorial and flash product partition
this may be of interest or help to Samsung users in particular.
getting fastboot via TWRP to work on windows 7 to 10. it worked for me on windows 10 pro and enabled me to flash GSIs successfully.
Latest ADB Fastboot and USB Drivers installer tool for windows
All praise and All Thanks to God ADB Fastboot and USB Driver installer tool for Windows, which will always install the latest version. To update the adb fastboot and usb drivers again, just rerun the tool. OS Requirements: Windows 7 and above Steps: 1. Connect the phone in USB Debugging mode...
eu.community.samsung.com
it's not just for Samsung users though, it'll install the latest ADB and Fastboot drivers and download Microsoft dependencies. but now us Samsung users can have Fastboot and do
Code:
fastboot flash system system.img
... so yay !!
kusti420 said:
super partiton only has system, vendor and product a/b partitions
boot isnt on super partition
Click to expand...
Click to collapse
i flashed using these commands on my v60 tmobile
--AB devices--
fastboot devices
fastboot --disable-verification flash vbmeta vbmeta.img
fastboot reboot fastboot
fastboot getvar is-userspace
fastboot erase system
fastboot delete-logical-partition product_insertslothere
Example
fastboot delete-logical-partition product_a
fastboot delete-logical-partition productb
fastboot flash system system.img
fastboot reboot recovery
i flashed 3 gsi A10s, los 17.1 didnt boot, pixel experiance and RR Remix booted but never entered android. and when i tried to flash my kdz it flashes all parititons except for super.img it fails everytime on different modes of LG up. I flashed super.img via Qfil but phon wont boot.
i even tried using ChonDoe_Flasher via twrp in a folder it flashes but it still wont boot at all. at this point i cant use LGup because i get stuck in download mode. any help would be greatly appreciated
blaze2051 said:
Try :
Click to expand...
Click to collapse
Commands used to Install gsi Rom using Fastboot Mode
1. First Go into Fastboot mode by typing this command
adb reboot bootloader
fastboot --disable-verity --disable-verification flash vbmeta_a vbmeta.img
2.Type these commands 1 by 1
fastboot reboot fastboot
fastboot delete-logical-partition product_a
fastboot delete-logical-partition system_ext_a
fastboot erase system
fastboot flash system system.img(dynamic gsi ROM flash)
fastbo -w
fastboot reboot
Note(stock recovery to try)
Parvej789 said:
Commands used to Install gsi Rom using Fastboot Mode
1. First Go into Fastboot mode by typing this command
adb reboot bootloader
fastboot --disable-verity --disable-verification flash vbmeta_a vbmeta.img
2.Type these commands 1 by 1
fastboot reboot fastboot
fastboot delete-logical-partition product_a
fastboot delete-logical-partition system_ext_a
fastboot erase system
fastboot flash system system.img(dynamic gsi ROM flash)
fastbo -w
fastboot reboot
Note(stock recovery to try)
Click to expand...
Click to collapse
i finally got a working rom install since i cant go back to oem stock, it wasnt the commands it was the roms, they just dont boot at all. except one 1 rom did boot. all others LOS 16-18 RR Remix and Pixel experiamce all failed to boot except for E foundation rom
/http://doc.e.foundation/how-tos/understand-and-use-gsi 7
/http://doc.e.foundation/how-tos/install-GSI 7
New links​to download the latest official
dev /e/ G.S.I. android.10 Q
Once you know which system image you need
Arm A 2 (system-arm-a.img.xz)
Arm A/B 3 (system-arm-ab.img.xz)
Arm64 A 11 (system-arm64-a.img.xz)
Arm64 A/B 31 (system-arm64-ab.img.xz)
Binder 64 A 1 (system-a64-a.img.xz)
Binder 64 A/B 4 (system-a64-ab.img.xz)
I no know.
Dynamic
gsi ROM
GsI Rom Link : Tested rom
Tecno kd7 work
*Official Android 11 :
1. AOSP 11.0 v313_system-roar-arusson
Download link AOSP 11.0 v313
*Unofficial QAndroid 11 :
1. Pixel Experience Plus 11.0 v313
Thanks for ponces
Download link PixelExperience_Plus_arm64-ab-11.0-20211011-UNOFFICIAL.img.xz
*Unofficial Android 12 :
1.Pixel Experience 12.0 v400.e
Thanks for ponces
Full googel rom. my used 5 day . 1 bug : bootanimation not vew full size
Download link :PixelExperience_arm64-ab-12.0-20211226-UNOFFICIAL.img.xz

Where to get vbmeta.img for my phone

I followed a tutorial and it gave a single vbmeta.img file that it can be used for all Android devices. Is this true or does each device have its own vbmeta.img file? If Each device has its own then where can I get that of my phone (Tecno Spark 4 KC8 Android 10)? Can I get it from the Stock Firmware? If yes how do I go about it? If no then how can I get it
Please I need help.
Sakodie King TI said:
I followed a tutorial and it gave a single vbmeta.img file that it can be used for all Android devices. Is this true or does each device have its own vbmeta.img file? If Each device has its own then where can I get that of my phone (Tecno Spark 4 KC8 Android 10)? Can I get it from the Stock Firmware? If yes how do I go about it? If no then how can I get it
Please I need help.
Click to expand...
Click to collapse
vbmeta.img is unique for the phone model.
you can get it be extracting your stock firmware.
Kenora_I said:
vbmeta.img is unique for the phone model.
you can get it be extracting your stock firmware.
Click to expand...
Click to collapse
Hi #[email protected] thanks very much. So you mean if I extract the stock firmware of my model I should be able to see a file named vbmeta right (or do I need to go an extra mile to get the vbmeta file)? Now what of a blank (empty) vbmeta.img file. How do I get it because I need to flash it before flashing custom recovery? Also can I use a universal empty vbmeta.img as I saw on a tutorial or my model also has its specific empty vbmeta.img file?
The one in the tutorial.is fine.
Kenora_I said:
The one in the tutorial.is fine.
Click to expand...
Click to collapse
Um, So, To install TWRP, I need -dm-verity-opt-encrypt.zip and vbmeta.img. Should the Vbmeta, be specific for each device, only to install a custom rom? or also specific to install a recovery like TWRP, If I install TWRP, I still need the Vbmeta, to install custom roms, or I only need it when using ADB, Um, Also, Do I need no-verity-opt-encrypt, I saw a post, that I need to flash it in order to install the TWRP, If I dont need the dm-verity to install the TWRP, Can I directly flash vbmeta?
I saw this code to install TWRP on my device:
Code:
fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img
fastboot flash recovery TWRP.img
I need to ask 2 more things:
1) how to check if my device is compatible with No-verity-opt-Encrypt?
2) Differences between DM Verity, OPT Encrypt, and Force Encryption Disabler?
Why would I need to disable verity? What is No verity, and what is vbmeta?
Is there any FULL Comprehensive Tutorial on this mobile Custom Rom Cooking lecture, So that I could know about treble, recoveries, kernels, and etc. Please.
Thanks
Hi TechySkills see my answer in the next comment below for a clear explanation.
TechySkills said:
Um, So, To install TWRP, I need -dm-verity-opt-encrypt.zip and vbmeta.img. Should the Vbmeta, be specific for each device, only to install a custom rom? or also specific to install a recovery like TWRP, If I install TWRP, I still need the Vbmeta, to install custom roms, or I only need it when using ADB, Um, Also, Do I need no-verity-opt-encrypt, I saw a post, that I need to flash it in order to install the TWRP, If I dont need the dm-verity to install the TWRP, Can I directly flash vbmeta?
I saw this code to install TWRP on my device:
Code:
fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img
fastboot flash recovery TWRP.img
I need to ask 2 more things:
1) how to check if my device is compatible with No-verity-opt-Encrypt?
2) Differences between DM Verity, OPT Encrypt, and Force Encryption Disabler?
Why would I need to disable verity? What is No verity, and what is vbmeta?
Is there any FULL Comprehensive Tutorial on this mobile Custom Rom Cooking lecture, So that I could know about treble, recoveries, kernels, and etc. Please.
Thanks
Click to expand...
Click to collapse
[Links have been attached at the end of the explanation]...
I started this thread sometime ago and after following up, I have now documented everything.
-- DM-Verity (or Verified Boot), Forceencryption and SafetyNet are some basic Android security features. For security reasons, Android should boot with what the OEM has provided (modifications to partitions or modified/custom partitions are not trusted; the reason your phone won't boot or boots with a warning if you make changes to the OS).
-- DM-Verity checks for alterations when your phone is booting and if detected, Forceencryption encrypts the data partition to prevent a data breach. Meanwhile Safetynet is also triggered when you alter the OS and apps that depend on the strict Android security won't work well if SafetyNet fails.
-- TWRP (which can be flashed using: fastboot flash recovery TWRP.img)
is a custom recovery partition (not provided or approved by the OEM), GSI is a custom system partition (not approved by the OEM) and to install any custom partition, it is wise to disable the security barriers (Forceencryption, DM-Verity). As you are taking over control of your phone, whatever issue you fall into afterwards should be addressed to yourself.
-- In older Android versions, DM-verity sits in the boot partition. But in recent Android versions (9, 10, etc), it sits in the dedicated vbmeta partition and that is why you have to flash an empty/signed vbmeta image (using:
fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img) to bypass DM-Verity. Google has a universal vbmeta image that works for all devices. For Forceencryption, you need to flash a disabler zip like dm-verity-and-forceencrypt-disabler zip (also disables DM-verity) or no-verity-opt-encrypt zip. Or you can also edit the vendor fstab file to remove encryption.
-- See What Is Verified Boot (DM-Verity) In Android And How To Disable It https://sakophone.wordpress.com/202...ce=728bab228a&preview=true&_thumbnail_id=4446
-- See Encryption, Decryption And Forceencryptin https://sakophone.wordpress.com/2022/01/03/encryption-decryption-and-forceencryptin/#forceencryption
Hello,
1. In the first link you gave, It says, that, after flashing a custom recovery, flash forceencryption, I don't know how to flash forceencryption through adb, cuz, If i just flash the TWRP, and boot, In my guess, It will not open, unless you flash the forceencrytption.
2. As you said in your reply, "fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img" So this removes the need to flash the zip file as mentioned in the first step?? But right after you said that, You also need to flash the dm-verity zip file. I am very very confused.
3. Also, What is exactly vbmeta, I understood about dm-verity etc, But I am still confused about vbmeta, can you please comprehend it to me?
4. What is the need of rooting the phone, after unlocking the bootloader, like, why root phone, when the phone is already unlocked? Please remove these stupid confusions of mine.
Thanks
TechySkills said:
Hello,
1. In the first link you gave, It says, that, after flashing a custom recovery, flash forceencryption, I don't know how to flash forceencryption through adb, cuz, If i just flash the TWRP, and boot, In my guess, It will not open, unless you flash the forceencrytption.
2. As you said in your reply, "fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img" So this removes the need to flash the zip file as mentioned in the first step?? But right after you said that, You also need to flash the dm-verity zip file. I am very very confused.
3. Also, What is exactly vbmeta, I understood about dm-verity etc, But I am still confused about vbmeta, can you please comprehend it to me?
4. What is the need of rooting the phone, after unlocking the bootloader, like, why root phone, when the phone is already unlocked? Please remove these stupid confusions of mine.
Thanks
Click to expand...
Click to collapse
If you went through the guides I sent, you should have all your answers there.
1. The key used by DM-Verity is signed and kept in the vbmeta partition (from Android 8 onwards). Therefore you have to flash a vbmeta that has been signed or an empty vbmeta (that holds no key to do a check) to disable DM-VERITY.
2. vbmeta disables DM-verity and not Forceencryption. The disabler zips disable Forceencryption (and some disable DM-VERITY too). For zips that disable both Forceencryption and DM-Verity, you can use just it and not use the signed/empty vbmeta.
3. Your phone is protected out of the box for your own safety. If you want to take total control over it, you must alert the system by unlocking it (unlocking the bootloader). If you want to give back all the control to your phone, relock bootloader. Note that unlocking/locking bootloader wipes all your data so do backups first.
4. Bootloader is the first step and must be done, if not, the phone won't boot. After bootloader then comes turning off security barriers (DM-Verity, Forceencryption).
5. Though the steps might vary, they usually follow this manner:
• Unlock bootloader. Turn on the toggle in Developer options and then use fastboot to complete the unlocking
• Flash vbmeta to disable DM-VERITY
• Flash TWRP. Though Forceencryption has not been removed yet, TWRP will boot. Now format data in TWRP to temporarily make the phone decrypted. With a temporarily decrypted state, you can access your internal storage to select Forceencryption disabler zip. Flashing the zip makes decryption Permanent.
• You can now reboot or continue flashing other stuff like other recovery, GSI, custom ROM, magisk, etc. Most of them can be done from TWRP itself (the reason you need TWRP in the first place)
• Rooting is optional. You can decide not to root even if you have TWRP, custom ROM, etc. Some apps need superuser privileges to work and you can only use them in a rooted phone (the reason people root their phone). These apps are mostly those that modify the OS. Flashing magisk roots your phone.
Any doubts again?
Sakodie King TI said:
If you went through the guides I sent, you should have all your answers there.
1. The key used by DM-Verity is signed and kept in the vbmeta partition (from Android 8 onwards). Therefore you have to flash a vbmeta that has been signed or an empty vbmeta (that holds no key to do a check) to disable DM-VERITY.
2. vbmeta disables DM-verity and not Forceencryption. The disabler zips disable Forceencryption (and some disable DM-VERITY too). For zips that disable both Forceencryption and DM-Verity, you can use just it and not use the signed/empty vbmeta.
3. Your phone is protected out of the box for your own safety. If you want to take total control over it, you must alert the system by unlocking it (unlocking the bootloader). If you want to give back all the control to your phone, relock bootloader. Note that unlocking/locking bootloader wipes all your data so do backups first.
4. Bootloader is the first step and must be done, if not, the phone won't boot. After bootloader then comes turning off security barriers (DM-Verity, Forceencryption).
5. Though the steps might vary, they usually follow this manner:
• Unlock bootloader. Turn on the toggle in Developer options and then use fastboot to complete the unlocking
• Flash vbmeta to disable DM-VERITY
• Flash TWRP. Though Forceencryption has not been removed yet, TWRP will boot. Now format data in TWRP to temporarily make the phone decrypted. With a temporarily decrypted state, you can access your internal storage to select Forceencryption disabler zip. Flashing the zip makes decryption Permanent.
• You can now reboot or continue flashing other stuff like other recovery, GSI, custom ROM, magisk, etc. Most of them can be done from TWRP itself (the reason you need TWRP in the first place)
• Rooting is optional. You can decide not to root even if you have TWRP, custom ROM, etc. Some apps need superuser privileges to work and you can only use them in a rooted phone (the reason people root their phone). These apps are mostly those that modify the OS. Flashing magisk roots your phone.
Any doubts again?
Click to expand...
Click to collapse
Um, No, Thank you very very very much, You literally fixed all my confusions, I actually bricked my phone and had to go to support office previous month, and pay 2$ (500PKR) to fix it. That is why, I was asking and clearing my confusions. Thank you, Now I am very confident, That, I can now flash my device. Thank you!
TechySkills said:
Um, No, Thank you very very very much, You literally fixed all my confusions, I actually bricked my phone and had to go to support office previous month, and pay 2$ (500PKR) to fix it. That is why, I was asking and clearing my confusions. Thank you, Now I am very confident, That, I can now flash my device. Thank you!
Click to expand...
Click to collapse
Good to hear
{Mod edit: Quotation fixed - Oswald Boelcke, Moderator}
Sakodie King TI said:
[Links have been attached at the end of the explanation]...
I started this thread sometime ago and after following up, I have now documented everything.
-- DM-Verity (or Verified Boot), Forceencryption and SafetyNet are some basic Android security features. For security reasons, Android should boot with what the OEM has provided (modifications to partitions or modified/custom partitions are not trusted; the reason your phone won't boot or boots with a warning if you make changes to the OS).
-- DM-Verity checks for alterations when your phone is booting and if detected, Forceencryption encrypts the data partition to prevent a data breach. Meanwhile Safetynet is also triggered when you alter the OS and apps that depend on the strict Android security won't work well if SafetyNet fails.
-- TWRP (which can be flashed using: fastboot flash recovery TWRP.img)
is a custom recovery partition (not provided or approved by the OEM), GSI is a custom system partition (not approved by the OEM) and to install any custom partition, it is wise to disable the security barriers (Forceencryption, DM-Verity). As you are taking over control of your phone, whatever issue you fall into afterwards should be addressed to yourself.
-- In older Android versions, DM-verity sits in the boot partition. But in recent Android versions (9, 10, etc), it sits in the dedicated vbmeta partition and that is why you have to flash an empty/signed vbmeta image (using:
fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img) to bypass DM-Verity. Google has a universal vbmeta image that works for all devices. For Forceencryption, you need to flash a disabler zip like dm-verity-and-forceencrypt-disabler zip (also disables DM-verity) or no-verity-opt-encrypt zip. Or you can also edit the vendor fstab file to remove encryption.
-- See What Is Verified Boot (DM-Verity) In Android And How To Disable It https://sakophone.wordpress.com/202...ce=728bab228a&preview=true&_thumbnail_id=4446
-- See Encryption, Decryption And Forceencryptin https://sakophone.wordpress.com/2022/01/03/encryption-decryption-and-forceencryptin/#forceencryption
Click to expand...
Click to collapse
So, I want to install twrp to install a custom rom, but you said if I want to change from miui to a custom rom, it needs a file called "vbmeta" but after I did a search, the vbmeta file is only needed if the device is running Android 8 and above, whereas my device is on Android 7 | MIUI 10 | Santoni, and it says it only needs DM-verity? What should I do to be able to install a custom ROM?
kjisoo said:
So, I want to install twrp to install a custom rom, but you said if I want to change from miui to a custom rom, it needs a file called "vbmeta" but after I did a search, the vbmeta file is only needed if the device is running Android 8 and above, whereas my device is on Android 7 | MIUI 10 | Santoni, and it says it only needs DM-verity? What should I do to be able to install a custom ROM?
Click to expand...
Click to collapse
vbmeta was introduced starting Android 8, so no need looking for a vbmeta if you are on Android 7. Starting Android 7, dm-verity had to be strictly enforcing (optional). If this is your case, then you can disable it in Android 7 by using flasher zips. Everything is in this guide.
What Is Verified Boot (DM-Verity) In Android And How To Disable It
Last Updated: February/21/2023 Contents Getting Started What Actually Is Verified Boot And Dm-Verity In Android How Verified Boot And DM-Verity Work In Older Devices (Android 7 And Below) How Verif…
sakophone.wordpress.com
@Kenora_I hi, maybe you know. I have Redmi 9 with soft upgraded to android 12.1 and i wanted boot temporary to SHRP. I tried fasboot flash recovery shrp.img and fasboot reboot recovery after but my device did not boot to recovery but started normally into system. May it be problem with vbmeta? My device ia A partition only.
Slawek_ said:
@Kenora_I hi, maybe you know. I have Redmi 9 with soft upgraded to android 12.1 and i wanted boot temporary to SHRP. I tried fasboot flash recovery shrp.img and fasboot reboot recovery after but my device did not boot to recovery but started normally into system. May it be problem with vbmeta? My device ia A partition only.
Click to expand...
Click to collapse
PART 1:
Maybe your device lacks recovery partition (common with new and AB slot devices). If this is so, "fastboot flash recovery shrp.img" won't work because there's no recovery partition (recovery now sits in boot partition as boot-ramdisk).
Such devices need two recovery files: img and zip. If you have the two, the ZIP should be in your phone and the img in your PC then first boot the SHRP:
fastboot boot shrp.img
When recovery boots up, locate and flash the ZIP then from SHRP, reboot recovery and enjoy.
NB: I am assuming the name of your img file is shrp.img which might differ.
PART 2:
However, if you are sure your device is A-only, then here you go (make sure the shrp.img is the one for your device and you have the universal vbmeta disable):
fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img
fastboot flash recovery shrp.img
## For AB devices with recovery partition, you can specify slot
fastboot flash recovery_a shrp.img
fastboot flash recovery_b shrp.img
Fastboot reboot
NB: You can choose to boot shrp (instead of permanently install) if you want to use it just now:
fastboot boot shrp.img
Hi @Sakodie King TI ,
I tried fastboot boot command but im getting "too many links error."
Treble check saying my phone is A partition only.
I also checked
fastboot flash recovery shrp.img
then rebooting manualy by volume up + pwr but then im getting bootloop while holding these keys.
That is why i asked is this can be caused by vbmeta.
Sakodie King TI said:
Maybe your device lacks recovery partition (common with new and AB slot devices). If this is so, "fastboot flash recovery shrp.img" won't work because there's no recovery partition (recovery now sits in boot partition as boot-ramdisk).
Such devices need two recovery files: img and zip. If you have the two, the ZIP should be in your phone and the img in your PC then first boot the SHRP:
fastboot boot shrp.img
When recovery boots up, locate and flash the ZIP then from SHRP, reboot recovery and enjoy.
NB: I am assuming the name of your img file is shrp.img which might diffe
Click to expand...
Click to collapse
Slawek_ said:
Hi @Sakodie King TI ,
I tried fastboot boot command but im getting "too many links error."
Treble check saying my phone is A partition only.
I also checked
fastboot flash recovery shrp.img
then rebooting manualy by volume up + pwr but then im getting bootloop while holding these keys.
That is why i asked is this can be caused by vbmeta.
Click to expand...
Click to collapse
Did you flash vbmeta first?
And try "fastboot reboot recovery" after flashing instead of using volume keys
I did not flash vbmeta at all. I'm afraid i will brick device.
Shouldn't shrp boot temporary without flashing vbmeta?
Slawek_ said:
I did not flash vbmeta at all. I'm afraid i will brick device.
Shouldn't shrp boot temporary without flashing vbmeta?
Click to expand...
Click to collapse
You have to flash vbmeta first. instead, doing it without flashing vbmeta means you are looking for ways to brick your device.
Hey @Sakodie King TI
So i did this:
{
"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"
}
After reboot recovery i got rebooted to system not recovery.
Also when i'm rebooting to recovery manually, i'm still on old muiu recovery nothing changed.
I took vbmeta from my firmware lancelot_eea_global_images_V13.0.3.0.SJCEUXM_20230111.0000.00_12.0_eea.
In that firmware there are also vbmeta_system.img and vbmeta_vendor.img maybe need to flash them also with --disable-verity --disable-verification parameters?

[Closed] Android 12 Update and Root ***Obsolete***

Update 12-16: I am closing this thread as it is no longer relevant. Please refer to this guide.
@V0latyle Can you help me out I installed a magisk module that caused a bootloop and I tried the adb wait-for-device shell magisk --remove-modules and it doesn't work for me I'm on the P5 a12 beta 5 I have since flashed the stock boot.img. What can I do to remove this module?
elong7681 said:
@V0latyle Can you help me out I installed a magisk module that caused a bootloop and I tried the adb wait-for-device shell magisk --remove-modules and it doesn't work for me I'm on the P5 a12 beta 5 I have since flashed the stock boot.img. What can I do to remove this module?
Click to expand...
Click to collapse
I'm honestly not that familiar with Magisk, sorry. I suggest you ask in the Magisk thread, they'll be of more help to you over there. Magisk modules live in /data, not /boot, so a data wipe would get rid of the module...and all your user data too.
V0latyle said:
I'm honestly not that familiar with Magisk, sorry. I suggest you ask in the Magisk thread, they'll be of more help to you over there. Magisk modules live in /data, not /boot, so a data wipe would get rid of the module...and all your user data too.
Click to expand...
Click to collapse
Ok thanks for your help I appreciate it
elong7681 said:
@V0latyle Can you help me out I installed a magisk module that caused a bootloop and I tried the adb wait-for-device shell magisk --remove-modules and it doesn't work for me I'm on the P5 a12 beta 5 I have since flashed the stock boot.img. What can I do to remove this module?
Click to expand...
Click to collapse
Wiki:
Module Issues:Magisk and MagiskHide Installation and Troubleshooting guide
www.didgeridoohan.com
Scroll down to read how to disable modules through Safe Mode
There is also a section how to manage modules from custom Recovery (if TWRP applies to your phone)
You seem to understand the issue with vmeta (and the associated data wipe). So I went from android 11 to android 12 beta without a wipe and although on andorid 11 i could flash my kernels, on android 12 i cannot without vmeta/wipe. I thought I read that it was because 12 was in beta. I plan to flash the factory image of 12 today, withotu doing a wipe of course. Will i be able to flash my custom kernles again?
How do we get in the download mode to install the OTA?
I do use adb reboot recovery
but every time, I got this.
E:\platform-tools>adb sideload E:\platform-tools\blueline-ota-sp1a.210812.015-cee465f5.zip
adb: sideload connection failed: device unauthorized.
This adb server's $ADB_VENDOR_KEYS is not set
Try 'adb kill-server' if that seems wrong.
Otherwise check for a confirmation dialog on your device.
adb: trying pre-KitKat sideload method...
adb: pre-KitKat sideload connection failed: device unauthorized.
This adb server's $ADB_VENDOR_KEYS is not set
Try 'adb kill-server' if that seems wrong.
Otherwise check for a confirmation dialog on your device.
E:\platform-tools>adb sideload E:\platform-tools\blueline-ota-sp1a.210812.015-cee465f5.zip
adb: sideload connection failed: no devices/emulators found
adb: trying pre-KitKat sideload method...
adb: pre-KitKat sideload connection failed: no devices/emulators found
ShadowJP88 said:
How do we get in the download mode to install the OTA?
I do use adb reboot recovery
but every time, I got this.
.....
Click to expand...
Click to collapse
Once you're in recovery, are you going into ADB sideload (hold the power button, then press the volume up key, then choose "Apply update from ADB")?
kfhughes said:
Once you're in recovery, are you going into ADB sideload (hold the power button, then press the volume up key, then choose "Apply update from ADB")?
Click to expand...
Click to collapse
I can't find out how... I only have the droid page with "no command" text
sorry i cant understand this:
* If, after flashing a patched boot image, you get the "unable to load/verify boot image", you probably didn't get the flags quite right. Just reflash vbmeta with the disable flags and that should fix the problem.
pixel 5 here, unlocked bootloader, did a clean flash, booted magisk , after direct install and restart i was stuck at booloader menu with that message, i don't understand what i have to do reading your post
where can i do this and how? Just reflash vbmeta with the disable flags
i had to clean flash again to use the phone
For re-flashing the vbmeta.img, my command has always been a little different than yours.
I use: fastboot flash --disable-verity --disable-verification vbmeta vbmeta.img
It's only a little different and your way might work, but if anyone has issues you could try this different command instead.
ShadowJP88 said:
I can't find out how... I only have the droid page with "no command" text
Click to expand...
Click to collapse
Hold down the power button and tap volume up to bring up the recovery menu.
V0latyle said:
With the Android 12 stable release just around the corner, I would like to make sure we have clear instructions on how to update with root.
These instructions work with the beta as well. This may seem redundant compared to other threads, but I wanted to consolidate the relevant information to one place.
WARNING: MANUALLY INSTALLING FACTORY UPDATES OR IMAGES REQUIRES AN UNLOCKED BOOTLOADER. If your bootloader is locked, DO NOT ATTEMPT THIS. You can, however, update using the OTA via ADB Sideload on a locked bootloader. DO NOT INSTALL THE BETA OTA WITH A LOCKED BOOTLOADER. BETA SOFTWARE IS EXPERIMENTAL AND MAY BE UNSTABLE, AND YOU MAY BE UNABLE TO RECOVER YOUR DEVICE IF SOMETHING GOES WRONG.
WARNING: MODIFY YOUR DEVICE AT YOUR OWN RISK. YOU ALONE WILL BE RESPONSIBLE FOR MALFUNCTION, DAMAGE, OR LOSS OF ANY KIND IF SOMETHING GOES WRONG.
Root will be done via Magisk. If you aren't already using it, download and install to your phone.
Warning: For the sake of simplicity, I frequently will use generalizations when referring to files ("[patched boot image]" instead of "magisk_patched-23001_xxxxx.img" for example). It is YOUR RESPONSIBILITY to ensure you are flashing the correct file. The easiest way to do this is type the command in the command line without the file itself, then drag and drop the file you want to flash into the command line window.
For those of you with a locked bootloader:
Simply install the update as usual via OTA, whether automatically through Android Update, or manually via adb sideload.
First, a bit of information on why you need to follow this guide (See this post)
Two new Verified Boot features implemented in Android 12 will interfere with attempts to root. A more detailed explanation is below if you would like.
Spoiler
Dm-verity (device-mapper-verity) is a method by which an image on block devices (the underlying storage layer of the file system) can be checked to determine if it matches an expected configuration, using a cryptographic hash tree. If the hash doesn't match, dm-verity prevents the stored code from loading.
Vbmeta verification is the other half of this - it provides a cryptographically signed reference hash which is used to verify the integrity of /boot, /system, and /vendor partitions. The vbmeta image is only used to verify /boot, while vbmeta-system is used to verify /system.
This was implemented to prevent persistent rootkits by means of a hardware level security check, to prevent "potentially harmful applications" such as Magisk from evading detection, as such applications residing within the kernel will have higher privileges than the detection applications.
What this means is that with these two enabled, a modified boot image will cause a verification error when flashed to the device, preventing boot. Interestingly, this check is not performed against "live" boot images loaded via ADB, so with dm-verity and vbmeta verification enabled, a modified image can be booted as long as the image in /boot is intact.
To update to Android 12 with data intact and reroot:
WARNING: Per Google, an Android 12 OTA should only be installed on a device running 12 DP or 12 Beta. However, other users were able to manually install the OTA via ADB without losing data, so DO THIS AT YOUR OWN RISK! It is currently unknown what Google's official instructions will be for installing the update, so the "best" current method is wait for automatic OTA.
Spoiler
If you update via automatic OTA:
1. Download the factory image (Yes, this is required) to your computer. Connect your device via USB.
2. Extract the contents of the factory image, then extract both boot.img and vbmeta.img from the image-[device].zip (where [device] is the codename for your device, such as Redfin for Pixel 5
3. Continue to Reflash vbmeta below
To manually install the OTA:
1. Download the OTA for your device, as well as the factory image (Yes, you need both) to your computer.
2. Install the OTA
3. Extract the contents of the factory image, then extract both boot.img and vbmeta.img from the image-[device].zip (where [device] is the codename for your device, such as Redfin for Pixel 5
4. Let the update complete, including reboot. Wait until you are in /system with the update process finished (no update notification)
5. Continue to Reflash vbmeta below
Reflash VBmeta
1. With device connected via USB, Developer Options enabled and USB Debugging enabled, reboot to bootloader using ADB:
Code:
adb reboot bootloader
2. Reflash vbmeta with dm-verity and boot verification disabled:
Code:
fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img
3. Reboot to bootloader:
Code:
fastboot reboot bootloader
Continue to Patch Boot Image below.
To update to Android 12 using Android Flash Tool:
Spoiler
1. Open this link in Google Chrome (DO NOT USE MICROSOFT EDGE OR MOZILLA FIREFOX) Here is the link for beta
2. Connect your device via USB (make sure USB Debugging is enabled)
3. Enable ADB access in the browser
4. Select your device
5. Select the Android 12 build
6. IMPORTANT: Click the pencil icon next to the selected build
7. Ensure Wipe Device, Disable Verification, and Disable Verity are checked. DATA WIPE IS REQUIRED when updating from an older version of Android. Don't lock your bootloader if you want root. Force flash all partitions should not be necessary (but use this if you've run into problems and are starting over). Skip Secondary and Force Debuggable should be unchecked, unless you want to use ADB for root access on the stock kernel for some reason.
8. Click Install Build.
9. Wait until the update finishes.
10. Continue to Patch Boot Image below.
To update to Android 12 via ADB using the factory image:
Spoiler
1. Download the factory image to your computer and connect your device via USB, with USB debugging enabled.
2. Extract the contents of the factory ZIP
3. Reboot to bootloader:
Code:
adb reboot bootloader
4. If necessary, update the bootloader: WARNING: IF DONE INCORRECTLY THIS WILL BRICK YOUR DEVICE!
Code:
fastboot flash bootloader [bootloader image]
Reboot back to bootloader.
5. If necessary, update the radio:
Code:
fastboot flash radio [radio image]
Reboot to bootloader.
6. Install the update:
Code:
fastboot --disable-verity --disable-verification -w update [factory image zip]
DATA WIPE IS REQUIRED when updating from an older version of Android.
7. Let the update complete
8. Continue to Patch Boot Image below
Patch Boot Image:
Spoiler
1. Extract boot.img from the factory image ZIP if you haven't done so already
2. Install Magisk on your phone
3. Move the boot image to your phone via USB, and patch it using "Select and Patch a File" in Magisk
4. Move the patched boot image back to your PC
5. Reboot to bootloader
6. Flash the patched boot image:
Code:
fastboot flash boot [patched boot image]
7. Reboot to system.
For subsequent updates to Android 12:
Either install the update via OTA Sideload, then reflash vbmeta with disable flags set, or dirty flash the factory image with disable flags set.
Live boot your patched boot image from bootloader (as long as you're still on Android 12, the old kernel should work fine):
Code:
fastboot boot [patched boot image]
In system, launch Magisk then select "Direct Install" to patch the stock image in /boot.
Key reminders:
* The OTA does not have a way to set the disable flags for vbmeta, so if you update via OTA, you will have to reflash vbmeta with the disable flags every time you update.
* If you forget to do this and have a patched boot image, bootloader will return an error: "failed to load/verify boot image"
* The fastest and easiest way to update is via OTA, but remember you will lose root until you're able to reflash vbmeta and repatch the boot image.
* Manually patching the new boot image in Magisk via "Select and Patch a File" should be unnecessary every time you update. You can, instead, just keep the image you originally patched, boot it every time you update, and flash the stock image in /boot using Magisk.
* If, after flashing a patched boot image, you get the "unable to load/verify boot image", you probably didn't get the flags quite right. Just reflash vbmeta with the disable flags and that should fix the problem.
Click to expand...
Click to collapse
@V0latyle I think I know why some people are having issues with obtaining root or maintaining root on Android 12 official release... When you use the following command,
Code:
fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img
I think after this command and then flashing the patched magisk boot image their might be a check on both slots. Would I be wrong suggesting for the disable vbmeta command be this instead?
Code:
fastboot --disable-verity --disable-verification flash --slot=all vbmeta vbmeta.img
I was having the same issue where it was saying that the system was corrupt and having to do a factory wipe after doing the command without --slot=all for the vbmeta disable flag command.
rester555 said:
@V0latyle I think I know why some people are having issues with obtaining root or maintaining root on Android 12 official release... When you use the following command,
Code:
fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img
I think after this command and then flashing the patched magisk boot image their might be a check on both slots. Would I be wrong suggesting for the disable vbmeta command be this instead?
Code:
fastboot --disable-verity --disable-verification flash --slot=all vbmeta vbmeta.img
I was having the same issue where it was saying that the system was corrupt and having to do a factory wipe after doing the command without --slot=all for the vbmeta disable flag command.
Click to expand...
Click to collapse
I haven't read his full instructions hidden behind the spoiler tags, but in my experience after flashing the vbmeta.img the first time, I needed to follow it with "fastboot -w" and wipe my phone, then flash the patched boot.img.
On subsequent updates as long as I booted to bootloader immediately after flashing the OTA.zip to flash vbmeta, I didn't have to wipe. If I boot to system by mistake, I'll need to fastboot -w again
rester555 said:
@V0latyle I think I know why some people are having issues with obtaining root or maintaining root on Android 12 official release... When you use the following command,
Code:
fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img
I think after this command and then flashing the patched magisk boot image their might be a check on both slots. Would I be wrong suggesting for the disable vbmeta command be this instead?
Code:
fastboot --disable-verity --disable-verification flash --slot=all vbmeta vbmeta.img
Click to expand...
Click to collapse
xunholyx said:
I haven't read his full instructions hidden behind the spoiler tags, but in my experience after flashing the vbmeta.img the first time, I needed to follow it with "fastboot -w" and wipe my phone, then flash the patched boot.img.
On subsequent updates as long as I booted to bootloader immediately after flashing the OTA.zip to flash vbmeta, I didn't have to wipe. If I boot to system by mistake, I'll need to fastboot -w again
Click to expand...
Click to collapse
@xunholyx I did what you suggested, flashing the vbmeta.img and then patching the magisk boot image and I got the corrupt system message in recovery. So I ended up reflashing stock image with wipe through adb.. did minimal initial setup, then reflashed the vbmeta.img to all slots and then immediately flashed the patched magisk image. That seemed to work for me to gain root on A12.
Did as you showed , and it works well .Thank!
4a 5G here (sorry, I know that this is the section for Pixel 5, but I assume most or all things are the same). I rushed and installed the OTA the normal way, thinking I'll be able to patch and flash boot.img afterwards (like normally). Update went fine (upgrading from 11, haven't used any of the DPs/betas), but after I flash the patched boot.img, I get "failed to load/verify boot images" in fastboot. Am I out of luck?
rester555 said:
@V0latyle I think I know why some people are having issues with obtaining root or maintaining root on Android 12 official release... When you use the following command,
Code:
fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img
I think after this command and then flashing the patched magisk boot image their might be a check on both slots. Would I be wrong suggesting for the disable vbmeta command be this instead?
Code:
fastboot --disable-verity --disable-verification flash --slot=all vbmeta vbmeta.img
I was having the same issue where it was saying that the system was corrupt and having to do a factory wipe after doing the command without --slot=all for the vbmeta disable flag command.
Click to expand...
Click to collapse
So are you saying that using the slot all flag fixed your problem?
killchain said:
4a 5G here (sorry, I know that this is the section for Pixel 5, but I assume most or all things are the same). I rushed and installed the OTA the normal way, thinking I'll be able to patch and flash boot.img afterwards (like normally). Update went fine (upgrading from 11, haven't used any of the DPs/betas), but after I flash the patched boot.img, I get "failed to load/verify boot images" in fastboot. Am I out of luck?
Click to expand...
Click to collapse
Did you follow the instructions on flashing vbmeta with the disable flags set?
Another 4a 5G owner here. I installed the OTA via recovery yesterday and tried to flash a patched boot.img, but got "failed to load/verify boot images". Reanimated the phone using a factory image, then tried to flash vbmeta.img with verification disabled (but no wipe) and patched boot.img. The phone couldn't boot into the system and offered to perform factory reset. I didn't want to wipe anything so I didn't go with it, but it seems like there is no way to root 4a 5G and keep your data (at least for now).
But I will be happy to be proven wrong!

Categories

Resources