[ROM][STOCK][FASTBOOT][OP6] Stock Fastboot ROMs for OnePlus 6 - OnePlus 6 Guides, News, & Discussion

Things are changing with the advent of project treble and seamless updates. OnePlus will no longer release ROMs flashable via stock recovery (with twrp is possible but not recommended). The updates will be done on the slot not used for example if you are using slot a the update will be installed on slot b and the slot b will be set as default. If you brick and you are in bootloop how you can restore the rom? You can't with Stock ROM you have, because the zip can be only installed via Update Engine, so what can you do? Flash a stock rom via fastboot. I have extracted all images from the stock zip and i have made a new zip with the Fastboot ROM with a flash-all.bat included. This will work only if your bootloader is unlocked. This will erase all your data and will wipe your internal storage.
HOW TO FLASH
Download the zip;
Unpack the zip in a folder;
Reboot the OnePlus 6 in fastboot mode (Power and volume-);
Connect the OnePlus 6 to PC;
Run flash-all.bat flasher you need;
Wait until the process end;
The phone will automatically reboot.
FLASHER ADVANCED GUIDE
flash-all-partitions-fastboot.bat : this .bat will flash all possible partitions through fastboot (Except persist) , there are some criticals partitions that can't be flashed through fastboot;
flash-only-persist.bat : this .bat will flash only persist partition in fastboot mode (This is good for people that have problems with sensor);
flash-all-partitions-recovery-criticals.bat : this .bat will boot the twrp and will flash criticals partitions, use this carefully;
flash-system-boot-vendor.bat : this .bat is the same of older flash-all.bat and so it will flash only vendor, system and boot;
flash-all-partitions.bat : this .bat will run flash-all-partitions-fastboot.bat , then flash-only-persist.bat and then flash-all-partitions-recovery-criticals.bat .
Now usually the one needed is only the first "flash-all-partitions-fastboot.bat" but if you are badly bricked i recommend to use flash-all-partitions.bat .
DOWNLOAD
All roms on AFH: https://www.androidfilehost.com/?w=files&flid=271877
All roms on Sourceforge: https://sourceforge.net/projects/fastbootroms/files/OnePlus 6/
MANUAL FLASH: Windows - OSX - Linux
If you want to manual flash these roms these are the commands (you need to extract images.zip before proceed)
Fastboot Partitions:
Code:
fastboot flash aop_a aop.img
fastboot flash aop_b aop.img
fastboot flash bluetooth_a bluetooth.img
fastboot flash bluetooth_b bluetooth.img
fastboot flash boot_a boot.img
fastboot flash boot_b boot.img
fastboot flash dsp_a dsp.img
fastboot flash dsp_b dsp.img
fastboot flash dtbo_a dtbo.img
fastboot flash dtbo_b dtbo.img
fastboot flash fw_4j1ed_a fw_4j1ed.img
fastboot flash fw_4j1ed_b fw_4j1ed.img
fastboot flash fw_4u1ea_a fw_4u1ea.img
fastboot flash fw_4u1ea_b fw_4u1ea.img
fastboot flash modem_a modem.img
fastboot flash modem_b modem.img
fastboot flash oem_stanvbk oem_stanvbk.img
fastboot flash qupfw_a qupfw.img
fastboot flash qupfw_b qupfw.img
fastboot flash storsec_a storsec.img
fastboot flash storsec_b storsec.img
fastboot flash system_a system.img
fastboot flash system_b system.img
fastboot flash vbmeta_a vbmeta.img
fastboot flash vbmeta_b vbmeta.img
fastboot flash vendor_a vendor.img
fastboot flash vendor_b vendor.img
fastboot flash LOGO_a LOGO.img
fastboot flash LOGO_b LOGO.img
If you need also persist partition, this is the command:
Code:
fastboot flash persist persist.img
Criticals Partitions, for these you need to boot the TWRP:
Code:
fastboot boot TWRP.img
When you are in TWRP you need to run these commands to push and flash all criticals partitions:
Code:
adb push abl.img /sdcard/abl.img
adb shell dd if=/sdcard/abl.img of=/dev/block/bootdevice/by-name/abl_a
adb shell dd if=/sdcard/abl.img of=/dev/block/bootdevice/by-name/abl_b
adb push cmnlib.img /sdcard/cmnlib.img
adb shell dd if=/sdcard/cmnlib.img of=/dev/block/bootdevice/by-name/cmnlib_a
adb shell dd if=/sdcard/cmnlib.img of=/dev/block/bootdevice/by-name/cmnlib_b
adb push cmnlib64.img /sdcard/cmnlib64.img
adb shell dd if=/sdcard/cmnlib64.img of=/dev/block/bootdevice/by-name/cmnlib64_a
adb shell dd if=/sdcard/cmnlib64.img of=/dev/block/bootdevice/by-name/cmnlib64_b
adb push devcfg.img /sdcard/devcfg.img
adb shell dd if=/sdcard/devcfg.img of=/dev/block/bootdevice/by-name/devcfg_a
adb shell dd if=/sdcard/devcfg.img of=/dev/block/bootdevice/by-name/devcfg_b
adb push hyp.img /sdcard/hyp.img
adb shell dd if=/sdcard/hyp.img of=/dev/block/bootdevice/by-name/hyp_a
adb shell dd if=/sdcard/hyp.img of=/dev/block/bootdevice/by-name/hyp_b
adb push keymaster.img /sdcard/keymaster.img
adb shell dd if=/sdcard/keymaster.img of=/dev/block/bootdevice/by-name/keymaster_a
adb shell dd if=/sdcard/keymaster.img of=/dev/block/bootdevice/by-name/keymaster_b
adb push xbl.img /sdcard/xbl.img
adb shell dd if=/sdcard/xbl.img of=/dev/block/bootdevice/by-name/xbl_a
adb shell dd if=/sdcard/xbl.img of=/dev/block/bootdevice/by-name/xbl_b
adb push xbl_config.img /sdcard/xbl_config.img
adb shell dd if=/sdcard/xbl_config.img of=/dev/block/bootdevice/by-name/xbl_config_a
adb shell dd if=/sdcard/xbl_config.img of=/dev/block/bootdevice/by-name/xbl_config_b
REMEMBER
"Invalid sparce file format at header magic" is not an error, you need to wait a bit when you see that string, just wait.
These ROMs can't be used to update or downgrade your phone but just to restore your phone, so don't use them to come back to oreo or to update from oreo to pie.
If you want to rebrand your phone from HydrogenOS to OxygenOS you can follow this guide: Rebrand Guide
If you want you can use also my tool to flash Factory Images, unlock bootloader, flash twrp or to understand if the device is recognized: https://toolaio.tk/
Thanks to @SaiBork for first time tested
If you got some problems like write error or no partition, check this: https://forum.xda-developers.com/showpost.php?p=76658555&postcount=34
DONATE LINK
If you want to support this and others my projects please consider making a donation, thanks.
​

This would've saved me 6 hours of my life trying to unbrick my 6 this morning. You are a savior. Reserved.

So how do we install the OTA update when we have twrp installed?..
Always through fastboot?...

will this erase internal storage?
---------- Post added at 07:17 PM ---------- Previous post was at 07:15 PM ----------
mikex8593 said:
This would've saved me 6 hours of my life trying to unbrick my 6 this morning. You are a savior. Reserved.
Click to expand...
Click to collapse
did this work for u?

cultofluna said:
So how do we install the OTA update when we have twrp installed?..
Always through fastboot?...
Click to expand...
Click to collapse
No, with Update Engine. With project treble the updates are installed from an Android app called Update Engine in the slot that you are not using, when you reboot the device after the update, the slot will be changed and you will have the update. The stock recovery is there only to wipe your memory if needed and there is no longer the recovery partition but the recovery is included in the boot partition.
Bradl79 said:
will this erase internal storage?
Click to expand...
Click to collapse
Yes, i added it on first post
If you get some errors write it here and i will help you to solve it

mauronofrio said:
No, with Update Engine. With project treble the updates are installed from an Android app called Update Engine in the slot that you are not using, when you reboot the device after the update, the slot will be changed and you will have the update. The stock recovery is there only to wipe your memory if needed and there is no longer the recovery partition but the recovery is included in the boot partition.
Yes, i added it on first post
Click to expand...
Click to collapse
so it pretty much puts it back to factory settings. So even with us being rooted and having a custom recovery, will we be able to get OTA's or will we have to wipe our phones on every update?

Bradl79 said:
will this erase internal storage?
---------- Post added at 07:17 PM ---------- Previous post was at 07:15 PM ----------
did this work for u?
Click to expand...
Click to collapse
I restored it via the unofficial twrp by flashing the stock zip in recovery, but it was a pain because the new modded version didn't support mtp and the original was extremely slow and didn't load with anything on the internal storage. It was a painful process with repeated failures and if I had this method, would've saved a lot of frustration. I will definitely try next time I brick, which I do a lot....
---------- Post added at 07:24 PM ---------- Previous post was at 07:23 PM ----------
Maybe I'll just take one for the team and intentionally brick to try for sure

mikex8593 said:
I restored it via the unofficial twrp by flashing the stock zip in recovery, but it was a pain because the new modded version didn't support mtp and the original was extremely slow and didn't load with anything on the internal storage. It was a painful process with repeated failures and if I had this method, would've saved a lot of frustration. I will definitely try next time I brick, which I do a lot....
---------- Post added at 07:24 PM ---------- Previous post was at 07:23 PM ----------
Maybe I'll just take one for the team and intentionally brick to try for sure
Click to expand...
Click to collapse
have for u to brick but that would be great to know if this works, b/c i don't think there has been any tests on it, would u be able to make a video of it too?

Bradl79 said:
have for u to brick but that would be great to know if this works, b/c i don't think there has been any tests on it, would u be able to make a video of it too?
Click to expand...
Click to collapse
Maybe in a week or so because I have a cold at the moment. I could probably do a video on my PC with no audio.

So we can just take the OTA when it drops like stock users?..
And how about root?
After any update we flash root through twrp?..
Sory for so.many questions but im on OP3T now and im planning to upgrade to OP6...
This A/B think is totally new for me..
Trying to clear things out...

Bradl79 said:
so it pretty much puts it back to factory settings. So even with us being rooted and having a custom recovery, will we be able to get OTA's or will we have to wipe our phones on every update?
Click to expand...
Click to collapse
If you make an update you will lose root and twrp, but if you run magisk manager before reboot after the update you can keep the root.
I forget to say that the latest TWRP have the support for Update Engine

Zip updated

mauronofrio said:
Zip updated
Click to expand...
Click to collapse
new links?

flash-all.bat dont works for me,
unzip, fastboot, start flash-all.bat > result: show me current folder and exit, after 1sec

uragan1987 said:
flash-all.bat dont works for me,
unzip, fastboot, start flash-all.bat > result: show me current folder and exit, after 1sec
Click to expand...
Click to collapse
Did you:
1 have unlocked bootloader
2 tyoe fastboot devices and get response

did unlock and flash twrp, did a try to install a clear system, now system wont boot and twrp crash at start after some second
looks like a bug at twrp, cause no system on phone

uragan1987 said:
did unlock and flash twrp, did a try to install a clear system, now system wont boot and twrp crash at start after some second
looks like a bug at twrp, cause no system on phone
Click to expand...
Click to collapse
Well you should be able to get to bootloader and fastboot devices
Have you tried that?

uragan1987 said:
flash-all.bat dont works for me,
unzip, fastboot, start flash-all.bat > result: show me current folder and exit, after 1sec
Click to expand...
Click to collapse
Sure that you have entered the correct path into cmd? If so and it still doesn't work, maybe follow the instructions of this post: https://forum.xda-developers.com/showpost.php?p=76632484&postcount=82, at least type the shown commands into cmd. These are, what the bat file includes, but now "manually".
If it still doesn't work you maybe have to install another adb version (like shown in the linked post).
But before, try it once more with @mauronofrio method and make sure that
- your phone is in fastboot mode
- the zip is unzipped to one new folder, which only includes the unzipped files
- and that you entered the correct path via cmd (if you are on windows).
- and wait... some files flashing need a while
- while that, don´t touch the display of the op6 (even not, when it is shown lock.... unlock bootloader - just wait)

thx Flying Fox, you push me to right way
this is inside bat:
flash-all.bat
Code:
@echo off
title Mauronofrio flashall :P
for %%f in (""CurrentDIR.bat"") DO @SET currDir_=%%~df%%~pf
echo.
echo Current Directory = %currDir_%
SET ANDROID_PRODUCT_OUT=%currDir_%
pause
cant see commands here for fastboot
at this script is only setup for ANDROID_PRODUCT_OUT
will be nice, to update script and include this code too:
https://forum.xda-developers.com/showpost.php?p=76632484&postcount=82

androidfilehost indicates its 2gb file...but downloadable file is 3.08gb...cant understand

Related

one S stuck

my friend have one s then he flash it with recovery for "one X " after that the phone wont boot only stuck on "hTC this build is for development purposes only do ...etc" and every time i reboot it it gives me the same message
also it says **TAMPERED** whats that mean ?
Ouch. You should have followed the directions to flashing recovery for the One S not X. But I guess you know that now. Tampered means the sky is going to swallow you up in 24 hours. I'd find cover.
Lolz...jk. tampered. Modded. Unlocked bootloader....don't worry about it. As far as getting out of your situation. Go to the Q&A section.
Sent back in time to find Marty.
boot into bootloader and flash the correct recovery..
after that flash a different ROM after doing a full factory reset. You should be fine
azzledazzle said:
boot into bootloader and flash the correct recovery..
after that flash a different ROM after doing a full factory reset. You should be fine
Click to expand...
Click to collapse
i flash the correct recovery and i tried factory reset it didnt work
flash a different ROM then, Chances are if the old owner flash recovery for a One X, he probably flashed a ROM for the One X too !
first off, let someone ok this before you do it as the one s may be different with erasing system than my N1 is, since it has no actual sdcard
you could also try
fastboot erase system
fastboot -w
before doing any fastboot flashing of recovery then rom
maybe even fastboot erase recovery after fastboot -w
have everything on one s sdcard before doing this
without a system wipe, sometimes old rom remnants are left behind and not overwritten when new rom flashes. also one time I had to erase system before recovery would flash
You have various options, depending on your current state, which is always tough to judge if not having the actual device.
You can
1. push system.img and boot.img via bootloader
Start the 1.53 RUU and then look in TEMP folder in a folder with current date, then in the subfolder you find rom.zip. Copy that to another place outside of TEMP.
Now unzip with winrar and copy system.img and boot.img to fastboot folder along with a proper custom recovery
Now flash the 3 images with
fastboot flash boot boot_signed.img
fastboot flash system system.img
fastboot flash recovery r2-modaco-recovery-clockwork-touch-ville.img
Here`s the custom recovery for you - http://minus.com/mIA3OFkYq/4
Now reboot with
fastboot reboot
OR
2. Restore my clean stock nandroid backup
Part 1 - add clockworkmod folder (in case you don`t have them yet)
Boote in recovery and in cmd navigate to fastboot folder
Now type:
adb shell
then
mkdir /sdcard/clockworkmod
then
mkdir /sdcard/clockworkmod/backup
then
mkdir /sdcard/clockworkmod/backup/stockbackup
Now we have the empty folders.
Part 2 - Nandroid push and restore
Now we push the single parts of my backup in clockworkmod/backup folder. Navigate to your fastboot folder in cmd and type:
adb push .android_secure.vfat.tar /sdcard/clockworkmod/backup/stockbackup
adb push boot.img /sdcard/clockworkmod/backup/stockbackup
adb push cache.ext4.tar /sdcard/clockworkmod/backup/stockbackup
adb push data.ext4.tar /sdcard/clockworkmod/backup/stockbackup
adb push nandroid.md5 /sdcard/clockworkmod/backup/stockbackup
adb push recovery.img /sdcard/clockworkmod/backup/stockbackup
adb push system.ext4.tar /sdcard/clockworkmod/backup/stockbackup
Now we have everything in sdcard/clockworkmod/backup/stockbackup
Now you can restore that backup in recovery.
http://minus.com/mquC9WDG6/4
Tip: If you are sure your data partition is fine, you can leave out the data.ext4.tar, but make sure you also delete the md5 of data.ext4.tar before in nandroid.md5. That way you would restore wiithout having data loss
good process and "command" info, even if you don't need to do all of it
especially for folks not real familiar with fastboot/adb
hope OP gets it working

ADB Command/HBOOT Changes in recent OTA enhancement for 4.1.2

So it has become prudent to me that I update this info to the general public within the home of our One SV. Most of you may already be aware of the recent OTA Enhancement that the k2_cl has been receiving or already received. I have just learned after trying some modifications within my device that some commands were changed. I have not been able to figure out what all commands have been changed however one that I am aware of and the very one I constantly use as a safety hazard on my own device is booting vice flashing while in fastboot usb. Originally you all may have known the command to be fastboot boot recovery recovery.img (as an example). Its common for people to flash being the command: fastboot flash recovery recovery.img. As for me I ALWAYS BOOT before I flash to insure it's integrity while operating on my device. Thank of it as running within a virtual window to dumb this down for the less understanding individuals. Back on track, this command has been changed. fastboot boot boot boot.img (as an example) no longer works. They changed the command to: fastboot -c "lge.kcal=0|0|0|x" boot customrecovery.img. That code functions respectively no different than as we would use to type: fastboot boot recovery customrecovery.img. Why they made such changes I am not sure. So be cautious of these changes. I made this thread to all who may come to learn about other changes with other commands and if so then please come back here and shar this knowledge as it will be VERY USEFUL TO US ALL. Thanks.
EDIT:
"fastboot boot" command DOESN'T work with the recent 4.1.2 OTA enhancement so you need to SPECIFY a kernel commandline to use "fastboot boot" command.
A list of commands with a quick summary on them.
/boot
This is the boot partition of your Android device, as the name suggests. It includes the android kernel and the ramdisk. The device will not boot without this partition. Wiping this partition from recovery should only be done if absolutely required and once done, the device must NOT be rebooted before installing a new one, which can be done by installing a ROM that includes a /boot partition.
/system
As the name suggests, this partition contains the entire Android OS, other than the kernel and the ramdisk. This includes the Android GUI and all the system applications that come pre-installed on the device. Wiping this partition will remove Android from the device without rendering it unbootable, and you will still be able to put the phone into recovery or bootloader mode to install a new ROM.
/recovery
This is specially designed for backup. The recovery partition can be considered as an alternative boot partition, that lets the device boot into a recovery console for performing advanced recovery and maintenance operations on it.
/data
Again as the name suggest, it is called userdata partition. This partition contains the user’s data like your contacts, sms, settings and all android applications that you have installed. While you are doing factory reset on your device, this partition will wipe out, Then your device will be in the state, when you use for he first time, or the way it was after the last official or custom ROM installation.
/cache
I hope you have some idea about cache, as you are expert on internet browsing. This is the partition where Android stores frequently accessed data and app components. Wiping the cache doesn’t effect your personal data but simply gets rid of the existing data there, which gets automatically rebuilt as you continue using the device.
/misc
This partition contains miscellaneous system settings in form of on/off switches. These settings may include CID (Carrier or Region ID), USB configuration and certain hardware settings etc. This is an important partition and if it is corrupt or missing, several of the device’s features will will not function normally.
usage: fastboot [ <option> ] <command>
commands:
update <filename> reflash device from update.zip​ flashall flash boot + recovery + system​ flash <partition> [ <filename> ] write a file to a flash partition​ erase <partition> erase a flash partition​ getvar <variable> display a bootloader variable​ boot <kernel> [ <ramdisk> ] download and boot kernel​ flash:raw boot <kernel> [ <ramdisk> ] create bootimage and flash it​ devices list all connected devices​ continue continue with autoboot​ reboot reboot device normally​ reboot-bootloader reboot device into bootloader​
options:
-w erase userdata and cache​ -s <serial number> specify device serial number​ -p <product> specify product name​ -c <cmdline> override kernel commandline​ -i <vendor id> specify a custom USB vendor id​ -b <base_addr> specify a custom kernel base address​ -n <page size> specify the nand page size. default:​
Edit
---------- Post added at 06:30 PM ---------- Previous post was at 06:21 PM ----------
V1sual1mpact said:
That code functions respectively no different than as we would use to type: fastboot boot recovery customrecovery.img.
EDIT:
"fastboot boot" command DOESN'T work with the recent 4.1.2 OTA enhancement so you need to SPECIFY a kernel commandline to use "fastboot boot" command.
Click to expand...
Click to collapse
The correct cmd to boot a recovery.img before flashing is :
Code:
fastboot boot recovery.img
NOT fastboot boot recovery recovery.img
:thumbup:
russellvone said:
Edit
---------- Post added at 06:30 PM ---------- Previous post was at 06:21 PM ----------
The correct cmd to boot a recovery.img before flashing is :
Code:
fastboot boot recovery.img
NOT fastboot boot recovery recovery.img
:thumbup:
Click to expand...
Click to collapse
Actually, the command I gave is also correct (it's based on optional command) . But thanks for the input. The command has always been the command which I used. However, since that OTA I can not use it anymore.
help
V1sual1mpact said:
Actually, the command I gave is also correct (it's based on optional command) . But thanks for the input. The command has always been the command which I used. However, since that OTA I can not use it anymore.
Click to expand...
Click to collapse
OK, so I'm a bit confused here....What would be the proper command line to actually flash custom recovery....I keep getting an unknown error message using fast flash recovery custom recovery.img...
Rename the recovery.img to recovery.img.
Code:
fastboot flash recovery recovery.img
http://forum.xda-developers.com/showthread.php?p=47471643
Sent from my C525c using XDA Premium 4 mobile app

Returning to stock, where can I find the stock image?

I need to warranty a phone but I need to turn it back to stock. I am using an older version of TWRP, I am guessing here but do I just download the factory image and flash it and I am done? It seems like everything I get when searching is geared towards the Pixel XL and using ADB rather than TWRP.
Thanks in advance.
Beacuse I part time as an internet troll, I have to chastise you for not reading threw this forum, because well that's why it's there, but hey we all can't use our Brian's all the time, but yes download the factory image for your phone Marlin for Pixel XL and Sailfish for Pixel unzip the file, make sure you have lastest usb drivers installed and click the flash all.bat.
Fastboot and flash factory image.
A wonderful guide: https://forum.xda-developers.com/pixel-xl/how-to/guide-how-to-unlock-root-flash-pixel-xl-t3507886
jerryhou85 said:
Fastboot and flash factory image.
A wonderful guide: https://forum.xda-developers.com/pixel-xl/how-to/guide-how-to-unlock-root-flash-pixel-xl-t3507886
Click to expand...
Click to collapse
why do I have to fastboot or ADB cant I just boot into twrp and flash factory image?
twilk73 said:
why do I have to fastboot or ADB cant I just boot into twrp and flash factory image?
Click to expand...
Click to collapse
I'm not a good developer so I cannot answer you that question, but on Google official page, it is recommended to use fastboot or adb to flash factory images...
twilk73 said:
why do I have to fastboot or ADB cant I just boot into twrp and flash factory image?
Click to expand...
Click to collapse
Because recovery and boot are sort of intermingled now. You would be writing over twrp at the same time you are trying to use it to flash.
Use the flashall bat file. If you want to save data edit out the -w from the bat file.
twilk73 said:
why do I have to fastboot or ADB cant I just boot into twrp and flash factory image?
Click to expand...
Click to collapse
I am on linux let me just get that out of the way.
So I used adb to fastboot the factory image but nothing happens
the file is in downloads and in the fastboot file. So I type cd Downloads, cd fastboot, fastboot sailfish-nmf260 it all looks good and you can tell adm is working but nothing happens on the phone.
I am current only able to get the phone into fastboot mode I dont know what I messed up but I can no longer even boot into TWRP.
I must have succesfully removed the twrp recovery because no i get the no command screen. If I hold power and press up I can get into the stock android recovery. Is there a way to install the factory image still? Or is the process still the same and I need to adb fastboot? I might need to just do the abd fastboot on a windows computer at work tomorrow.
twilk73 said:
I must have succesfully removed the twrp recovery because no i get the no command screen. If I hold power and press up I can get into the stock android recovery. Is there a way to install the factory image still? Or is the process still the same and I need to adb fastboot? I might need to just do the abd fastboot on a windows computer at work tomorrow.
Click to expand...
Click to collapse
Download the factory image you want here. Unzip the entire contents to the same folder fastboot is located in. Then boot the phone to the bootloader, then plug it in to you computer. Then, if you're using Linux, double click the flash-all.sh file that got unzipped to your fastboot folder. If you're using a Windows computer, double click on the flash-all. bat file instead of the flash-all.sh file. Then sit back and wait. That's about all there is to it. One note. If you want to save your data, open the script you're going to use in a text editor and remove the -w toward the end of the script (remember to save your changes). If you want the phone wiped clean and like new again, just leave it as is.
robocuff said:
Download the factory image you want here. Unzip the entire contents to the same folder fastboot is located in. Then boot the phone to the bootloader, then plug it in to you computer. Then, if you're using Linux, double click the flash-all.sh file that got unzipped to your fastboot folder. If you're using a Windows computer, double click on the flash-all. bat file instead of the flash-all.sh file. Then sit back and wait. That's about all there is to it. One note. If you want to save your data, open the script you're going to use in a text editor and remove the -w toward the end of the script (remember to save your changes). If you want the phone wiped clean and like new again, just leave it as is.
Click to expand...
Click to collapse
ive done these steps but its failing to work. This is exactly what I am doing.
1. Download factory image.
2. Extract factory image into fastboot file.
the fast boot file is in the dowloads folder so I type.
cd Downloads
cd fastboot
fastboot flash-all.sh
iv also tried fastboot the sailfish-nmf260.img and boot.img and flashall. Ive tried several different ways this is what happens no mater what I type.
usage: fastboot [ <option> ] <command>
commands:
update <filename> reflash device from update.zip
flashall flash boot, system, vendor and if found,
recovery
flash <partition> [ <filename> ] write a file to a flash partition
erase <partition> erase a flash partition
format[:[<fs type>][:[<size>]] <partition> format a flash partition.
Can override the fs type and/or
size the bootloader reports.
getvar <variable> display a bootloader variable
boot <kernel> [ <ramdisk> [ <second> ] ] download and boot kernel
flash:raw boot <kernel> [ <ramdisk> [ <second> ] ] create bootimage and
flash it
devices list all connected devices
continue continue with autoboot
reboot reboot device normally
reboot-bootloader reboot device into bootloader
help show this help message
options:
-w erase userdata and cache (and format
if supported by partition type)
-u do not first erase partition before
formatting
-s <specific device> specify device serial number
or path to device port
-l with "devices", lists device paths
-p <product> specify product name
-c <cmdline> override kernel commandline
-i <vendor id> specify a custom USB vendor id
-b <base_addr> specify a custom kernel base address.
default: 0x10000000
-n <page size> specify the nand page size.
default: 2048
-S <size>[K|M|G] automatically sparse files greater
than size. 0 to disable
Click to expand...
Click to collapse
On the phone nothing happens. It appears that all I am getting is a list of options but none of the options seem to be working either.
I might add that the fastboot folder I am using was downloaded back when I installed twrp is it possible my fastboot file doesnt have the correct files to get the job done?
twilk73 said:
ive done these steps but its failing to work. This is exactly what I am doing.
1. Download factory image.
2. Extract factory image into fastboot file.
the fast boot file is in the dowloads folder so I type.
cd Downloads
cd fastboot
fastboot flash-all.sh
iv also tried fastboot the sailfish-nmf260.img and boot.img and flashall. Ive tried several different ways this is what happens no mater what I type.
On the phone nothing happens. It appears that all I am getting is a list of options but none of the options seem to be working either.
I might add that the fastboot folder I am using was downloaded back when I installed twrp is it possible my fastboot file doesnt have the correct files to get the job done?
Click to expand...
Click to collapse
Have you tried putting phone in fastboot mode and doubble click the flash all.sh file? That's how it is done on Windows.
Sent from my Google Pixel using XDA Labs
Sgace said:
Have you tried putting phone in fastboot mode and doubble click the flash all.sh file? That's how it is done on Windows.
Sent from my Google Pixel using XDA Labs
Click to expand...
Click to collapse
Basically yes. But with linux you cant just double click. So in terminal I typed "cd Download, cd fastboot, fastboot flash-all.sh" that command will attempt to launch that file.
I feel like the issue is with adb on my laptop I tried making sure its updated but i got nothing so ill try to do it on a work computer when I get free time.
Its pretty crappy right now because I am without a phone but heck I pet the dog today during lunch instead of reading the news feed off my phone so I guess the dog is happy lol.
twilk73 said:
Basically yes. But with linux you cant just double click. So in terminal I typed "cd Download, cd fastboot, fastboot flash-all.sh" that command will attempt to launch that file.
I feel like the issue is with adb on my laptop I tried making sure its updated but i got nothing so ill try to do it on a work computer when I get free time.
Its pretty crappy right now because I am without a phone but heck I pet the dog today during lunch instead of reading the news feed off my phone so I guess the dog is happy lol.
Click to expand...
Click to collapse
I don't think you can flash it with fastboot. In Windows, at the command prompt, you just type flash-all.bat and the batch file will run. It contains all the necessary fastboot commands. Perhaps that's where you're going wrong. Try just typing flash-all.sh. Leave the fastboot out.
twilk73 said:
Basically yes. But with linux you cant just double click. So in terminal I typed "cd Download, cd fastboot, fastboot flash-all.sh" that command will attempt to launch that file.
I feel like the issue is with adb on my laptop I tried making sure its updated but i got nothing so ill try to do it on a work computer when I get free time.
Its pretty crappy right now because I am without a phone but heck I pet the dog today during lunch instead of reading the news feed off my phone so I guess the dog is happy lol.
Click to expand...
Click to collapse
Try this for sailfish (fix accordingly if marlin, username of course is common sense, if still confused, you shouldn't be using linux)
I build and use debian sid
Code:
cd /home/username/Downloads
tar xvf sailfish-opr3.170623.008-factory-bb8bb3a3.zip -C /home/username
cd /home/username/sailfish-opr3.170623.008
tar xvf image-sailfish-opr3.170623.008.zip
cd /home/username/sailfish-opr3.170623.008
./flash-all.sh
If you need the latest adb/fastboot name it something like google.sh
Code:
#!/bin/bash
wget https://dl.google.com/android/repository/platform-tools-latest-linux.zip
unzip \platform-tools-latest-linux.zip
cp platform-tools/adb /usr/bin/adb
cp platform-tools/fastboot /usr/bin/fastboot
piperx said:
Try this for sailfish (fix accordingly if marlin, username of course is common sense, if still confused, you shouldn't be using linux)
I build and use debian sid
Code:
cd /home/username/Downloads
tar xvf sailfish-opr3.170623.008-factory-bb8bb3a3.zip -C /home/username
cd /home/username/sailfish-opr3.170623.008
tar xvf image-sailfish-opr3.170623.008.zip
cd /home/username/sailfish-opr3.170623.008
./flash-all.sh
If you need the latest adb/fastboot name it something like google.sh
Code:
#!/bin/bash
wget https://dl.google.com/android/repository/platform-tools-latest-linux.zip
unzip \platform-tools-latest-linux.zip
cp platform-tools/adb /usr/bin/adb
cp platform-tools/fastboot /usr/bin/fastboot
Click to expand...
Click to collapse
Sorry I wish I could try this. I had access to a windows computer at work and I was able to get everything done. After doing it at work I have a feeling I wasnt placing the files in the correct folder together to get it to start the update. It can be hard doing this on something other than windows for a dummy like me because most of the tutorials for things like this seem to be windows oriented. Regardless its done. I couldnt lock the boot loader on the windows computer though oddly but no big deal because I can do it on my laptop.
Thanks for all the help guys.

How to extract recovery.img from the ASUS firmware? [7.0/8.0] [ZE552KL/ZE520KL]

Hello guys, some time ago this device had more support from developers, someone could extract the recovery.img in order to keep it updated.
I wonder if anyone would know what the procedure is for extracting.
My device is the ZE552KL (Z012D).
I followed the steps in this tutorial, however, I did not succeed: https://tinyurl.com/yd3w4pxa
I followed all the steps and tried to extract recovery.img from the Zenfone 3 ZE552KL (Z012D) Asus firmware, however, there was a problem after applying the applypatch directive.
Error: patch boot.img: Only patches to EMMC targets are supported.
And I can not solve it.
install-recovery.sh (original extraction): https://hastebin.com/lupoqovila.bash
install-recovery.sh (change): https://hastebin.com/ofuqofezat.bash
Apllypatch directive used at the prompt: applypatch -b recovery-resource.dat boot.img recovery.img 28e9d4088f51c9dafb9189eb15f061c78be55a57 18791676 4a9f7c48e01aed3a46ac8d06618239dff9834caf: recovery-from-boot.p
Error:
https://imgur.com/a/JWfyr
I also asked for help at Zentalk, but so far no one has spoken.
https://www.asus.com/zentalk/tw/thread-147621-2-1.html
Please, I'll be grateful if anyone can help.
The recovery partition is #59, therefore to back it up you can use terminal emulator and type;
Su
dd if=/dev/block/mmcblk0p59 of=/sdcard/recovery.img
To flash, go to fastboot and type
Fastboot flash recovery recovery.img
Fastboot reboot
You need root for all this. You can convert the recovery image to be flashable via recovery but it only works with twrp, not stock.
wang1chung said:
The recovery partition is #59, therefore to back it up you can use terminal emulator and type;
Su
dd if=/dev/block/mmcblk0p59 of=/sdcard/recovery.img
To flash, go to fastboot and type
Fastboot flash recovery recovery.img
Fastboot reboot
You need root for all this. You can convert the recovery image to be flashable via recovery but it only works with twrp, not stock.
Click to expand...
Click to collapse
Thanks for taking note of my question, but what I really need to know is about recovery stock. It would not be logical for my use to perform custom recovery extraction, since it is already found in the .img format from the developer's available links (TWRP).
Following the tutorial steps of the links I indicated it is possible to make a kind of compilation using the official OTA file, processing on the device itself to generate the file recovery.img stock.
Again thank you for trying to help, any and all help is very welcome.
+1
Can someone post here stock recovery.img for ze520kl newest oreo firmware?
I'd like to know how to do this as well. I went through a lot of trouble to get Oreo installed after rooting and installing TWRP on my phone running Nougat, ended up having to go back to stock and install updates incrementally. As you noted, root is required to save the stock recovery.img, but since my device is not rooted now I can't root without installing TWRP first. That would put me in the same situation as the OP. The google translate of the link posted by the OP is a bit hard to understand, can someone else give an english explanation of how to extract recovery.img from firmware zip?
TIA
Update: I managed to follow the instructions in the OP's link, ended up with a similar applypatch command as he did and also encountered the same error with running the command over adb. I'm not sure if those instructions are for all asus devices, the one in the link is Asus P028 (Zenpad 10)
applypatch -b recovery-resource.dat boot.img recovery.img f448eeec56d4d87173858cd7aec25c36a7dfaaa7 18736380 9ebabd3eb6a59cfcaf0f4f048e2d8d6d870d7924:recovery-from-boot.p
ktl20 said:
Can someone post here stock recovery.img for ze520kl newest oreo firmware?
Click to expand...
Click to collapse
Here
Error
I keep getting
/sbin/sh: f448eeec56d4d87173858cd7aec25c36a7dfaaa7: not found
whenever i go through this. what am i doing wrong? T_T
wang1chung said:
The recovery partition is #59, therefore to back it up you can use terminal emulator and type;
Su
dd if=/dev/block/mmcblk0p59 of=/sdcard/recovery.img
To flash, go to fastboot and type
Fastboot flash recovery recovery.img
Fastboot reboot
You need root for all this. You can convert the recovery image to be flashable via recovery but it only works with twrp, not stock.
Click to expand...
Click to collapse
when I type su and enter, on adb shell show error "/system/bin/sh: su: not found". my device is unrooted. I did this for boot and recovery backup before rooting. I'm using Zenfone x00rd (Live L1)

20e semi stock fastboo/twrp flashable images

Hey guys,
This is for people who already unlocked the bootloader!!
Since there hasn't been any flashable images via twrp or fastboot, I have decided to create one for the stock 20e. Now it's semi stock because the twrp is included with the boot image I uploaded. I'm doing just 20e because im too lazy to go back and forth firmwares just to upload different versions of fw of stock.
You can flash them via fastboot or twrp.
To access fastboot you need to be rooted in your custom rom or stock:
1. Use terminal or adb shell and do these commands
Code:
Su
dd if=/dev/zero of=/dev/block/bootdevice/by-name/laf_a
Then reboot and hold the vol+ button while it's plugged into the PC
Don't worry about losing download mode on slot_a cause the other slot will still have it and you can switch to the other slot via fastboot or twrp then you can have download mode
To flash via fastboot:
Code:
Fastboot flash boot_a twrpboot_a.img
Fastboot flash system_a system_a.img
Fastboot flash vendor_a vendor_a.img
To flash via twrp:
1. Move these files to your internal sd or external.
2. Get into recovery mode and then hit install
3. Tap on select image and find the image files
4. Then flash them one by one.
5. Format data and reboot.
https://drive.google.com/folderview?id=1-1tRMeDK7sVzta9kKhAvfVF2B9XZu2ki
If you want to help out and upload the other firmwares, here are the steps:
1. Be on the firmware you want to make the image files for.
2. Make sure you are rooted!!
3. Use terminal from the play store or use adb shell
4. And do the following for each partition.
A. First SU in shell then
For system-
Code:
dd if=/dev/block/bootdevice/by-name/system_a of=/sdcard/system_a.img
For boot:
Code:
dd if=/dev/block/bootdevice/by-name/boot_a of=/sdcard/boot_a.img
For vendor:
Code:
dd if=/dev/block/bootdevice/by-name/vendor_a of=/sdcard/vendor_a.img
Then upload them to Google drive or wherever and share them if you can.
Does it work on G710EM?
Resync said:
Does it work on G710EM?
Click to expand...
Click to collapse
In theory it should.
can you upload the twrpboot for ulm21d?
Can you make the v35 twrp , thanks

Categories

Resources