Question about A/B Flashing Commands - General Topics

Suppose we want to flash the boot.img file to the A and B Slot of the boot partition. So the general command that I use is:
fastboot flash boot_a boot.img
fastboot flash boot_b boot.img
Click to expand...
Click to collapse
However, nowadays, I am coming across this command:
fastboot flash boot_ab boot.img
Click to expand...
Click to collapse
So do both the commands perform the same functionality? In other words, would the 'fastboot flash boot_ab boot.img' command flash the boot.img file to both the A and B partition?

As far as I know, yes. The official documentation doesn't tell me anything about it ("fastboot -h"/"fastboot flash -h")

Related

Problems getting back to stock from boot loop after trying to root.

First I unlocked the bootloader, and then I tried to use chainfire's root method by flashing the boot-to-root-img through fastboot. The phone will no longer boot to system and I cant seem to get google's factory image to install via fastboot. The flash-all would only flash the bootloader and radio, but would fail after that. I also cannot manually flash the stock system.img file. I get an error that reads " remote: data too large ". Not sure how to get out of this so any help would be GREATLY appreciated.
Did you manually flash the boot and system.img to each slot?
fastboot flash boot_a boot.img
fastboot flash boot_b boot.img
Fastboot flash system_a system.img
fastboot flash system_b system_other.img
Use these commands assuming your boot slot is slot_a...if your boot slot is slot_b then use
Fastboot flash system_a system_other.img
fastboot flash system_b system.img
Hope this helps!!!
You need to update your fastboot version....then the system file will flash for you. Only the newest supports large files.
Sent from my Pixel using Tapatalk
maulich said:
You need to update your fastboot version....then the system file will flash for you. Only the newest supports large files.
Click to expand...
Click to collapse
Good call...totally forgot about that man
BakedTator said:
Good call...totally forgot about that man
Click to expand...
Click to collapse
Thanks to both of you! I actually did get my phone to boot up just before you replied by flashing to boot.img to both slots. Just installed TWRP and flashed superSU after that to get root. All is well now!

I cant flash userdata.img?

Im reverting back to android 6.0 for my k1
But when i go to flash userdata its says userdata isnt found
And i look in the zip and it wasnt there so i downloaded again and it still wasnt there any suggestions
1 more thing nvidias instrucrions say to
Fastboot flash recovery recovery.img
fastboot flash boot boot.img
fastboot flash system system.img
fastboot flash userdata userdata.img
fastboot flash staging blob
And rhats it do i reboot after blob?
Cause someone elses tutorial says to
fastboot flash recovery {dir}/recovery.img
fastboot flash boot {dir}/boot.img
fastboot flash system {dir}/system.img
fastboot flash userdata {dir}/userdata.img
fastboot flash staging {dir}/blob
fastboot flash dtb {dir}/tegra124-tn8-p1761-1270-a04-e-battery.dtb
Tjeres an extra command?
Which do i use?
Thx
Iceek1 said:
Im reverting back to android 6.0 for my k1
But when i go to flash userdata its says userdata isnt found
And i look in the zip and it wasnt there so i downloaded again and it still wasnt there any suggestions
1 more thing nvidias instrucrions say to
Fastboot flash recovery recovery.img
fastboot flash boot boot.img
fastboot flash system system.img
fastboot flash userdata userdata.img
fastboot flash staging blob
And rhats it do i reboot after blob?
Cause someone elses tutorial says to
fastboot flash recovery {dir}/recovery.img
fastboot flash boot {dir}/boot.img
fastboot flash system {dir}/system.img
fastboot flash userdata {dir}/userdata.img
fastboot flash staging {dir}/blob
fastboot flash dtb {dir}/tegra124-tn8-p1761-1270-a04-e-battery.dtb
Tjeres an extra command?
Which do i use?
Thx
Click to expand...
Click to collapse
Don't worry, that one isn't included in the latest Nougat builds as well and they still flash normally.
Just proceed without that

How to flash stock on both partitions?

Tried All in One Tool a while ago, but after booting up after flash, and the flashing again it still flashed to partition b.
I forgot. I have done it. Flash with Tool All in One, flash TWRP, change partition in TWRP, reboot to fastboot and flash stock again with Tool All in One, and flash TWRP again.
https://forum.xda-developers.com/android/software/tool-tool-one-driversunlocktwrpfactory-t3358711
andacro said:
I forgot. I have done it. Flash with All in One Tool, flash TWRP, change partition in TWRP, reboot and flash stock again with All in One Tool.
Click to expand...
Click to collapse
In future you can also run this command to change slot in fastboot, fastboot --set-active=a or fastboot --set-active=b depending which slot you need.
liam_davenport said:
In future you can also run this command to change slot in fastboot, fastboot --set-active=a or fastboot --set-active=b depending which slot you need.
Click to expand...
Click to collapse
Great! Thanks a lot

Development Manually update firmware (fastboot commands) - Moto G Stylus (2021)

All,
I successfully updated my Moto G Stylus (2021) [RETUS / XT2115-1] with the following fastboot commands:
fastboot oem fb_mode_set
fastboot flash partition gpt.bin
fastboot flash bootloader bootloader.img
fastboot flash vbmeta vbmeta.img
fastboot flash radio radio.img
fastboot flash bluetooth BTFM.bin
fastboot flash dsp dspso.bin
fastboot flash logo logo.bin
fastboot flash boot boot.img
fastboot flash dtbo dtbo.img
fastboot flash recovery recovery.img
fastboot flash super super.img_sparsechunk.0
fastboot flash super super.img_sparsechunk.1
fastboot flash super super.img_sparsechunk.2
fastboot flash super super.img_sparsechunk.3
fastboot flash super super.img_sparsechunk.4
fastboot flash super super.img_sparsechunk.5
fastboot flash super super.img_sparsechunk.6
fastboot flash super super.img_sparsechunk.7
fastboot flash super super.img_sparsechunk.8
fastboot flash super super.img_sparsechunk.9
fastboot flash super super.img_sparsechunk.10
fastboot flash super super.img_sparsechunk.11
fastboot flash super super.img_sparsechunk.12
fastboot flash super super.img_sparsechunk.13
fastboot flash super super.img_sparsechunk.14
fastboot flash super super.img_sparsechunk.15
fastboot flash super super.img_sparsechunk.16
fastboot erase carrier
fastboot erase userdata [optional]
fastboot erase metadata
fastboot erase ddr
fastboot flash boot <name of magisk patched boot file.img> [optional]
fastboot oem fb_mode_clear
fastboot reboot
I downloaded the latest firmware from the Moto Rescue and Smart Assistant PC application.
Enjoy!
Caution: The flash commands can vary from one Software Channel to another, and the number sparsechunk(s) can change with the android versions.
You should always use the flashfile.xml or service.xml to get the flash commands.
Several ways to do that.
Online FlashFile Converter
Write a Batch File
XML to Bat Converter Tool for Windows
More here
[Guide] Using Fastboot.exe with Motorola devices
Guide: Using Fastboot.exe with Motorola Devices If your device has its own section please post in that section. You can ping me with @sd_shadow MediaTek or Qualcomm Chip? Do I have a MediaTek Device? see post #26 Info: If you have a MediaTek...
forum.xda-developers.com
sd_shadow said:
.....
You should always use the flashfile.xml or service.xml to get the flash commands.
.....
Click to expand...
Click to collapse
I like using Notepad++ to view a flashfile.xml from the extracted firmware. Right-click and open with, it formats it very nicely.
peajul said:
I successfully updated my Moto G Stylus (2021) [RETUS / XT2115-1] with the following fastboot commands: ...
Click to expand...
Click to collapse
Just curious, this was an actual "update"? OTA? Or did you just refresh a current install? Do you have a version number? I'm gonna plug-in to the MRSA app as soon as I can get my hands on my lady's phone, but I'm asking so I can be prepared for what I might find.
peajul said:
All,
I successfully updated my Moto G Stylus (2021) [RETUS / XT2115-1] with the following fastboot commands.....
Click to expand...
Click to collapse
Your list and order does match perfectly (except for the added Magisk-patched bootloader) with the flashfile.xml in my downloaded copy of XT2115-1_MINSK_RETUS_10_QPC30.Q4-31-26-1.
. . . I'm needing to reflash my lady's Stylus 2021, is why I went so far as to check in detail. Apparently I screwed up in manually copying the blocked numbers database from an older version of Android to her new XT2115-1. Something in Android 10 just doesn't like what I did (same thing I've done between Nougat and Pie with no problems at all). And then I further mangled the situation trying to fix it.

Question I do everything correctly to root but it keep booting in to the bootloader

My steps
1. oem unlock and unlock bootloader with the command
2. get the files from lmsa
3. Patch boot.img using magisk
4. Flash boot.img and vbmeta.img
5. Reboot using fastboot reboot
It should boot me normaly but it boots in to the boot loader
What device are you talking about ?
f1tm0t said:
What device are you talking about ?
Click to expand...
Click to collapse
Tab p11 4gig
Return the stock boot.
I can't tell you anything specific about this device. I own other.
If there is TWRP for your version of Android, flash Magisk.zip from TWRP.
f1tm0t said:
Return the stock boot.
I can't tell you anything specific about this device. I own other.
If there is TWRP for your version of Android, flash Magisk.zip from TWRP.
Click to expand...
Click to collapse
Threr is no twrp sadly
blocky3321 said:
My steps
1. oem unlock and unlock bootloader with the command
2. get the files from lmsa
3. Patch boot.img using magisk
4. Flash boot.img and vbmeta.img
5. Reboot using fastboot reboot
It should boot me normaly but it boots in to the boot loader
Click to expand...
Click to collapse
who told you to flash vbmeta.img?
You should flash patched_boot.img in fastbootd
You need to edit out vbmeta.img / vbmeta_system.img to actually disable verification. Change the byte at offset 123 from 0x00 to 0x03.
Another way is to use the following command when flashing vbmeta. You may need to use a relatively newer version of fastboot binary to get it work.
Code:
fastboot flash --disable-verity --disable-verification vbmeta vbmeta.img
mingkee said:
who told you to flash vbmeta.img?
You should flash patched_boot.img in fastbootd
Click to expand...
Click to collapse
I tried it i flashed patched boot.img only in fastbootd still boots me in to the bootloader
LSS4181 said:
You need to edit out vbmeta.img / vbmeta_system.img to actually disable verification. Change the byte at offset 123 from 0x00 to 0x03.
Another way is to use the following command when flashing vbmeta. You may need to use a relatively newer version of fastboot binary to get it work.
Code:
fastboot flash --disable-verity --disable-verification vbmeta vbmeta.img
Click to expand...
Click to collapse
now it only boot in to the bootloader earlier it would boot normaly if i did factory treset in recovery mode
blocky3321 said:
now it only boot in to the bootloader earlier it would boot normaly if i did factory treset in recovery mode
Click to expand...
Click to collapse
Which Magisk version did you use? From what I can tell any official Magisk version should work.
I haven't really tested the recent builds of vvb2060's Alpha or huskydg's Delta... so if you're using these versions I can't really help you much...
Additionally, you need to check which slot you are now, and through fastbootd check which slot actually has system, vendor and such. Normally the super partition only has enough size for one slot. You may have entered a wrong slot that doesn't have usable system.
blocky3321 said:
My steps
1. oem unlock and unlock bootloader with the command
2. get the files from lmsa
3. Patch boot.img using magisk
4. Flash boot.img and vbmeta.img
5. Reboot using fastboot reboot
It should boot me normaly but it boots in to the boot loader
Click to expand...
Click to collapse
Getting Started: What's Your Device ?
Tab p11 4gig
Device->settings->About : Model & Hardware -> Lenovo ??? (Tb-j606f,TB-J616F...) In your case stiker on box or on back.
mingkee said:
who told you to flash vbmeta.img?
Click to expand...
Click to collapse
???

Categories

Resources