yashsingh1/xdaforums huggingface dataset:
[Moto Z2 Force  Guides, News, & Discussion] xdabubba14:
Missing file(s) for Verizon/script bug?

When I run the script on my Verizon Z2 it makes it all the way through, but the 6th-last command is asking to flash a file that does not exist!

There are two files named with "oem": (oem.img_sparsechunk.0 and oem.img_sparsechunk.1), but not as shown below, and these two files are -not- referred to at all in the script!

FYI, I'm using: "NASH_VERIZON_ODXS27.109-34-17_subsidy-DEFAULT_regulatory-DEFAULT_CFC.xml"

Here's the last part of the log:

----

c:\MotoZ2_tools>fastboot flash oem oem.img

error: cannot load 'oem.img': No such file or directory

c:\MotoZ2_tools>fastboot erase carrier

erasing 'carrier'...

OKAY [ 0.000s]

finished. total time: 0.000s

c:\MotoZ2_tools>fastboot erase ddr

erasing 'ddr'...

OKAY [ -0.000s]

finished. total time: -0.000s

c:\MotoZ2_tools>fastboot oem fb_mode_clear

...

OKAY [ -0.000s]

finished. total time: -0.000s

c:\MotoZ2_tools>fastboot -w

wiping userdata...

Erase successful, but not automatically formatting.

File system type raw not supported.

erasing 'userdata'...

OKAY [ 0.250s]

finished. total time: 0.250s

c:\MotoZ2_tools>fastboot reboot-bootloader

rebooting into bootloader...

OKAY [ 0.000s]

finished. total time: 0.000s

c:\MotoZ2_tools>

----
[Moto Z2 Force  Guides, News, & Discussion] 41rw4lk:
The flashall in the utilities.zip is intended for TMO/Sprint, there is a little variance between ATT and Verizon obviously. You can use this xml to batch convertor to create your own flashall from the xml in your firmware.
[Moto Z2 Force  Guides, News, & Discussion] Manuel Marta:
can anyone provide stock recovery for xt1789-03 sprint variant because i tried to flash twrp and bricked the phone and then flashed stock rom now im completely stock but with no recovery.img
[Moto Z2 Force  Guides, News, & Discussion] Uzephi:
There was is no recovery.img. The recovery is in boot.
[Moto Z2 Force  Guides, News, & Discussion] Manuel Marta:
But i cant boot to recovery it says no command
[Moto Z2 Force  Guides, News, & Discussion] Uzephi:
That's Motorola stock recovery, you have to press either volume up and power or volume down and power, I forgot. I haven't used stock recovery I'm awhile
[Moto Z2 Force  Guides, News, & Discussion] 41rw4lk:
To add to what Uzephi said, when you boot to stock recovery you get a 'splash screen' if you will and it says no command, just hit the vol dwn btn and your recovery options will appear.
[Moto Z2 Force  Guides, News, & Discussion] Manuel Marta:
what does btn mean??

i already pressed volume down and up and even power but nothing appears
[Moto Z2 Force  Guides, News, & Discussion] Rukbat:
Hmmmm.....

btn means button.

[MENTION=4604067]Uzephi[/MENTION] - you said (back in post #1, that the bootloader has to be unlocked - then provided AT&T and Verizon ROMs. Their bootloaders can't be unlocked (if I'm wrong, please tell me how). The current ROM level should flash without unlocking the bootloader, though. (Oh, and you said [in post #2] "Over 4GB of RAM." In most Z2s, that's all you have. [In any box running Windows or Linux you probably have at least 8GB], so, after 46 years of developing software, I'm lost.)
[Moto Z2 Force  Guides, News, & Discussion] Uzephi:
I posted them in case you could flash current or upgrade with locked BL. I personally haven't tried and don't support flashing firmware unless unlocked.

Over 4GB of ram was for your system, not phone. I assumed I could leave that identifier out, but I guess some think phone. The reason is because if you don't have over 2GB free ram on your PC, it might use your page file and if you have that little ram, you are most likely using a HDD which can make the flash process take longer than 30+ minutes. Most newer custom built PCs have 8GB or more. Some Dell/HP prebuilts, especially ones a few years old, have about 4GB of ram... Some laptops made 2015 and older also have less than 8GB of ram.
[Moto Z2 Force  Guides, News, & Discussion] Rukbat:
30+ minutes? Once I get this thing torn up, I'm going to have to see why it takes even half that. I've flashed phones with fastboot before, and even restarting the bootloader after each file (some firmware installs ping the phone for a delay, and that's not a good practice - I've bricked more than one phone doing that) doesn't make it take that long. I just hope that flashing the stock ROM works after playing with it. I plan to boot twrp.img first, to see if it does anything. (As long as it doesn't eat the bootloader, a long press on the power button should fix any problems if it doesn't work.) (As soon as A Terrible Thing sends me the unlock code.)
[Moto Z2 Force  Guides, News, & Discussion] Uzephi:
It only takes that long if you don't have enough free ram to store the file in ram when flashing. Edit: on the flashing PC. I personally ran into this on my old PC when one of my 4GB sticks failed and went from 8 to 4 GB until I could buy another set. It only would be affected if you flashed an unofficial or unparsed system image, meaning the image you're trying to flash is over 4 GB
[Moto Z2 Force  Guides, News, & Discussion] Rukbat:
Ahhh, okay. That's one phone I've never flashed, a Lenovo (flashed a lot of Motorolas, back when Motorola was making them), so I'm talking through my hat so far. We'll see in a couple of days.

(I wonder what extracting boot.img and letting Magisk modify it, then putting the modified version back into the mix, would do. Brick? Or root? I may get brave enough to find out.)
[Moto Z2 Force  Guides, News, & Discussion] Uzephi:
On a locked BL, it won't flash it. I don't even know if it would boot it tbh
[Moto Z2 Force  Guides, News, & Discussion] Rukbat:
I'll let you know. Just booting TWRP would be handy. And booting a rooted boot.img would be nice. More work every time, but I've worked with just twrp.img before and I will again if I have to. (I knew, going in, that AT&T would do something like this - but for $100? What the heck? I doubt it'll be my daily driver, but I may find out some things. [I spent 2 years on one job being told "you can't do that" - then doing it. I don't mind trying, as long as I don't hard-brick it. I don't have a JTAG, I'm not buying one, and turning a phone so new that I haven't torn the shrink wrap on it yet into a paperweight would be a shame.])
[Moto Z2 Force  Guides, News, & Discussion] lchiu7:
Phone restarts to Fastboot mode

I see this thread hasn't been too active lately so I presume most people have been happy with their flashing.

I was too but recently I started to see this strange behaviour. I needed to restart my phone and it hung on the Motorola logo for a while and then ended up on the Fastboot screen. I pressed Start to restart the phone and it went back there. Several tries had the same result.

Since the phone has been backed up I tried a factory refresh from Fastboot and after a couple of tries the phone rebooted normally and no data was lost.

All was well for a month or so and I had to reboot again and again ended in Fastboot mode. This time after a couple of retries the phone eventually booted normally.

This is a Sprint phone of course and locked to Sprint. I flashed the retail to return to stock and then flashed the patches to unlock it from Sprint. That appeared to go very well and I have been using since January this year. It was only a month ago that this problem occurred and it still remains. If I reboot the phone it will go into Fastboot mode and I have to boot a couple of times to back to normal.

I might try a complete reflash, get all the latest updates (I keep getting prompted for a Nov 2018 update) and then install custom recovery, Magisk etc.
[Moto Z2 Force  Guides, News, & Discussion] 41rw4lk:
In bootloader mode issue 'fastboot oem fb_mode_clear' w/o quotes, 'fastboot reboot bootloader', and 'fastboot oem fb_mode_clear' again. Sometimes after flashing it doesn't clear so you end up rebooting to bootloader. I'm not sure what would make it reboot to bootloader just out of the blue, but I know it isn't uncommon for it to happen after flashing. The solution is simple though, just follow above. Might check for sticky or damaged buttons if the problem persist.
[Moto Z2 Force  Guides, News, & Discussion] lchiu7:
Thanks. Next time it happens what you are saying is connect the phone to my PC and get into fastboot mode from the PC and issue those commands?

Buttons seem fine on the phone.
[Moto Z2 Force  Guides, News, & Discussion] 41rw4lk:
You can issue them now if you like. All it does it clear the flag that sets reboots to bootloader. When you flash firmware it toggles it on so that any reboots go back to the bootloader in case there are still things to be done, once it's done it usually toggles it back off. Sometimes that doesn't happen, or it doesn't clear it, etc. You can manually toggle it off by issuing the commands I posted and you should reboot to OS normally.
[Moto Z2 Force  Guides, News, & Discussion] tonochito:
what i am missing? i follow steps and it remains on waiting for device...
[Moto Z2 Force  Guides, News, & Discussion] Uzephi:
If it says waiting for device, then it isn't in bootloader or your PC doesn't recognize it in bootloader.
[Moto Z2 Force  Guides, News, & Discussion] tonochito:
This is the part that i have for doing rooting and all that stuff... There is the last update and of course mine is rooted, the annoying message of the update drives me nuts. So i am forced to restore back to stock and then again root, but now it' s detecting it but it just reboot the device on bootloader again, been on this like 15 minutes... I was hoping that somebody would just make a new rom with that update and be painless but seems nobody has done it, because it will be way easier just to install the rom using a TWRP, than reflashing the entire system for an stupid security update.

Or might be Windows 10, i had to reinstall the entire system on my PC and CMD is not opening anymore from the ADB folder... Just PowerShell
[Moto Z2 Force  Guides, News, & Discussion] Uzephi:
I honestly haven't done windows 10 personally. I have Linux at home and Win 7 at work. If you're having issues with Windows 10, my suggestion is try a bootable Linux USB and manually try each command. You could also turn the .bat into .sh and run it in terminal. Right click in the folder of the files and .sh and open terminal here and then bash flashall.sh. you could edit the file to not wipe (delete the fastboot -w line) if you're just doing it to take the update, then reroot.

Edit: Honestly, with the shoddy update cycle of Moto, why haven't you tried LOS or DU? Only speaker mod and camera mod don't work. Everything else is rock solid.
[Moto Z2 Force  Guides, News, & Discussion] tonochito:
To be honest i think i screwed this phone, tried to restore and now i have 0 on internal storage... booting on TWRP
[Moto Z2 Force  Guides, News, & Discussion] tonochito:
Really the last security update seems to block Titanium Backup... I can't even open it because it crash, and there's no alternative to freeze or remove the annoying Amazon and Sprint bloatware... Seems there's no stock ROM without that stuff
[Moto Z2 Force  Guides, News, & Discussion] davehasninjas:
Is there a mirror for the utilities zip? I keep getting a 502 error with the androidfilehost link.
[Moto Z2 Force  Guides, News, & Discussion] ElwynnEldoriath:
I have returned to Stock Rom, but my bootloader is still unlocked, keeping me from using apps like google Pay. How can I return to a locked bootloader again?
[Moto Z2 Force  Guides, News, & Discussion] ekoms420:
Hello, i have an Amazon unlocked ATT Moto Z2 force xt1789-04

I installed the Oreo 8 update via PC software, does this method work for it to return to Android 7?? Bootloader isn't unlocked and it is not rooted or anything...

Thanks so much for your time and any information
[Moto Z2 Force  Guides, News, & Discussion] Uzephi:
I don't think you can flash all an older version with a locked bootloader. I know most devices won't let you. I never had my Z2F locked long enough to try.
[Moto Z2 Force  Guides, News, & Discussion] iurd2007:
Moto Z2 Force from AT&T cannot be bootloader unlocked :crying:

---------- Post added at 09:46 PM ---------- Previous post was at 09:44 PM ----------

probably you can downgrade... but if you downgrade and apply any ota update, your phone will enter in a damned hardbrick, so... dont downgrade.
[Moto Z2 Force  Guides, News, & Discussion] ha3:
I've just come across this. Is there any chance you can link me to or advise on what kind of 'wonky stuff' is required to get my phone back into working shape? I've been installing a number of different ROMs and my UK SIM card no longer works. My phone model is XT1789-03.
[Moto Z2 Force  Guides, News, & Discussion] Uzephi:
Flash the firmware for your model. -03 is Sprint variant. You can flash the system/oem/boot of a RET version if you want to remove any bloat. Keep baseband and such of the Sprint Variant. I did this for AT&T and it worked fine. Sprint bootloader and modem (NON-HLOS.bin) and used AT&T oem/system/boot images. You would need to manually update if you do this method though.
[Moto Z2 Force  Guides, News, & Discussion] iurd2007:
Hello. I have a moto z2 force at&t , updated to oreo.

As you know, NO BOOTLOADER UNLOCK for this model. Then, how to flash a retail rom? Probably if i flash a Frankenstein (sprit + retail + att) , and get a OTA UPDATE the phone gona die.
[Moto Z2 Force  Guides, News, & Discussion] Uzephi:
Oreo update added to OP! Enjoy!
[Moto Z2 Force  Guides, News, & Discussion] Chien35:
I'm on OREO Retail version, can I return to stock SPRINT version?
[Moto Z2 Force  Guides, News, & Discussion] Uzephi:
If you have a Sprint model phone, this will work just fine.
[Moto Z2 Force  Guides, News, & Discussion] EddiePR:
Can i downgrade from oreo?
[Moto Z2 Force  Guides, News, & Discussion] Uzephi:
Not suggested but can in theory (never tested) if you blank flashed. I haven't tested any of the blank flashes floating around for this device.

You cannot without that. It'll be in an unusable state and would need a blank flash to fix, if it works...
[Moto Z2 Force  Guides, News, & Discussion] EddiePR:
thanks for your answer..

I've been trying to make a blankflash without success ... i need help. It is my first Android moto device and I have very little experience with adb, commands and related. If it is possible, is there a guide? or someone could help me with that ..
[Moto Z2 Force  Guides, News, & Discussion] Uzephi:
http://download.invisiblek.org/nash/unbrick.zip

Read the instructions carefully! This is very low level **** and can cause a hard brick if not followed correctly.
[Moto Z2 Force  Guides, News, & Discussion] EddiePR:
Thanks friend, but I give up. I'll see if someone here can do a blankflash, since I do not get it:confused:

I've been trying for 3 days without results. I followed all the tutorials to the letter, so?:crying:
[Moto Z2 Force  Guides, News, & Discussion] Uzephi:
I haven't tried it at all, blank flashing only is needed when you totally brick the device. Using it for other reasons isn't suggested, so I haven't tested it. Invisiblek had to since he was messing with the bootctrl hal.
[Moto Z2 Force  Guides, News, & Discussion] EddiePR:
Oh, I understand. I read something like that in the forums. even a person recommended brick the device to make blankflash. My moto works perfect, but I would like to do a super clean installation and see if my system is certified again, since it is the main reason why I want blankflash or do donwgrade ... since my moto works at 100%
[Moto Z2 Force  Guides, News, & Discussion] litsgt:
So I had done some flashing back in the cyanogenmod days and wanted to try it with my brand new moto z2. Long story short I bricked it up like a stone mason...

specs before tinkering:

Sprint moto z2 force running latest oreo via sprint OTA

My process was

1. Unlock bootloader via motorola code. This worked fine until I attempted to...

2. Flash TWRP using this method (double U double U double U).theandroidsoul.com/motorola-moto-z2-force-root/

3. I am now soft bricked. I can boot into bootloader but attempting to boot into recovery gives me nothing but a droid with a red exclamation point (saying the recovery is broken I assume?). Attempting to fully boot up the phone brings it to the blue android/motorola screen, it just stays there. (I've waited as long as 30 min with no change)

4. I attempted to go back to stock via the method and files on this thread to no avail.

It's not a hard brick so I REALLY hope theres a way to fix my new phone and its freshly voided warranty...
[Moto Z2 Force  Guides, News, & Discussion] Uzephi:
Have you flashed the Oreo link or the Nougat one? You need to flash the one that matches your version.
[Moto Z2 Force  Guides, News, & Discussion] litsgt:
I first tried the nougat then had the realization that I probably needed the oreo. So oreo was the last attempt.
[Moto Z2 Force  Guides, News, & Discussion] Uzephi:
How long did the Oreo one take to flash?
[Moto Z2 Force  Guides, News, & Discussion] litsgt:
Around 15 min for so. The nougat took seconds so I knew something was up.

update: I redownloaded the oreo flashall and ran it again. I have no idea what was wrong with the previous download but I'm not going to look a gift horse in the mouth... Now it boots up, functions, and is unbricked but for some reason my recovery is still not right. Its the same recovery screen as before (black screen with little droid and exclamation point) but it now has the words "No Command" in white letters at the bottom. It seems as though whatever I did to it with TWRP (I think I've somehow blanked my recovery?) is still in there but I have no way to clear caches and whatnot.

I can live with it I ABSOLUTELY have to but I'd rather fix my recovery if possible and have a fully functioning phone.

And thanks again guys for all your help and fast responses. Not all heroes wear capes...
[Moto Z2 Force  Guides, News, & Discussion] Uzephi:
Oreo one should take longer. Your system will need to parse the system and OEM images since they are over 512Mb. I have a large project at work so my fixing it is on the back burner to preparse those images as in a perfect world, it will flash fine (never ran into an issue on my testing and I have used that same zip 8 times thus far switching from AOSiP/LoS test builds back to stock, takes my PC with 8Gb of ram about 20 minutes but works fine).

Pull the boot image from that zip and manually flash it in bootloader: fastboot flash boot boot.img

Then reboot to recovery. Our recovery is nested in our boot image ramdisk.
[Moto Z2 Force  Guides, News, & Discussion] litsgt:
I thought about trying that last night but I figured I'd get some advice from you guys first. I'll go ahead and try that tonight. Thanks again!
[Moto Z2 Force  Guides, News, & Discussion] zlebors:
where?
[Moto Z2 Force  Guides, News, & Discussion] 41rw4lk:
Looks like there isn't one in the zip you have, but you can find the xml convertor here. Just make sure you have the right zip for your carrier and/or version. Seen a lot of issues from not researching enough and flashing the wrong thing.
[Moto Z2 Force  Guides, News, & Discussion] zlebors:
here's oreo, couldn't find it either
[Moto Z2 Force  Guides, News, & Discussion] ha3:
Thanks so much for this. Not had any luck using Sprint bootloader and modem with RETIN - SIM still not recognised. Do you think it will make a difference if I use RETLA or RETRU instead? I bought the phone in the UK so I'm also wondering if perhaps it doesn't like the US Sprint bootloader and modem!
[Moto Z2 Force  Guides, News, & Discussion] Uzephi:
It won't allow it. It must match the model number to flash and be an unmodified file from Moto. You are stuck with AT&T firmware and software
[Moto Z2 Force  Guides, News, & Discussion] iurd2007:
Sad :( . My Moto Z2 Force at&t unlocked, dont take LTE signal, only 3g/2g. But if i install my chip in Lg g6, it takes LTE FLAWLESSLY. It is not LTE coverage issue, is something with the phone. Even that the Moto z2 force have LTE 4 bands
[Moto Z2 Force  Guides, News, & Discussion] Horatig:
cnt find Utilities zip

:crying::crying:

where can i find the Utilities zip please?
[Moto Z2 Force  Guides, News, & Discussion] 41rw4lk:
Hmm,,,,
[Moto Z2 Force  Guides, News, & Discussion] boo boo Mario:
How
[Moto Z2 Force  Guides, News, & Discussion] ram1894:
Can I flash latest Oreo RETIN on my xt1789-06 running latest oreo RETAPAC? Bootloader is locked
[Moto Z2 Force  Guides, News, & Discussion] Uzephi:
If locked, no. Has to be the one for your version. Unlocked, you might but OTA functionality and other things might not work.
[Moto Z2 Force  Guides, News, & Discussion] SHAHNVAJ:
Motorola is very bad is not update 9 pei is june month oppo realmi redme oneplus nokia is very fast update but motorola is not update fast i hate motorola i am chang my phone i am update oneplus phone
[Moto Z2 Force  Guides, News, & Discussion] iurd2007:
Moto is trash, i bought a moto z2 force at&t unlocked, and the phone dont take lte in foreign sim cards
[Moto Z2 Force  Guides, News, & Discussion] Uzephi:
Updated post 2 with disclaimer 3.
[Moto Z2 Force  Guides, News, & Discussion] iurd2007:
Hello. And what about hard bricked devices? Do you have the latest blankflash for moto z2 oreo feb 2019 patch?
[Moto Z2 Force  Guides, News, & Discussion] zidemizar:
I flashed the retail version on my Sprint Moto Z2 Force but I am missing a few features like voicemail notifications and calling plus, is there any way to just flash the bloatware back on the phone without wiping?
[Moto Z2 Force  Guides, News, & Discussion] Albert Wayne:
Hi, how can I downgrade from Pie to Oreo, is there a possibility?

Thank you
[Moto Z2 Force  Guides, News, & Discussion] Uzephi:
Please don't spam three threads with the same question. It might be possible, but as disclaimer two in post two states: it is never suggested to flash a system image not intended for your model or major Android version. I.E. if you're on Pie, don't go back to Oreo. You can try LOS but you'd run into verity issues if you try an Oreo stock ROM. The Pie OTA made adjustments that aren't in flash all zips.
[Moto Z2 Force  Guides, News, & Discussion] Albert Wayne:
sorry

I'm so sorry, Uzephi, I was desperate looking for a solution after updating on pie, it won't happen again, I promise, I'll wait a little before trying LOS, Regards.
[Moto Z2 Force  Guides, News, & Discussion] netorincon:
Hi, I used this method to return to stock successfully (latest Oreo security update). But when installing the Pie OTA, the process stops at about 30% in step 3 of 6 (The OTA downloads just fine). After this, i get the message "Sorry, there was a problem updating your moto z2. No changes were made".

I didnt make any changes to system after going back to stock. What could be wrong?

Edit: Added YouTube video showing my problem.
[Moto Z2 Force  Guides, News, & Discussion] Tiger749:
I am returning my moto z2 force for a defective lcd display. How can i re lock the bootloader? They might not repair it when they see the unlock bootloader screen. Such a Shame the phone is only 4 months old.
[Moto Z2 Force  Guides, News, & Discussion] fast69mopar:
If you want to lock the bootloader I would make sure you are back to a fully stock state by using a flash-all for your variant and current software number.

To lock the bootloader you will need to boot into the bootloader, connect your USB and open a command prompt and type:

fastboot oem lock
[Moto Z2 Force  Guides, News, & Discussion] Tiger749:
Will that get rid of your device software can't be checked for corruption message during boot?
[Moto Z2 Force  Guides, News, & Discussion] fast69mopar:
I do believe it will but I cannot be certain because I haven't tried it in quite a while. You could always do this to try and hide it...

https://www.google.com/amp/s/xdafor...ove-bootloader-unlocked-warning-t3702353/amp/
[Moto Z2 Force  Guides, News, & Discussion] Tiger749:
Now it says device loaded a different operating system. ? It did lock the bootloader tho.
[Moto Z2 Force  Guides, News, & Discussion] kinshuugoyal:
from an hour it is showing erasing "modemst1 ".what to do now ???