FORUMS

Moto G7 Power/Supra [All Versions] [Pie] Magisk Root Guide [OTA/SafetyNet Working]

24 posts
Thanks Meter: 52
 
By diversenerd, Junior Member on 23rd April 2019, 04:38 AM
Post Reply Email Thread
Disclaimer: This WILL void your warranty. I am not liable for breaking/bricking your phone, you losing your data, or any nuclear war/other catastrophe. This process WILL totally wipe all data on your phone. Make sure you have a backup! You will also forever see "bad key" displayed in the top left of your screen for a few seconds after a reboot after unlocking the bootloader. There is currently no way around this that I'm aware of (let me know if you have a way)

This guide was assembled from mingkee's G7 guide here: https://forum.xda-developers.com/mot...agisk-t3907084

You will need:
1. Your Moto G7 Power (Any hardware version, any carrier, but running Android 9 Pie)
2. A stock boot.img for your hardware version, here are the two that I have. You can just extract the boot.img from a stock ROM for a hardware version not listed, although I'm not sure it actually matters which one you use. Experiment at your own risk.(Full stock ROM's for both versions will be linked in the next post. )
3. A USB cable to connect your G7 to a computer
4. Motorola USB drivers: https://support.motorola.com/uk/en/p...uments/MS98028
4. Your bootloader unlock code from Motorola, more on that below
5. Android SDK

Step 1: Unlocking the bootloader
First we'll need to unlock the bootloader, to do this, you'll need your unlock code from Motorola:
https://support.motorola.com/us/en/bootloader
Note that this will require you to register your device with Motorola, and this WILL void your warranty.

Then, download and install the Motorola USB drivers (link above), you may need to reboot your computer after installation.

Next you'll need to download and extract/install the Android SDK
https://developer.android.com/studio...html#downloads
Note that you'll only need the "command line tools" for this guide, unless you really want the whole SDK (huge).
Extract the command line tools to anywhere really, C:\Android is fine for Windows. If you downloaded/installed the whole sdk, the tools you need will be in C:\Users\[your username]\AppData\Local\Android\Sdk\platform-tools
Once you have that, open up a powershell window in your tools folder by holding Shift and right-clicking in the folder.

Now, reboot your G7 to fastboot mode by powering off, then holding power+volume down until you're in the bootloader. Now, connect your G7 to your computer with your USB cable.

In powershell, verify your device is recognized by typing "./fastboot devices". Your G7 should show up by its serial number.

Now, type "./fastboot oem unlock [your motorola unlock code]". THIS WILL WIPE ALL DATA ON YOUR PHONE. After that, use the volume up and down buttons and then the power key to restart the bootloader. You should now see "flashing_unlocked" at the bottom of the bootloader screen. Now use the volume/power buttons to select "start" to boot the phone. You will see "bad key" displayed in the top left corner of the screen. This is normal. The phone should boot and bring you to the Android set up wizard. Go ahead and set up the phone as you normally would.
Note that at this time, if you go to "Update" in system settings, it may warn you that "system integrity is compromised" and that you will no longer receive OTA updates. This is also normal, we'll fix that in a bit.

Step 2: Rooting
Now that we have an unlocked bootloader, we can flash things to the phone through fastboot (at the time of this writing, TWRP or other custom recoveries are not available for the G7 Power. Once it is, you can use that to flash the Magisk .zip file instead of using powershell).

Copy the correct *_boot.img for your hardware version to a folder on your phone. I used the downloads folder. (not too sure if the version makes a difference; I was able to flash the entire US XT1955-5 firmware/rom to my Latin America XT1955-2 without a problem, but experiment at your own risk)

Download and install the Magisk Manager APK through Chrome or browser of your choice on your G7
https://github.com/topjohnwu/Magisk/releases
It will ask you if you want to allow [your browser] to install things from unknown sources. Say yes.

Then, open Magisk Manager and tap "Install". Then tap "patch boot image file". Select the *_boot.img you copied earlier and let it run. It will tell you when its done.
Once it completes, copy the patched *_boot.img back to your computer and place it in the same folder as your Android SDK tools (where fastboot.exe and adb.exe live)
Now power off the phone then boot to fastboot, again by holding power + volume down until the bootloader appears.

Now in powershell, type "./fastboot flash boot [the name of your patched boot.img].img" and hit enter. Alternatively, type "./fastboot flash boot" then hit space, then drag your patched *_boot.img into powershell and hit enter.
(Note, if you get an error saying "Invalid partition name boot__a" like I did, add a "_a" to "boot" ie "./fastboot flash boot_a [the name of your patched boot.img]" instead. )
Powershell should tell you "Image signed with key bad key". This is normal.

Now use the volume up/down buttons and power button to start the phone.

Once booted, load up Magisk Manager again. You should see all green checkmarks. Congrats, your G7 is now rooted! One last thing:
Tap where Magisk says "tap to start SafetyNet check". This tests to see if its able to fool Google's checks and let you install OTA updates or use Android Pay. If you did everything properly, this should all check out fine. Confirm by going into Updates in System Settings and verifying that you are up-to-date and it doesnt say anything about "device integrity compromised".

Thanks to everyone who's work I shamelessly paraphrased. I wanted to make a concise guide specifically for the G7 power as I didn't find much online regarding it. (And the stock US rom was ridiculously hard to find and acquire). I'll link stock US and Latin America G7 Power firmwares/roms in the post below in case anyone wants to go back to stock, once the upload finishes. Note: there is no known way at the time of this writing that you can ever get rid of "bad key" being displayed at boot once you unlock the bootloader (again, if anyone knows how, let me know! Thanks!)
The Following 19 Users Say Thank You to diversenerd For This Useful Post: [ View ] Gift diversenerd Ad-Free
23rd April 2019, 04:39 AM |#2  
OP Junior Member
Thanks Meter: 52
 
More
gedster314 linked me to a site in another thread where stock ROMS for a lot of devices can be found, including the XT1955 (codename: Ocean).
https://mirrors.lolinet.com/firmware...cean/official/

"RETUS" on that page would signify "Retail, US"
The Following 9 Users Say Thank You to diversenerd For This Useful Post: [ View ] Gift diversenerd Ad-Free
23rd April 2019, 12:31 PM |#3  
Senior Member
Thanks Meter: 24
 
More
until some good custom roms will pop out i don't have needs to unlick/root...
The Following User Says Thank You to mrmcphisto77 For This Useful Post: [ View ] Gift mrmcphisto77 Ad-Free
23rd April 2019, 08:38 PM |#4  
OP Junior Member
Thanks Meter: 52
 
More
Quote:
Originally Posted by mrmcphisto77

until some good custom roms will pop out i don't have needs to unlick/root...

Baby steps my friend.
The Following User Says Thank You to diversenerd For This Useful Post: [ View ] Gift diversenerd Ad-Free
25th April 2019, 05:37 AM |#5  
nucher's Avatar
Senior Member
Thanks Meter: 46
 
More
Their are still reasons to Root a phone besides ROMs. Titanium backup, Root explorer, and having super user
access. I used to Root my Pixel 2 to enable tethering when the carrier blocked it. The fact that we don't have
the option of super user access on a device we own is crazy. Jailbreaking the iPhone opens up so many
customization's with tweaks and apps that I went to the dark side. I also have the G7 Power so I'm not a
total traitor.

Quote:
Originally Posted by mrmcphisto77

until some good custom roms will pop out i don't have needs to unlick/root...

The Following 3 Users Say Thank You to nucher For This Useful Post: [ View ] Gift nucher Ad-Free
26th April 2019, 12:44 AM |#6  
Senior Member
Thanks Meter: 31
 
More
Got everything to work! Flashed Tethering Enabler too. Thank you!
The Following 2 Users Say Thank You to Coak5 For This Useful Post: [ View ] Gift Coak5 Ad-Free
26th April 2019, 07:43 AM |#7  
Senior Member
Flag Brooklyn, NY
Thanks Meter: 771
 
More
Quote:
Originally Posted by nucher

Their are still reasons to Root a phone besides ROMs. Titanium backup, Root explorer, and having super user
access. I used to Root my Pixel 2 to enable tethering when the carrier blocked it. The fact that we don't have
the option of super user access on a device we own is crazy. Jailbreaking the iPhone opens up so many
customization's with tweaks and apps that I went to the dark side. I also have the G7 Power so I'm not a
total traitor.

There's one more reason to root: CF Lumen
I want all devices have same exactly same white tone.
The Following User Says Thank You to mingkee For This Useful Post: [ View ] Gift mingkee Ad-Free
27th April 2019, 03:51 AM |#8  
turboyo's Avatar
Senior Member
Flag Miami
Thanks Meter: 2
 
More
Anyone with a regional phone that has NFC and 5ghz disabled try flashing to a region that has it enabled to see if it works?? I read the NFC and 5ghz options are just software locked
27th April 2019, 05:01 AM |#9  
OP Junior Member
Thanks Meter: 52
 
More
Quote:
Originally Posted by turboyo

Anyone with a regional phone that has NFC and 5ghz disabled try flashing to a region that has it enabled to see if it works?? I read the NFC and 5ghz options are just software locked

I've tried that. Flashing the XT1955-2 with the XT1955-5 firmware. It flashes and boots up without a problem but no dice for the 5Ghz. I have gotten ALL LTE bands unlocked however, about to write up a how-to. If I can get 5ghz wifi working then the XT1955-2 will be the cats meow with its 4gb ram and dirt cheap price.
The Following 2 Users Say Thank You to diversenerd For This Useful Post: [ View ] Gift diversenerd Ad-Free
27th April 2019, 06:31 AM |#10  
turboyo's Avatar
Senior Member
Flag Miami
Thanks Meter: 2
 
More
Quote:
Originally Posted by diversenerd

I've tried that. Flashing the XT1955-2 with the XT1955-5 firmware. It flashes and boots up without a problem but no dice for the 5Ghz. I have gotten ALL LTE bands unlocked however, about to write up a how-to. If I can get 5ghz wifi working then the XT1955-2 will be the cats meow with its 4gb ram and dirt cheap price.

Perfect. How about NFC? Does the XT1955-2 come with NFC already enabled? Or does the -5 enable it?
27th April 2019, 06:51 AM |#11  
OP Junior Member
Thanks Meter: 52
 
More
Quote:
Originally Posted by turboyo

Perfect. How about NFC? Does the XT1955-2 come with NFC already enabled? Or does the -5 enable it?

I was wrong in my first thread, my -2 does NOT have NFC. Heres the newly minted LTE Band unlocking guide: https://forum.xda-developers.com/g7-...e-lte-t3925246
Post Reply Subscribe to Thread

Guest Quick Reply (no urls or BBcode)
Message:
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes