[Sony Xperia XZ Questions & Answers] YasuHamed:
if you click the BLU button! it will ask for unlock code by SONY, and you can do that!

---------- Post added at 09:31 AM ---------- Previous post was at 09:10 AM ----------

[QUOTE="Nimral, post: 77801422, member: 8902279"]Hi all,
would anyone be so kind to walk me through the process of rooting my Xperia XZ (F8331). I need this to be allowed to run a network sniffer which I need to resolve a weird network problem I have with IPv6.

---- Long story & rants ----
I admit, I am running out of patience, sorry for that.

I have tried to root my XA F8331 (Android 8.0.0) for more than 2 days now with no success. Host computer is Windows 10 x64. I wade knee deep in outdated, incomplete, misleading, simply not working for some reason, laden with unclear abbreviations and all other kind of time wasting misinformation both in this forum and anywhere else. I tried to use tools like flashtool, magisk, superuser, supersu and some others but obviously either they didn't do the trick, require I do things I don't understand, require I intstall and use other tools I don't have, or they didn't work at all, or the descriptions on how to install and use them were so unclear that I didn't even get them installed or they crashed right upon start.

So please don't post the usual "have you read this ... " thread pointers, chances are high I have read it, and tried to do like described, but got stuck at some point where things don't work like described, rendering the whole thing useless. I will happily follow hreads, however, if you are confident that the information given is accurate for the XZ ( F8331) on Android 8.0.0 and up to date (9/2018).

Desaster status:

I think I have successfully unlocked the bootloader (using flashtool 0.9.24), since the phone when rebooted gives me a yellow warning that the device must be considered unsafe. This is also where Flashtool drops out, the next step (root the phone using SuperSu oder SuperUser) fails with a fairly non-helpful error message that "The part1 exploit did not work".

This is what flashtool has to say on loading:
[FONT="Courier New"][SIZE="1"]05/044/2018 10:44:27 - INFO - Flashtool Version 0.9.24.4 built on 01-02-2018 22:15:00
05/044/2018 10:44:27 - INFO - Searching for a web proxy
05/044/2018 10:44:34 - INFO - No proxy found, using direct connection
05/044/2018 10:44:35 - INFO - Syncing devices from github
05/044/2018 10:44:35 - INFO - Opening devices repository.
05/044/2018 10:44:35 - INFO - Scanning devices folder for changes.
05/044/2018 10:44:40 - INFO - Pulling changes from github.
05/044/2018 10:44:40 - INFO - Devices sync finished.
05/044/2018 10:44:41 - INFO - Loading devices database
05/044/2018 10:44:41 - INFO - Loaded 115 devices
05/044/2018 10:44:41 - INFO - Starting phone detection
05/044/2018 10:44:51 - INFO - Device connected with USB debugging on
05/044/2018 10:44:52 - INFO - Connected device : Sony Xperia XZ
05/044/2018 10:44:52 - INFO - Installed version of busybox : N/A
05/044/2018 10:44:52 - INFO - Android version : 8.0.0 / kernel version : 3.18.66-perf-g27418207c1b5-04571-gda413b97f3a4 / Platform : 64bits / Build number : 41.3.A.2.184
05/044/2018 10:44:52 - INFO - Root access denied[/SIZE][/FONT]

And this is what it says when I try to Root:

[FONT="Courier New"][SIZE="1"]05/046/2018 10:46:07 - INFO - Pushing C:\Flashtool\custom\root\PsNeuter\psneuter.tar.uue to /data/local/tmp
05/046/2018 10:46:07 - INFO - Pushing C:\Users\Linder\.flashTool\devices\busybox\1.20.2\busybox to /data/local/tmp/busybox
05/046/2018 10:46:07 - INFO - Pushing C:\Flashtool\custom\root\subin\Supersu\su to /data/local/tmp/su
05/046/2018 10:46:07 - INFO - Pushing C:\Flashtool\custom\root\subin\Supersu\Superuser.apk to /data/local/tmp/Superuser.apk
05/046/2018 10:46:07 - INFO - Pushing C:\Flashtool\custom\root\subin\Supersu\install-recovery.sh to /data/local/tmp/install-recovery.sh
05/046/2018 10:46:08 - INFO - Pushing C:\Flashtool\custom\root\subin\Supersu\99SuperSUDaemon to /data/local/tmp/99SuperSUDaemon
05/046/2018 10:46:08 - INFO - Running part1 of Root Exploit, please wait
05/046/2018 10:46:08 - INFO - Running rootit
05/046/2018 10:46:08 - INFO - Waiting for device. After 60secs, stop waiting will be forced
05/050/2018 10:50:06 - INFO - Forced stop waiting.
05/050/2018 10:50:06 - ERROR - The part1 exploit did not work
05/050/2018 10:50:06 - INFO - Cleaning files[/SIZE][/FONT]

Note that when Androxyne expects 60s, it is in fact 4 minutes, before the program recovers from the error.

I went with flashtool, because this brought me the farthest, other approaches like Magisk failed because they rely on me having mysterious images of something, which I don't have, and/or make use of some other mysterious tool (TWRP) which I am usure where to get, how to use, and how it fits into the Magisk process, or make choices in a bootloader which never appears on my Xperia (screen is just black/blank if I boot in fastboot or flashmode or use commands like "adb reboot bootloader"

Thanks to the forum restrictions I am also forced to post here, instead of using the correct section where it's all about ROMS and firmwares, sorry for that, but I had no choice.
Anyone who is able to give me a hand and help me out?#
Thanks, Armin[/QUOTE]

wow! this is the first time i am reading some one has unlocked the xz this way :eek: ..

anways if the device is unlocked (as you say that warning is coming on every boot) then....

1. your flashtool version is OUTDATED, and for OREO it doesnt work ! it should be latest (as of now its (0.9.25.0) )

2. inbuilt rooting methods/EXPLOITS given in flashtool doesnt work for XZ,

3. simply flash twrp , DOWNLOAD IT FROM HERE

4. now take the appropriate kernel & DRMFIX.zip file from H E R E

5. download magisk & magisk Manager

6. put kernel.img , drmfix.zip, magisk17.1.zip & MagiskManager6.0.x.APK in the SD CARD of your XZ

7. [ rename the file to twrp.img and put it in [C:\Program Files (x86)\Minimal ADB and Fastboot] ] open minimal adb &fastboot, connect device in fastboot mode (blue LED) & type" fastboot flash recovery twrp.img " (without quotes ) & Enter. now disconnect the device, press volume down and power & keep pressing until you see the twrp.

8. goto install, click install IMAGE FILE, point to kernel.img from that SD CARD, select BOOT partition (very important) and do it.

9. now flash drmfix.zip, then magisk17.1.zip and clear cache and reboot device!

you are DONE!

p/s:- you can flash supersu instead of magisk but magisk has its own benefits :) and supersu is discontinued.