yashsingh1/xdaforums huggingface dataset:
[Xperia Z3 General] The Android Robot:
Try installing Neo Busybox

https://play.google.com/store/apps/details?id=com.polarbearsoftware.neobusybox

That is currently the only BusyBox installer that works with RecRoot.

1. Install BusyBox with that installer

2. Reboot to recovery

3. Flash RecRoot v3

Note that steps 2 and 3 are optional, as you should have a functioning BusyBox and recovery after the first step, but do it if you want to be extra sure.

NB: Although something bad is unlikely to happen, I am not responsible

Good luck ;)
[Xperia Z3 General] Wolfbreak:
LB/UB supported [Windows/Flashable]

Hey guys i present you RecRoot v4.

Please report back if it works!

Instructions

You need to have Root already and a Windows PC or working Recovery

Run install.bat on Windows and connect Phone or flash in your already working Recovery to keep Root

The Windows Variant only installs Recovery

Features

New TWRP 3.0.2 Recovery from shoey63

ByeSELinux

RIC Defeat

Fixed sqsh mount in Script

Recovery uses its own Busybox now

Updated Busybox to 1.24.2

SuperSU 2.71 in System Mode

Download

Download RecRoot Combined v4 for Android 6.0.1 Marshmallow [all MM Firmwares supported]

Credits

serajr for Scripts

shoey63 for Recovery

NUT for his Scripts

zxz0O0 for ByeSELinux and RIC Defeat

Chainfire for SuperSU
[Xperia Z3 General] CAL7:
If already running and working, do you recommend updating v3 to v4 ?
[Xperia Z3 General] Licaon_Kter:
You mean re-make the ZIP from FTF+dummy+Recrootv4 and reflash that? Nope, no reason to do that.

Althout, having said that, I guess I'll remake my ZIP to have the latest one on hand just in case. ;)
[Xperia Z3 General] batrian:
Thank you!! This is great news. and probably i'm being greedy. but what happens if beta updates? are we getting OTA right? Do they check IMEI?

Thanks
[Xperia Z3 General] Wolfbreak:
This might be related to the new way Sony handles odex on Z3 MM Update. The odex files are now located in oat/arm in every app and priv-app Folder and are just symbolic links to the real odex which is located in sqsh files. Maybe Titanium Backup cannot handle this but im not sure, its just a guess.
[Xperia Z3 General] Allewar:
Are you using this root solution for the z3 compact?

Enviado de meu D5803 usando Tapatalk
[Xperia Z3 General] ondrejvaroscak:
I think he is

---------- Post added at 12:08 AM ---------- Previous post was at 12:07 AM ----------

Yes.... That can be
[Xperia Z3 General] Allewar:
Im about to try the beta rom and I was planning on using titanium backup to restore my apps now that we have root ?...

It's not working hun?

Enviado de meu D5803 usando Tapatalk
[Xperia Z3 General] Pandemic:
Never restore apps to get issues, install everything brand new to get no issues !
[Xperia Z3 General] Marília de Oliveira:
Here I can restore normally but not via flashable but by the same folder. ta working :D
[Xperia Z3 General] ondrejvaroscak:
I would never use TB to move apps and settings between ROMs.
[Xperia Z3 General] Gustavo RD78:
to debloat for example is recommended to extract the rom files designated for example for:

app folder the file is odex.app.sqsh

on a Linux machine you can unpack and pack this file

thus becomes totally customizable

the same process is used to deodex
[Xperia Z3 General] lamducthien:
Waiting for z3c
[Xperia Z3 General] Gustavo RD78:
hello

you who have unlocked bootloader, I posted the kernel in section Z3c :good:
[Xperia Z3 General] Allewar:
It's working on the z3 compact already. I tested here and everything works fine.

Enviado de meu D5803 usando Tapatalk
[Xperia Z3 General] serajr:
Thank you mah!

I really don't know! That's the question!!

But there will be one for some advanced Home settings, as you already know ;)

You're right, but you can face systemui bootloop due some code injected directly in its creation method!

I didn't have time to check its compatibility yet, but I will do it when I have some spare time.
[Xperia Z3 General] lamducthien:
Can you give me intruction
[Xperia Z3 General] :
Awesome job on the root. Not much developers we can rely on for our device.
[Xperia Z3 General] nhuduy:
I have idea

I think this beta rom use kernel 3.4.

Why don't flash kernel of 5.0? we maybe have recovery. We can flash somefile.

After we flash file, we flash kernel 3.4 of beta and everything is ok. We can have recovery and we still stay beta 6.0
[Xperia Z3 General] ondrejvaroscak:
Yes, it would work but recovery works already in [MENTION=4675598]shoey63[/MENTION] kernel for beta.
[Xperia Z3 General] doresreturns:
Hi, I tried to boot into recovery many times using power+vol down but it just boot directly into Home. I'm on unlocked bootloader.

What I did was flash rootable Kitkat rom then Root+install XZDR using giefroot and XZDR installer then I did

fastboot flash recovery recovery.img

with shoey's new TWRP.

Then I just wipe and restore the beta 6.0.1 rom. I tried to

fastboot flash boot boot.img

(with mm-beta_permissive_no-RIC.img from OP) but no luck. I can't boot into recovery at all.

Now I'm temporarily rooted using KingRoot with system R/W access but I would love to have TWRP too.

I don't even know if there is any mistake in my procedure. What should I try next? I'm confused.

Thank you in advance!
[Xperia Z3 General] Allewar:
Can you link?
[Xperia Z3 General] chris_g92:
finally mm gj guys the fix works perfect for touch reset... mm is faster than light amazing... Anyone knows hot to fix the nav remains black even u change theme?
[Xperia Z3 General] bowyerv:
Still not working on mine

Thanks for the update. Running the batch file restarted the phone this time whereas V3 didnt. But still unable to boot into recovery. :(
[Xperia Z3 General] Wolfbreak:
What ROM and did you installed Busybox? Is chargemon and chargemon.stock present in system/bin? Also check in system/etc if mm_twrp_recovery folder is present and if the 3 files are present. Did you use stock kernel or custom kernel? These are the only Questions i can think of that could be the Problem.
[Xperia Z3 General] bowyerv:
ROM: [6.0.1][D6653] Z3 - 23.5.A.0.570, so stock rom and kernal

mm_twrp_recovery folder is present with its three but only two files:

boot_twrp_recovery.sh (rwxr-xr-x) and

recovery.twrp.cpio.lzma (rw-r-r-)

Busybox? Root checker verifies it as version 1.24.2-Stericson
[Xperia Z3 General] petrmelis:
Boot into the recovery is only possible by power+vol.down. QuickBoot or similar apps does not work. So make sure you try right way.
[Xperia Z3 General] Wolfbreak:
Thats the Problem then. Copy the busybox manually from RecRoot zip into the Folder with 755 rights and let me know.
[Xperia Z3 General] Captain-Platano:
Hey thanks a lot bud! I've been trying to root this darn phone for the past few days. Anyway, I flashed the mm-beta_permissive_no-RIC.img, but when holding down the Power+VolDown buttons it didn't want to go into recovery. But this boot image worked perfectly fine! Thanks again dude! :D
[Xperia Z3 General] bowyerv:
I cant copy busybox into the folder - permissions!

Must mean my SU is not working properly, eventhough it appears to be there and Root Checker pro says its rooted. ?!?
[Xperia Z3 General] okij:
Thanks a lot, it's working great on my Z3c on stock rooted 570 firmware! Before flashing I replaced the two recovery.twrp.cpio.lzma files in your zip with TWRP 3.0.2.0 from the Z3c thread.

Two questions though:

Is it still necessary to replace recovery.twrp.cpio.lzma, or are they compatible between Z3 and Z3c by now?

In TWRP 3.0.2.0, it's not possible to select the TA partition to make a backup of it. I'm sure it worked before (at least with TWRP 2.8.7.0 under LP). Maybe [MENTION=4675598]shoey63[/MENTION] can answer this!?
[Xperia Z3 General] shoey63:
I think I removed TA backup option in case of noobs sharing backups and restoring TA on a different device. Plus surely everyone has one by now. There is an option to flash TA images lurking under the hood in though. Obviously for emergency scenarios only. One recovery.twrp.cpio.lzma should work for Z, Z2 and Z3c. Flashable recovery zips are in This post if needed.
[Xperia Z3 General] okij:
OK, that's quite understandable. :)

But is it possible to restore a TA backup that was made of an Anroid 4.4.4, 5.0.2 or 5.1.1 installation (which I keep on my HD and SD-Card just in case) on an Android 6.0.1 installation? Somewhere I read that the contents of the TA partition change when updating the OS. Do you know if the TA backup files are backwards (or in this case forwards) compatible?

Of course it's always possible to use Backup-TA-9.11 for making a TA backup, but having also a current TA backup made with TWRP makes me feel more secure.

I think that's not true because also in the post you linked to you compiled three different recovery.twrp.cpio.lzma files.

Wouldn't it be possible to compile a single TWRP executable that works on the whole Z, Z2, Z3 and Z3c line by implementing a check for the display resolution (Z, Z2 and Z3: 1920x1080, Z3c: 1280x720) and starting TWRP accordingly? Or are there other major differences between these devices to consider?

If there was only one single TWRP executable, we could use [MENTION=2822871]Wolfbreak[/MENTION]'s RecRoot on different devices without having to worry if recovery.twrp.cpio.lzma is the correct one and replacing it before flashing. :D
[Xperia Z3 General] AlbyTran:
Sorry all this information is a bit overwhelming and technical for me to understand all of it. Is there a difference in creating a Pre-rooted firmware compared to lollipop? In lollipop, I add nut dual recovery, the ftf and SuperSU. How do I make a Pre-rooted firmware now that recroot is here? Thanks in advance
[Xperia Z3 General] shoey63:
The TA changes all the time, even without changing firmware (Except the DRM part). I Have personally restored TA backup taken on stock KK and restored on concept MM. No dramas at all.

You can put Backup-TA-9.11 TA.img on your sd card and use the install image function to flash it to Trim Area (Use md5sum command in twrp terminal first to make sure it matches)

That's mainly mainly to to do with build.prop being different for each device. (In case you flash a zip that checks the model). TWRP automatically adjusts resolution for portrait devices with the TW_THEME := portrait_hdpi flag.

That would need [MENTION=2822871]Wolfbreak[/MENTION] to make serious modifications to his zip - If he were to have the time or the inclination to do it;)
[Xperia Z3 General] The Android Robot:
Amazing job. :good:

You are a legend.

Tested on:

Own made pre-rooted 23.5.A.0.570 on D6603.

Although... How can I access the TA backup option in TWRP? Seems like it has been disabled.
[Xperia Z3 General] ondrejvaroscak:
http://xdaforums.com/z3/general/wip-sony-android-6-0-mm-t3337357/post66705005
[Xperia Z3 General] The Android Robot:
For Lollipop:

Firmware FTF as firmware file, SuperSU zip as SuperSU file and [NUT]'s XZDR zip as recovery file in PRFC.

For Marshmallow:

Firmware FTF as firmware file, dummy flashable as SuperSU (I did it with real SuperSU zip instead of dummy, doesn't make a difference), RecRoot v4 as recovery file in PRFC.

---------- Post added at 12:48 AM ---------- Previous post was at 12:45 AM ----------

I saw that post before, but couldn't get to the bottom of this as how to enable the option for backing up TA. Anyway, I'll just be using BackupTA with PC. It was a dumb question. Thanks
[Xperia Z3 General] fluffi444:
Many thanks for this nice updated TWRP... Do you see any possibility to bring back TA backup option?

In restore option the TA partion shows up (in one of my prior made backups). But besides this FOTA is missing in Restore - But availbale in Backup... Maybe a mismatch somewhere? Or maybe just a problem of partition differences between LP and MM?

This is because you changed file names in recovery from FOTAKernel to recovery_fota - so no issue at all - sry :)

I really liked the option in older TWRP version because of switching between Custom (stock) Kernel with (lets say) bad TA - And 100% stock kernel with valid TA... UB/LB on the fly :)

I use your TWRP right now with AndroPlusKernel V72 (removed his 2.8.7 out of ramdisk and replaced it with your Z3C version and repacked boot.img) - Works very good!
[Xperia Z3 General] fluffi444:
Made it the quick and dirty way for myself... :o

Just edited complete recovery.twrp.cpio in HexEditor finding the responsible flag (originally in twrp.fstab)

/ta	emmc	/dev/block/platform/msm_sdcc.1/by-name/TA flags=backup=0;flashimg=1;display="Trim Area"

to

/ta	emmc	/dev/block/platform/msm_sdcc.1/by-name/TA flags=backup=1;flashimg=1;display="Trim Area"

Voila - Backup TA is back.... Thanks again for your work! This pushed me a bit further to understand "things" a bit more ;)
[Xperia Z3 General] shoey63:
Glad you worked it out. Yup, that's the flag alright. I was about to do exactly the same thing for you. Thanks for showing some initiative and saving me the time:good:
[Xperia Z3 General] okij:
Thanks for sharing this! :)

Just one question: How did you re-compress to lzma format? I used ZArchiver app for extracting recovery.twrp.cpio and patched it with Hex Editor, but ZArchiver cannot re-compress to lzma format.
[Xperia Z3 General] juanpirulo:
I do it on linux with lzma command i cant tell you now how exactly is because i am not at home. I will get you the exact command when i get home if nobody get you till then. Cheers

Enviado desde mi D6603 mediante Tapatalk
[Xperia Z3 General] fluffi444:
Actually for me it was not needed to repack it to lzma. In AndroPlusKernels Ramdisk its just a plain recovery.twrp.cpio.... Lucky me ;)

I guess you need to us linux?! Or maybe Cygwin could works this out also....

EDIT

Cygwin works - https://cygwin.com/install.html

Put files to work with in C:\cygwin64\home\*Your Username*

Decompress

$ unlzma recovery.twrp.cpio.lzma

Compress

$ lzma recovery.twrp.cpio

Here is an easy to understand Decompress/Compress/Modify howto - just replace initrd.img with "our" filename

https://sites.google.com/site/sridharlreddylinux/linux-t/initrd-img

With this you can actually modify the decpmpresse recovery.twrp.cpio the "correct way".

EDIT2

recovery.twrp.cpio.lzma with TA Backup and LTALabel (Certificates info) activated for Z3C. [MENTION=4675598]shoey63[/MENTION] - call if you want me to remove this. I respect your whish to protect the innocent.

EDIT3

Little update - LTALabel now emmc (not ext4) with default - No listed in mountable anymore.

See Post #605
[Xperia Z3 General] okij:
[MENTION=4962787]fluffi444[/MENTION]: Thanks a lot for the infos and also for your patched binary! I just installed it and it's working fine!

[MENTION=4675598]shoey63[/MENTION]: IMHO fluffi444's file can stay online because it's not simply flashable (i.e. people who know where to copy the binary to should also be skilled enough not to misuse the TA backup and restore capabilities.) ;)
[Xperia Z3 General] shoey63:
Not only leave it there, but share it on Z3C forums if you see other users requesting it. I think the majority won't miss it though. Most don't know what it's for or how to use it.
[Xperia Z3 General] dex87xda:
[MENTION=4962787]fluffi444[/MENTION] can u make for z2? ?
[Xperia Z3 General] fluffi444:
OK - will do so. Thought about to post a AndroPlusKernel with new TWRP in ramdisk. But also users on DualRecovery can change easily just by copying. And maybe also [MENTION=4904057][NUT][/MENTION] is interested to use your new TWRP

Made all 3 new again with same (a bit cleaned) code for needed files. With TA Backup and LTALabel Backup.

Now I finish hijacking this :)
[Xperia Z3 General] flatpedals:
I have a little situation here. on a D6603.

Was running LP, unlocked, andropluskernel, root, xposed. happy.

Relocked bootloader with flashtool.

Updated to N preview using xperia companion.

Unlocked bootloader with flashtool.

That new bootloader, nexus style, was telling me safe boot off and unlocked bootloader.

Wasn't satisfied with the lack of root on N preview, so I decided to go back to stock LP via Xperia Companion. Then I found out the lastest update Xperia would flash is MM. I said fine.

Tried to relock bootloader with flashtool, I got ok message but it didn't relock the bootloader. tried a lot of times, different pc, flashtool version, regenerated code. nothing. so no Xperia Companion - no big deal, I just have an obsession with latest official builds, since my main device is a Nexus5. oh, what a nice girl that is. and easy to undress. :)

flashed a LP .ftf, tried to relock bootloader, no success.

fastboot flashed andropluskernel then RXSW 3.0 from TWRP.

At first boot with RXSW I could enter TWRP 3.0.2, then nothing. This bull**** seems to be busybox related, which I've installed. I haven't tried without it yet. This isn't my real problem.

later edit: without stericson busybox that I used to install on every device, I can enter TWRP on RXSW 3.0.

What the heck happened with the relocking of the bootloader??!!

I'm thinking it has something to do with the new bootloader from N preview which I was running when I unlocked it. Now it won't relock on any version.

---------- Post added at 09:56 PM ---------- Previous post was at 09:19 PM ----------

also, [MENTION=631273]Chainfire[/MENTION]'s FlashFire worked like a charm on Z3 D6603, RXSW 3.0. During my dark days of no recovery access :) the only thing I noticed: it hangs at times in fastboot backup at 'scanning' partitions.
[Xperia Z3 General] arminbih:
Hey guys, a little help pls wanted to install recovery on my stock z3 so I can install custom prerooted roms, but when I run recroot install, phone does not reboot into recovery. Do I need to flash 5.1.1 first and root it or what?
[Xperia Z3 General] flatpedals:
flash LP .ftf then andropluskernel. now you have recovery access. have fun
[Xperia Z3 General] arminbih:
I don't want to unlock bootloader but thx
[Xperia Z3 General] DiLeon:
should the Z2 version also work for the Z2 Tablet (SGP521)?
[Xperia Z3 General] flatpedals:
locked booloader but still prerooted custom roms. purpose of keeping it locked? apart from making your life miserable ? :)

You can relock the bootloader in no time.

If it's not messed up like mine after an encounter with the N preview version. :)

---------- Post added at 10:04 AM ---------- Previous post was at 09:47 AM ----------

anyway, if you still want to keep it locked, follow this:

http://xdaforums.com/z3/general/guide-rootrecovery-how-to-root-install-t3017056
[Xperia Z3 General] nailyk:
Your are right, afaik new bootloader can't be relocked. Also don't try to cross restore TA partition between bootloaders version and ta backups. (TA backups made with bootloader v15 should be restored only on v15 bootloader).
[Xperia Z3 General] flatpedals:
I don't have any TA backup nor did I restore any.

so, what's it in for me? can I relock it? do I have to go back to N preview to lock it?

I've noticed many times when I unlocked/locked it that flashtool was returning a TA partition code along the 'ok' message. After N preview it just says 'ok', but the code is blank. So there's a mess up.

I don't need it to be locked but I'm just wondering why the problem.

I mean as long as I'm running MM now, why doesn't it lock? same with any other versions.
[Xperia Z3 General] nailyk:
That is it: with v15 bootlodaer, unlocking change two things in the TA partition: it write the oem unlock code in a specific location, and change a bit from 0 to 1.

With the v35 (v37? can't remember) bootloader which, I suppose, is only available for unlocked phone, this TA locations doesn't exist anymore, bootloader is always unlocked. No way to get back....

Edit: upgrading an 'open device' with the official sony tool with a rom >.200 always upgrade bootloader.
[Xperia Z3 General] flatpedals:
So let me get this straight.

Once I've updated to N preview I got the new bootloader.

It stays the same even if I get back to LP?

Should't TA partition be back there if I downgrade to LP or MM?

Sorry, but my head is stuck with the nexus devices and I don't get this boot/recovery/TA mix-up on Sony here quite clear.
[Xperia Z3 General] nailyk:
That is it.

I don't think so but never try. One thing, many ftf on xda provide bootloader built-in so be careful! IMHO the safest way to try this is to downgrade via the official sony flashtool (emma).

As TA partitions and bootloaders versions seems to be incompatible it should. If not it will hard brick the device :(

Empathize with that! It take me a lot of RE to understood what is going on with this sony Z devices..... But once the bootloader get upgraded the big advantage is your always be able to boot the recovery in your FOTAKernel partition.

P.S.: I never make experiences on this, all think I wrote are based on partitions analysis and googlefoo.

And sorry for my out-topic answers :o
[Xperia Z3 General] ioannis.baptista:
"Error flashing zip. No MD5 file found." :(
[Xperia Z3 General] Licaon_Kter:
UNcheck MD5 verification in settings?
[Xperia Z3 General] serajr:
It is not a flashable zip! Read the install instructions!!
[Xperia Z3 General] ioannis.baptista:
Sorry, I'm still newbie on this thing. I just upgraded from Android 5.1 to 6.0 using a custom ROM using TWRP, but the recovery app is gone. I reinstalled NDR Utils from Google Play, but it asks for the core files. So, I'm looking for a way to flash it again.
[Xperia Z3 General] Wolfbreak:
You can flash RecRoot in Recovery but NDR Utils is only for XZ Dual Recovery which is not working for Marshmallow.
[Xperia Z3 General] :
I created a prerooted Rom using RecRootV3_combined. Can I update this by flashing this file in my Recovery? Or have I to create a new prerooted ROM?
[Xperia Z3 General] Licaon_Kter:
If everything works ok (recovery is accesible and you have root) there is no need to reflash anything.

Although you could re-make the ZIP with the new RecRootV4 say if you need it in the future.
[Xperia Z3 General] Mohitash:
Hello everyone,

So, i am on official 6.0.1 on my D6653 (Officially updated to MM after flashing LP ftf)

Now at this time i just want root and busybox on my D6653 with pure stock MM without unlocking bootloader just to prevent from that image enhancement/quality stuff (DRM) as i can't find any thing to restore that on MM.

So, any way to do that?

Thanks in advance

Mohitash