Rooting an Android Motorola Moto G4 Rooting Motorola Moto G4
I have a Motorola Moto G4 that I would like to root.Quick summary of specs:


Developer options are enabled


OEM unlocking = enabled
USB debugging enabled

Android version: 7.0
computer os: windows 10
adb installed


adb devices: device shows up
adb reboot bootloader works

fastboot installed


device shows up in fastboot devices



Problem: after I go to the bootloader screen and I try fastboot oem get_unlock_data the output is:

... INFOUnlock data:

INFOUnlock data unavailable

INFOFailed

OKAY [ 0.101s]

finished. total time: 0.101s


Tried it also from a linux virtual machine. Same result, no code.

Nothing is added to my path. All commands are run in the installed directories of the programs.

How can I fix this?
your device is most likely verizon or AT&amp;T. check your cid is unlockable with  

fastboot getvar all


Your device is unlockable if the CID value returned is listed  

0x0000
0x0003
0x0007
0x0009
0x000B
0x000C
0x000D
0x000E
0x0014
0x0015
0x00DE
0x0032


source