yashsingh1/xdaforums huggingface dataset:
[Moto G5S  Guides, News, & Discussion] Adi5:
[MENTION=4554317]lohanbarth[/MENTION]

correct order flashing rom for g5s:

mfastboot getvar max-sparse-size

mfastboot oem fb_mode_set

mfastboot flash partition gpt.bin

mfastboot flash bootloader bootloader.img

mfastboot flash modem NON-HLOS.bin

mfastboot flash fsg fsg.mbn

mfastboot erase modemst1

mfastboot erase modemst2

mfastboot flash dsp adspso.bin

mfastboot flash logo logo.bin

mfastboot flash boot boot.img

mfastboot flash recovery recovery.img

mfastboot flash system system.img_sparsechunk.0

mfastboot flash system system.img_sparsechunk.1

mfastboot flash system system.img_sparsechunk.2

mfastboot flash system system.img_sparsechunk.3

mfastboot flash system system.img_sparsechunk.4

mfastboot flash system system.img_sparsechunk.5

mfastboot flash oem oem.img

mfastboot erase cache

mfastboot erase userdata

mfastboot erase DDR

mfastboot oem fb_mode_clear

mfastboot reboot

This error clogo and customize normal,G5s haven't got clogo and customize partitions :)
[Moto G5S  Guides, News, & Discussion] Membrillo007:
Can someone provide me the stock recovery for this device (i got a XT1790)
[Moto G5S  Guides, News, & Discussion] bycabraljr:
Can anyone help me to get the firmware for XT1792, NPPS26.102-49-1?

It's the latest firmware for the Moto G5S, with security patch 1st December 2017.

I'm asking this because I need to flash my firmware again with fastboot and it give me this message while flashing boot.img:

"(bootloader) Security version downgrade

(bootloader) Image boot failed validation

(bootloader) Preflash validation failed

FAILED (remote failure)""

I'm afraid to fkup my device like I did with my Moto X 2014: Downgraded the OS from 6.0 to 4.4 and then I accidentally upgraded again with OTA to 6.0. When I downgraded, It ran 4.4 with the latest bootloader. When I flashed the 6.0 with fastboot, everything went fine as the bootloader was in the most recent version. But when I did the upgrade (again, as I love mess with roms) from 4.4 to 6.0 with OTA, it partched the bootloader and corrupted everything, turning my phone into a brick.

in short, I'd love to get the latest firmware with the latest bootloader version, as I'm stuck with custom roms as I can't restore the official firmware because I did upgraded my phone to the latest firmware (NPPS26.102-49-1) before flashing custom roms. :silly:
[Moto G5S  Guides, News, & Discussion] lohanbarth:
I often do downgrades simply do not flash the gpt.bin.
[Moto G5S  Guides, News, & Discussion] bpcy1st:
I want Rom update on 1 December :crying:
[Moto G5S  Guides, News, & Discussion] lohanbarth:
hello, this update will not be released in flash fastboot.
[Moto G5S  Guides, News, & Discussion] alinefr:
Just flash this one and you will get 1st december as ota update.
[Moto G5S  Guides, News, & Discussion] FloBaoti:
I'm sorry if my question is stupid. Here is a screenshot of my device rom versions. Is this the "last" known version ? I don't have any OTA update since October.

If I can update to a newer rom, how to do it and will I need to reset my phone ?
[Moto G5S  Guides, News, & Discussion] lohanbarth:
the orange rom has not had the ota yet
[Moto G5S  Guides, News, & Discussion] FloBaoti:
Ok and can I switch to another official rom "officially" ? (without unlocking bootloader)
[Moto G5S  Guides, News, & Discussion] Adi5:
Yes but You must install newest version of stock

I installed on locked bootloader
[Moto G5S  Guides, News, & Discussion] smipx013:
Hi there,

Thanks so much for this - saved me!!!

My phone went bad after the last OTA update and I used this to recover things.

One question... If I use this method going forward to install the latest updates/build - is there a way to preserve the user data (bearing in mind the Phone has a lock PIN and so is encrypted).

Can I just leave out the "mfastboot erase userdata" command.

Thanks

Paul
[Moto G5S  Guides, News, & Discussion] michael50310:
Does this support model XT1797?

Does this support model XT1797? I got mine device few days ago and the model is XT1797.. can I root this device and flash custom rom on this model?

I saw most of the post are not for this model...
[Moto G5S  Guides, News, & Discussion] Quark^2:
I have build NPP26.10249 and want to flash the new OTA update.

Unfortunately my system is somehow touched and I want to dirty flash my system again with NPP26-102-49.

This should be "safe", right?

What steps should I follow? Just this? :

mfastboot getvar max-sparse-size
mfastboot oem fb_mode_set
mfastboot flash system system.img_sparsechunk.0
mfastboot flash system system.img_sparsechunk.1
mfastboot flash system system.img_sparsechunk.2
mfastboot flash system system.img_sparsechunk.3
mfastboot flash system system.img_sparsechunk.4
mfastboot flash system system.img_sparsechunk.5
[Moto G5S  Guides, News, & Discussion] lohanbarth:
Normally it's enough, if your mobile is a bootloop, reflashed the complete rom
[Moto G5S  Guides, News, & Discussion] Seraphic_Fate:
Hello all.

I'd like to report this ROM works with XT1792 (Brasil version). Story of my life: after unlocking the bootloader, I made a dirty TWRP backup of my stock ROM: the /system partition would fail to mount after every restore.

So I spent a few days searching for a stock ROM that would restore my phone to basic functionality. The instructions failed at mfastboot flash partition gpt.bin with "not verified or corrupted", but I went ahead regardless and everything else worked.

After a few tries, thanks to this ROM, my G5S is recovered! BUT I didn't keep stock installed long: flashed LineageOS right over it :D
[Moto G5S  Guides, News, & Discussion] Quark^2:
Would I lose all my data that way? I assume not, but

restoring a TWRP backup of system would work too?
[Moto G5S  Guides, News, & Discussion] lohanbarth:
you do not lose your data, for the backup with the twrp I will not be able to tell you.
[Moto G5S  Guides, News, & Discussion] Talwar sridhar:
But in my case it is showing the same system status modified and I am having xt1795 Indian variant please guide me bro how to correctly flash
[Moto G5S  Guides, News, & Discussion] Adi5:
Read OP
[Moto G5S  Guides, News, & Discussion] Quark^2:
Does flashing another logo.bin count as modifying system?

If so, does reflashing the original count as having an unmodified system? (I guess not)
[Moto G5S  Guides, News, & Discussion] Adi5:
No

When You flash another kernel You will see modified status in bootloader menu
[Moto G5S  Guides, News, & Discussion] Talwar sridhar:
when i flash this rom at gpt.bin it says security downgrade

,preflash validation failed ,syill require signed images

is it from lenovo
[Moto G5S  Guides, News, & Discussion] lohanbarth:
did not flash the gpt.bin, passed directly to the next command.
[Moto G5S  Guides, News, & Discussion] Talwar sridhar:
Yes but I can't relock my bootloader and it is saying that still

Require signed boot image

---------- Post added at 12:11 PM ---------- Previous post was at 12:07 PM ----------

Are you saying to not to flash gpt.bin,but when I relock bootloader it says to flash all factory images and when I try. To flash them every step shows the same that security downgrade,preflash validation failed and doesn't relock bootloader
[Moto G5S  Guides, News, & Discussion] catalin habdul:
Why do you want to relock the boatloader? With the boatloader locked you can't flash custom roms , root ....
[Moto G5S  Guides, News, & Discussion] Daniel936:
Is the newest rom in this thread contains october or december security patch?

I recently got 26.102-49-1 with december security patch
[Moto G5S  Guides, News, & Discussion] Talwar sridhar:
No I don't have any interest to flash custom roms after a great struggle my software status has changed from modified to official so that's why I want to relock my bootloader

---------- Post added at 08:05 PM ---------- Previous post was at 08:01 PM ----------

Yes this thread contain October security patch (NPP26.102-49) still now we didn't get December one

---------- Post added at 08:09 PM ---------- Previous post was at 08:05 PM ----------

Yes this thread contain October security patch (NPP26.102-49) still now we didn't get December one
[Moto G5S  Guides, News, & Discussion] Daniel936:
I got one.

[IMG="Screeonshot"]https://drive.google.com/file/d/1csQiMk-iMK0910nQ8LPe9Nx2dHVqdCFk/view?usp=sharing[/IMG]

too bad i cant post screenshots or pictures..still dont have 10 posts.
[Moto G5S  Guides, News, & Discussion] Talwar sridhar:
Can't get the image update it with link that is been uploaded to drive
[Moto G5S  Guides, News, & Discussion] Daniel936:
cant do it because 10 posts restriction.
[Moto G5S  Guides, News, & Discussion] Talwar sridhar:
Did u get the new firmware that which is flashable if yes then provide the link in the next message with spaces for each word so that it won't recognize as a link:rolleyes:
[Moto G5S  Guides, News, & Discussion] Daniel936:
didnt think of that earlier, sorry ^^'

https:// drive.google.com/ file/d/1csQiMk-iMK0910nQ8LPe9Nx2dHVqdCFk/ view?usp=sharing
[Moto G5S  Guides, News, & Discussion] Talwar sridhar:
Ya it is hear
[Moto G5S  Guides, News, & Discussion] Daniel936:
thanks for reposting.

funny thing I didnt even get october security patch. I had August until this update.
[Moto G5S  Guides, News, & Discussion] michael50310:
Anyone is on retapac channel running NPP26.102-63 with December 1, 2017 patch?

I received an new update today, which is NPPS26.102-63-1, also brings February patch.
[Moto G5S  Guides, News, & Discussion] lohanbarth:
New firmware in op.

MONTANA_NPPS26.102-49-4_cid50_subsidy-DEFAULT_regulatory-DEFAULT_CFC.xml.zip ( Febuary 2018 Security update )
[Moto G5S  Guides, News, & Discussion] Talwar sridhar:
Can I install this firmware on retin channel Indian variant other wise please provide me the retin firmware please
[Moto G5S  Guides, News, & Discussion] lohanbarth:
I could not tell you, I have an EU version.
[Moto G5S  Guides, News, & Discussion] Talwar sridhar:
Does it support retin channel
[Moto G5S  Guides, News, & Discussion] Talwar sridhar:
Does we get any gpt.bin error if we flash this
[Moto G5S  Guides, News, & Discussion] michael50310:
You shouldn't, but still use it at your own risk, my current stock version is on NPPS26.102-63-1 also features February patch... Idk if this version will fits my device..
[Moto G5S  Guides, News, & Discussion] Talwar sridhar:
I have flashed the latest stock rom which has found on this page and I think it is a Brazil rom than how does I get software channel retin and baseband version indiadsds will I get the future updates on mobile
[Moto G5S  Guides, News, & Discussion] lohanbarth:
I flashed this rom and my baseband was not changed
[Moto G5S  Guides, News, & Discussion] Talwar sridhar:
Ya why does there are no changes on baseband and software Chanel
[Moto G5S  Guides, News, & Discussion] ASHDCBZ:
Moto G5s Hard bricked :confused: blankflash files and loader.img required.
[Moto G5S  Guides, News, & Discussion] Talwar sridhar:
Will us get the security patch updates I have installed the latest firmware on a Indian xt1795 variant baseband and software channel has not changed will I get the march security patch update
[Moto G5S  Guides, News, & Discussion] Guth13:
Me too.. :'(
[Moto G5S  Guides, News, & Discussion] Sytis:
Small question to which I haven't found the answer in this thread yet (maybe I'm just blind): Where do these software packages originate from? Official Sources? And would it be possible to log he DNS request when a new OTA hits the device to grab the full Image? :eek:
[Moto G5S  Guides, News, & Discussion] ShattrdChain:
More and more Moto G5S getting hard bricked every day. Guys, DO NOT FLASH STOCK ROM IF YOU HAVE APPLIED OTA. There is no blankflash file available so there is no way to recover the phone. Your phone is dead. BE CAREFUL.

And can senior devs clarify whether will it be safe to apply Oreo update (when it comes out) or will it hard brick the phone?
[Moto G5S  Guides, News, & Discussion] govind1233:
Yes it will brick the phone
[Moto G5S  Guides, News, & Discussion] ShattrdChain:
can you kindly explain why?
[Moto G5S  Guides, News, & Discussion] govind1233:
Because when you unlock bootloader it modifies system files...and after using custom ROM when you reflash the ROM it changes the bootloader version and when ota is installed by the user who did all above then it results in bricking the device...because ota is complied in a way that it needs the latest bootloader so it bricks the phone.
[Moto G5S  Guides, News, & Discussion] michael50310:
So is that mean after unlocking bootloader, install custom rom, rooted and if we want to go back to stock, after flashing the original rom in other thread, our phone will be bricked? Tks for the explanation:)
[Moto G5S  Guides, News, & Discussion] govind1233:
No...if u install ota after flashing stock firmware
[Moto G5S  Guides, News, & Discussion] Cyr4x:
Great, I've sucessfuly flashed the one with new february patch using fastboot (not mfastboot) on Linux. So it works.

In reference to the post above: Earlier I've flashed TWRP recovery on stock carrier-branded firmware (already upgraded to this february patch). In TWRP i've installed LineageOS from zip. Then on this LineageOS i've flashed this one stock unbranded firmware with february patch. Can I safely do stock OTA or not?
[Moto G5S  Guides, News, & Discussion] northwestspain:
Hi all

I also hard bricked my Moto G5s... white led blinking. EU version xt1794 from Spain. This is what I did:

- Unlock bootloader ->ok

- Flash recovery with TWRP 3.2.0-r1 ->ok

- Try to root with CF-AUTOROOT -> successfully, but root not working

- Install Magisk and Magisk apk -> successfully, root working.... but wifi not detecting networks...

- Uninstall Magisk and Magisk apk -> wifi still not working

- Flash stock firmware in this post -> HARD BRICKED...

this was the only failed command:

fastboot flash partition gpt.bin
(bootloader) slot-count: not found
(bootloader) slot-suffixes: not found
(bootloader) slot-suffixes: not found
(bootloader) has-slot:partition: not found
target reported max download size of 536870912 bytes
sending 'partition' (45 KB)...
OKAY [ 0.013s]
writing 'partition'...
(bootloader) Validating 'gpt.default.xml'
(bootloader) Security version downgrade
(bootloader) Image primary_gpt failed validation
(bootloader) Preflash validation failed
(bootloader) Cancelling 'gpt.default.xml'
FAILED (remote failure)

Please, is there any solution? Thank you!
[Moto G5S  Guides, News, & Discussion] H0LiC:
Hi!, Does anyone know if this works in XT1790 (Chile version)
[Moto G5S  Guides, News, & Discussion] lohanbarth:
Which version of the firmware did you flash?
[Moto G5S  Guides, News, & Discussion] northwestspain:
I flashed this files: MONTANA_NPP26.102-49_cid50_subsidy-DEFAULT_regulatory-DEFAULT_CFC.xml.zip

May be I should flash the february security update... was this the problem?
[Moto G5S  Guides, News, & Discussion] catalin habdul:
I never had any problems with flashing all the firmware from this thread, what I always do when flashing an older or a newer firmware I never flash the gbt.bin partition. There I believe it's the problem with all the briked phones. I flashed all the custom nougat ROMs and I always come back to official Motorola firmwares with no problem. I hope this help. Thanks
[Moto G5S  Guides, News, & Discussion] H0LiC:
this firmwares are specific to a variant? can it be flashed in a variant different of its target? could it brick the cellphone or it will work anyway (maybe not working properly)?
[Moto G5S  Guides, News, & Discussion] Cyr4x:
Can I fastboot-flash stock rom by any way without factory settings reset? I will do full flash when Oreo will finaly arrive, but then I don't want to have factory settings after each security update. Stock OTA is not safe with unlocked bootloader, especially when flashed stock rom over previous TWRP + Lineage OS, so I won't risk bricking the phone. Should I flash only system chunks or just don't erase userdata after flashing everything?
[Moto G5S  Guides, News, & Discussion] Exe557:
Yes, that's what I do mainly on my Nexus devices. Tried that yesterday on my G5S that was stuck on NPP26.102.49 and updated to NPP26.102.49-5 with keeping all my data.

I skipped :

mfastboot flash partition gpt.bin

mfastboot erase userdata

mfastboot erase DDR
[Moto G5S  Guides, News, & Discussion] Mindrel:
Hi guy. I skipped this 3 points too and it worked perfectly for me, and without losing any data... Thank you. :victory: :victory:

I had to reinstall the original firmware because I could not apply the February OTA update with the modified bootloader and/or recovery...

[MENTION=4554317]lohanbarth[/MENTION] : Maybe you could specify it in the post ? It could help those who need it. :good:
[Moto G5S  Guides, News, & Discussion] Cyr4x:
Why Google Play says my device is uncertified with this rom (february update)? It's pure stock.
[Moto G5S  Guides, News, & Discussion] Mindrel:
Where did you see this message? I do not see it. Put a screenshot.

---------- Post added at 10:20 PM ---------- Previous post was at 09:55 PM ----------

[EDIT] OK I saw it in the settings.

I don't know why... :confused: :confused:
[Moto G5S  Guides, News, & Discussion] Cyr4x:
Does anyone else have the DF-BPA-30 error in Google Play with this rom? It occurs since few days, i.e. when trying to install Facebook Messenger and some Google apps. Wiping Google Play Services and Google Play data or removing/adding back Google accound doesn't help.
[Moto G5S  Guides, News, & Discussion] catalin habdul:
Maybe because your boatloader it's unlocked?
[Moto G5S  Guides, News, & Discussion] Illuvitar:
I'm getting a 503 error trying to download the ADB drivers. Hope it's just a temporary glitch.

Some numbered questions:

1. As I understand it, the process in the top post CAN'T be used if an OTA has been applied. Is there a way of checking if an OTA has been applied? (My partner can't remember if she did it or not)

2. If an OTA has been applied, what is the method for future updates?

3. If an OTA has not been applied, is the Feb 2018 ROM safe to apply or is there something to be aware of to avoid bricking?

4. If I avoid:

mfastboot flash partition gpt.bin

mfastboot erase userdata

mfastboot erase DDR

should I then not lose any data?

Cheers!
[Moto G5S  Guides, News, & Discussion] vliqnie17:
I found you the new stock firmware with the April 2018 security patch.

Link:drive.google.com/file/d/1I-SlneTVa4rQ9DNdOLMfn_SpiB2jUpza/view
[Moto G5S  Guides, News, & Discussion] Talwar sridhar:
You can't post links u should have minimum 10 posts to post a link bro please message this link on Moto g5s Montana telegram discussion group so some one can upload it to xda

Search for Moto g5s on telegram to get the group
[Moto G5S  Guides, News, & Discussion] lohanbarth:
https://androidfilehost.com/?fid=962187416754478152

new build april security patch
[Moto G5S  Guides, News, & Discussion] shobbz:
g5s with blinking white led. I can't boot so i can't unlock boot loader, Am i screwed? I can load the firmware with fast boot but the phone will not turn on, just flashing white light:(
[Moto G5S  Guides, News, & Discussion] ARJNMRLON:
Hi, I want to go back to the stock rom, I knew it was bricking smartphones. It's real? and every time I have to update like this?
[Moto G5S  Guides, News, & Discussion] Dante187:
Hello everybody. I did everything for guidance. Also had no mistakes. But the mobile phone does not start anymore. Neither normal nor in recovery mode. Is no longer recognized by the PC. Only as a faulty USB device. led Also flashes 2 times fast white. When charging the battery and when I connect his ess to the PC. Is totally broken, right?
[Moto G5S  Guides, News, & Discussion] Daniel936:
Has anyone received it in Reteu?
[Moto G5S  Guides, News, & Discussion] jlcastro:
I got a from from India, i need to change baseband to use it in mexico, is it possible??
[Moto G5S  Guides, News, & Discussion] DoctorStrange96:
Just flash the latest firmware and you won't brick your device. In this case, use the one with the April security patch, no matter if your phone came with either the October or December '17 or February '18 patches as stock.

---------- Post added at 11:02 ---------- Previous post was at 10:56 ----------

I downloaded the latest firmware (April 2018) from here, installed as per instructions on OP (only skipped erasing userdata and DDR and flashing recovery, as I wanted to keep TWRP), zero problems. No white light, no IMEI 0. Phone works just fine. Mine came with the December 2017 security patch installed.
[Moto G5S  Guides, News, & Discussion] DoctorStrange96:
Do these commands

fastboot erase modemst1
fastboot erase modemst2

actually cause IMEI loss? Because I did execute these commands and both IMEIs are still there.
[Moto G5S  Guides, News, & Discussion] lohanbarth:
for me too the command works
[Moto G5S  Guides, News, & Discussion] ARJNMRLON:
Hi, flahsed the last update, and get sucess!
[Moto G5S  Guides, News, & Discussion] Adamask:
Thanks for the advice.
[Moto G5S  Guides, News, & Discussion] Toro Loco:
after my device is hardbricked, and i recovered it, any recovery stay in the memory, any solutions ?
[Moto G5S  Guides, News, & Discussion] lohanbarth:
Hello,

sorry I do not understand your question.

what recovery is the stock or twrp?
[Moto G5S  Guides, News, & Discussion] Toro Loco:
I tried both, after a reset the TWRP is gone, before the hard brick it worked nice, but I can't fix it in the memory, when I enter the recovery mode, the "no command" appears.
[Moto G5S  Guides, News, & Discussion] lohanbarth:
did you reinstall the twrp?

because the "no comand" is the recovery stock.

what recovery did you use and what order did you make?
[Moto G5S  Guides, News, & Discussion] Daniel936:
Hello. Three questions here

1.Can I flash newest rom on stock with locked bootloader?

2.Will it debrand my phone (positive thing)?

3. Which ret channel is it? Im currently in reteu, will it change after flashing this rom?
[Moto G5S  Guides, News, & Discussion] DoctorStrange96:
1. Yes, sure. Everything is signed by Motorola so you should have no issues flashing.

2. Also yes. All carrier stuff will be gone.

3. No, it won't change. The software channel is probably tied to the device itself now. Only a motherboard replacement could change it, if at all.

---------- Post added at 09:52 ---------- Previous post was at 09:50 ----------

Will Moto ever release a 7.1.1 firmware with the June security patch, or will they hold it until 8.1 is ready and release the patch with said firmware? :think:
[Moto G5S  Guides, News, & Discussion] dineshthakur14:
@talwar shridhar @lohanbarth anyone who has flashed stock rom in xt1795

I am using moto g5s (xt1795 ) indian variant i have flashed custom rom but i have lost the volte support so i wanna install stock rom can anyone suggest me which version i should install i think this phone i had purchased in October month and and after 2 update in February i had rooted my phone ???????????
[Moto G5S  Guides, News, & Discussion] Talwar sridhar:
Can I get a screenshot.
[Moto G5S  Guides, News, & Discussion] dineshthakur14:
Solved ims registration got and volte working in all custom rom
[Moto G5S  Guides, News, & Discussion] michael50310:
hi there, thanks for the tutorial! Successfully flashed the firmware and no issue at all (model XT1797, Taiwan model)

but I'm wondering is it possible to relock the bootloader and change the software status back to stock?

I tried the relock command but it tells me I need a signed boot.img... what can I do?
[Moto G5S  Guides, News, & Discussion] Adamask:
How can i capture OTA? I have this file (Blur_Version.26.251.6.montana.retail.en.US.zip) inside my phone after download the OTA and cant install the same. Always OTA error. Android logo erro.
[Moto G5S  Guides, News, & Discussion] rssxda:
Firmware completa do Moto G5s, Montana.

https://rsdsecure-cloud.motorola.co...ubsidy-DEFAULT_regulatory-DEFAULT_CFC.xml.zip

June patch