[DEVDB][TWRP][PhilZ Touch] XZDualRecovery 2.8.26 RELEASE

Search This thread

[NUT]

Senior Member
Last edited:
  • Like
Reactions: californicated

[NUT]

Senior Member
[DUAL RECOVERY] Version 1.4 released

Well, it took a little longer :p found some other stuff... 1.3 feels like a rush job now, while it was far from it :eek:

Change log:
Version 1.4:
  • Since the step up to the .cpio.lzma archives it stopped working for some, while for others it kept working... this was due to busybox versions lacking the lzcat for the unpacking process. This recovery now flashes/installs a busybox into /system/bin which supports it.
  • Loads of various and tiny tidbits in the scripting.
  • Fixed a small bug in the SDCard1 mounting functionality.
  • When an SDCard1 is found, it now cleans up /cache/chargemon.
  • Switched the keycheck file location to /dev (as it is actually a tmpfs filesystem)
  • Added a vibration to signal it's time to punch a button.

All files are now available on http://www.fun-industries.nl/xda/

Well, enjoy!
 
Last edited:

RoberM

Senior Member
Oct 12, 2011
253
121
ESPAÑA
Just installed 1.4 over standard CWM and now no recovery works, it doesn't matter if I use vol up or vol down, all I get is purple led forever.


19700123 122045: ### SDCard1 FS found: FAT32 with code 'Win95'.
19700123 122045: ### Not mounting SDCard1!
19700123 122045: ### Logfile rotation...
19700123 122045: /system/xbin/busybox mv /cache/chargemon/chargemon.log /cache/chargemon/chargemon.log.old
19700123 122045: RET=0
19700123 122045: /system/xbin/busybox touch /cache/chargemon/chargemon.log
19700123 122045: RET=0
19700123 122045: /system/xbin/busybox chmod 660 /cache/chargemon/chargemon.log
19700123 122045: RET=0
 
Last edited:

[NUT]

Senior Member
Just installed 1.4 over standard CWM and now no recovery works, it doesn't matter if I use vol up or vol down, all I get is purple led forever.


19700123 122045: ### SDCard1 FS found: FAT32 with code 'Win95'.
19700123 122045: ### Not mounting SDCard1!
19700123 122045: ### Logfile rotation...
19700123 122045: /system/xbin/busybox mv /cache/chargemon/chargemon.log /cache/chargemon/chargemon.log.old
19700123 122045: RET=0
19700123 122045: /system/xbin/busybox touch /cache/chargemon/chargemon.log
19700123 122045: RET=0
19700123 122045: /system/xbin/busybox chmod 660 /cache/chargemon/chargemon.log
19700123 122045: RET=0

:eek:

That's what this version is supposed to fix, lol :silly:

Can you open up a terminal app and execute /system/bin/busybox
Please let me know what version it says it is and search the commands it supports if it has lzcat as a command.

I hope you created a backup of your original chargemon script as instructed in the OP, thats your easy way back to your previously installed CWM.

[EDIT]

Doh! I think i know whats wrong, you probably have a busybox inside /system/xbin ... that is probably being used, can you repeat the above instructions on /system/xbin/busybox ?
 
Last edited:

cron0s879D

Senior Member
Apr 2, 2013
110
5
Barcelona
Hi!

Thank you for your job.

I would like install TWRP 2.5.0.0 in my new Lenovo A820 (based in MTK6589).

Anyone can say me how to install it?

I don't found any tutorial for install TWRP for my phone.

Thank you!
 

RoberM

Senior Member
Oct 12, 2011
253
121
ESPAÑA
:eek:

That's what this version is supposed to fix, lol :silly:

Can you open up a terminal app and execute /system/bin/busybox
Please let me know what version it says it is and search the commands it supports if it has lzcat as a command.

I hope you created a backup of your original chargemon script as instructed in the OP, thats your easy way back to your previously installed CWM.

[EDIT]

Doh! I think i know whats wrong, you probably have a busybox inside /system/xbin ... that is probably being used, can you repeat the above instructions on /system/xbin/busybox ?

Previously i had busybox 1.21.0 installed in /system/xbin/ (i used BusyBox Free app from the store to update it, because i was having some problems with a mod), after installing your package i had my previous Busybox in it's place and a new one (v1.20.2-jb) in /system/bin, but when starting your recovery script it was trying to use the busybox in /system/xbin, so i moved your busybox from bin to xbin and now i can boot into TWRP with vol-down. But when using vol-up i only get a black screen with purple led.

I will try updating from scratch to 1.5 later and see what happens.

Also, my SD card is not mounting, it is a Sandisk Extreme with factory format (Fat32), your script identifies it as "FAT32 with code 'Win95'." and refuses to mount it, see my previously posted log above. So i have the logs in cache and no new folder in sdcard1. Also i think this has something to do with CWM not booting on my phone.

BTW, thanks for your hard work.

EDIT: I took a look at your flashable install script in v1.5, it seems it is still copying busybox to /system/bin, but setting permissions on busybox located in /system/xbin/, my knowledge on linux scripting is very limited, so i may be wrong.
 
Last edited:

brockyneo

Senior Member
Jan 17, 2010
3,683
397
In The Matrix
CWM
'TWRP' is not recognized as an internal or external command,
operable program or batch file.
script created by krabappel2548, modified by [NUT]

=============================================
Step1 : Waiting for Device.
=============================================
adb server is out of date. killing...
* daemon started successfully *
Succes
.
=============================================
Step2 : Sending the recovery files.
=============================================
mkdir failed for /data/local/tmp/recovery, File exists
0 KB/s (57 bytes in 1.000s)
1952 KB/s (239920 bytes in 0.120s)
877 KB/s (8981 bytes in 0.010s)
2569 KB/s (657704 bytes in 0.250s)
2825 KB/s (2632572 bytes in 0.910s)
2833 KB/s (1479825 bytes in 0.510s)
2393 KB/s (735308 bytes in 0.300s)
79 KB/s (1622 bytes in 0.020s)
.
=============================================
Step3 : Setting up files system partition.
=============================================
remount rw /system
remount rw /
copy recovery.tar to system.
5141+1 records in
5141+1 records out
2890+1 records in
2890+1 records out
rename stock chargemon
copy ric
0+1 records in
0+1 records out
copy charger
468+1 records in
468+1 records out
copy hacked chargemon to system.
dd: can't open '/data/local/tmp/recovery/chargemon': No such file or directory
new busybox to system.
dd: can't open '/data/local/tmp/recovery/busybox': No such file or directory
make file for faster backup

/sdcard/clockworkmod/ already exists!
error: device not found

=============================================
Installation finished. Enjoy the recoveries!
=============================================

hi nut i get this when finnished flashing and it reboots but doesnt install the recoverys any ideas please

thanks
 

[NUT]

Senior Member
Previously i had busybox 1.21.0 installed in /system/xbin/ (i used BusyBox Free app from the store to update it, because i was having some problems with a mod), after installing your package i had my previous Busybox in it's place and a new one (v1.20.2-jb) in /system/bin, but when starting your recovery script it was trying to use the busybox in /system/xbin, so i moved your busybox from bin to xbin and now i can boot into TWRP with vol-down. But when using vol-up i only get a black screen with purple led.

I will try updating from scratch to 1.5 later and see what happens.

Please do, just to be sure. The fact that twrp starts means cwm should actually start too... unless the archive is damaged somehow... and that makes the full set of logs more important, from straight after a failed attempt. (see OP for locations)

Also, my SD card is not mounting, it is a Sandisk Extreme with factory format (Fat32), your script identifies it as "FAT32 with code 'Win95'." and refuses to mount it, see my previously posted log above. So i have the logs in cache and no new folder in sdcard1. Also i think this has something to do with CWM not booting on my phone.

Well... i believe it might be busybox related as well. But to be on the safe side:

AFTER updating to version 1.5

Open up a terminal app and execute the following line, and copy&paste the contents of /tmp/XZDualRecovery/test on to this thread:

Code:
/system/xbin/busybox fdisk -l /dev/block/mmcblk1 | /system/xbin/busybox grep "/dev/block/mmcblk1p1" > /tmp/XZDualRecovery/test

This will output the information on your SDCard1. I'll need that for comparison to my own output to spot the differences.

BTW, thanks for your hard work.

EDIT: I took a look at your flashable install script in v1.5, it seems it is still copying busybox to /system/bin, but setting permissions on busybox located in /system/xbin/, my knowledge on linux scripting is very limited, so i may be wrong.

Take a look at the system folder in there too, that's what gets extracted, you will notice the busybox executable being in the right spot there. update-script can be a bit confusing, but I gave it the order to extract 'system' from the zip and put it in to 'system' on the phone, that means all of the zip's contents, so it will extract busybox into /system/xbin/ :)

And: you are very welcome, I'm glad to be of service to the community, which has helped me a lot in the past :)
 
Last edited:

[NUT]

Senior Member
[SNIP]
copy hacked chargemon to system.
dd: can't open '/data/local/tmp/recovery/chargemon': No such file or directory
new busybox to system.
dd: can't open '/data/local/tmp/recovery/busybox': No such file or directory
make file for faster backup
[SNIP]
=============================================
Installation finished. Enjoy the recoveries!
=============================================

hi nut i get this when finnished flashing and it reboots but doesnt install the recoverys any ideas please

thanks

Please re-download the installer package, there was a dumb mistake in the install script. :eek:
I've quick-fixed it, but its too small to do a new version as it is effectively just a release error :)

All the other lockeddualrecovery1.5.installer users should do the same!
 
  • Like
Reactions: brockyneo

zlebors

Senior Member
Jan 2, 2012
438
55
Jakarta
CWM
'TWRP' is not recognized as an internal or external command,
operable program or batch file.
script created by krabappel2548, modified by [NUT]

=============================================
Step1 : Waiting for Device.
=============================================
adb server is out of date. killing...
* daemon started successfully *
Succes
.
=============================================
Step2 : Sending the recovery files.
=============================================
mkdir failed for /data/local/tmp/recovery, File exists
0 KB/s (57 bytes in 1.000s)
1952 KB/s (239920 bytes in 0.120s)
877 KB/s (8981 bytes in 0.010s)
2569 KB/s (657704 bytes in 0.250s)
2825 KB/s (2632572 bytes in 0.910s)
2833 KB/s (1479825 bytes in 0.510s)
2393 KB/s (735308 bytes in 0.300s)
79 KB/s (1622 bytes in 0.020s)
.
=============================================
Step3 : Setting up files system partition.
=============================================
remount rw /system
remount rw /
copy recovery.tar to system.
5141+1 records in
5141+1 records out
2890+1 records in
2890+1 records out
rename stock chargemon
copy ric
0+1 records in
0+1 records out
copy charger
468+1 records in
468+1 records out
copy hacked chargemon to system.
dd: can't open '/data/local/tmp/recovery/chargemon': No such file or directory
new busybox to system.
dd: can't open '/data/local/tmp/recovery/busybox': No such file or directory
make file for faster backup

/sdcard/clockworkmod/ already exists!
error: device not found

=============================================
Installation finished. Enjoy the recoveries!
=============================================

hi nut i get this when finnished flashing and it reboots but doesnt install the recoverys any ideas please

thanks

ok mate thanks great work :angel:

the same as this error.. when reboot, it vibrate+grren light I pressed vol down..and now only blank screen with purple notification light
 

zlebors

Senior Member
Jan 2, 2012
438
55
Jakarta

Attachments

  • IMG-20130508-00038.jpg
    IMG-20130508-00038.jpg
    148.4 KB · Views: 562
Last edited:

[NUT]

Senior Member
I downloaded on the 1st post, and update the dualrecoveries.update.zip

Please re-download the installer package, there was a dumb mistake in the install script. :eek:
I've quick-fixed it, but its too small to do a new version as it is effectively just a release error :)

All the other lockeddualrecovery1.5.installer users should do the same!

Just to be sure, please download it again and install it without updating.

If it still doesn't work then, open a terminal app and execute /system/xbin/busybox and tell me what version it says it is.
 

zlebors

Senior Member
Jan 2, 2012
438
55
Jakarta
Just to be sure, please download it again and install it without updating.

If it still doesn't work then, open a terminal app and execute /system/xbin/busybox and tell me what version it says it is.

at that point, there was nothing I can do to trigger the ZL for fastboot or anything else..
then I open the simcard cover and there is a small yellow button with label "OFF"
I pressed it for 3seconds using a toothpick and the ZL restart and back in normal state.. phiiuuufffhhpphhhhh:eek:
 

[NUT]

Senior Member
at that point, there was nothing I can do to trigger the ZL for fastboot or anything else..
then I open the simcard cover and there is a small yellow button with label "OFF"
I pressed it for 3seconds using a toothpick and the ZL restart and back in normal state.. phiiuuufffhhpphhhhh:eek:

Ehrr.. pressing power+vol-up for some seconds will reboot your phone too, FYI :)

Does dual recovery work now? What version of busybox is installed in /system/xbin/ :confused:
 

Top Liked Posts

  • There are no posts matching your filters.
  • 691
    -=[XZDualRecovery]=-
    TWRP 2.8.7.0 & PhilZ Touch 6.59.0
    *** For Locked and Unlocked BOOTLOADERS! ***

    I proudly present you the first and only DUAL RECOVERY for locked boot loaders on our lovely Xperia phones! :cool:

    If you have an unlocked bootloader and chose to keep the STOCK Sony kernel, you can also use this MOD.

    Currently supported XPERIA models:
    These are also links to the device specific Q&A threads.
    Xperia Z: SO-02E, C6602, C6603, C6606, C6616
    Xperia ZL: C6502, C6503, C6506
    Xperia Tablet Z: SO-03E, SGP311, SGP312, SGP321, SGP351
    Xperia Z Ultra: C6802, C6806, C6833, C6843
    Xperia Z1: C6902, C6903, C6906, C6943, C6916
    Xperia Z1 Compact: D5502, D5503, D5506
    Xperia Z2: D6502, D6503, D6506, D6543, D6563
    Xperia Tablet Z2: SGP511, SGP512, SGP521, SGP551, SGP561
    Xperia ZR: C5502, C5503, C5506
    Xperia T, TX, TL and V: LT30p, LT29, LT30at, LT25i
    Xperia S: LT26i
    Xperia SP: C5302, C5303
    Xperia T2 Ultra: D5303, D5322
    Xperia Z3: D6603, D6633, D6643, D6653, D6616
    Xperia Z3 Compact: D5803, D5833
    Xperia Tablet Z3 Compact: SGP621, SGP641, SGP651

    I will be adding more and more devices to the list in the near future, keep your eyes on this thread for them to be released :)
    I will also start a Q&A thread for each of the models officially supported, once released from the experimental stage.

    XZDualRecovery User Manual

    Special Thanks:
    • DooMLoRD for all his excellent work on our much loved Sony phones!
    • The Team Win developers for TWRP
    • The ClockWorkMod developers for CWM
    • @alexocean for his awesome job testing almost all FW releases and the discovery of SuperSU causing problems for the installation of this recovery!
    • @RoberM for testing
    • @surdu_petru for testing and handy pointers
    • @Androxyde for allowing to use his linux and mac adb binaries.
    • @lancebukkake for finding the TWRP 'fix' to use exFAT formatted sdcards!
    • @delewer for the final fix for TWRP and its use of exFAT formatted sdcards
    • @DevShaft for some code help on the windows installer (the menu!)
    • @Androxyde again, but now for his bash code/script suggestions... oh boy this guy is a genius! :highfive:
    • @Tamirwig and @shoey63 for their excellent job at testing early BETA's (Xperia Z)
    • @gregbradley for his extensive testing on the Xperia Z1
    • @russel5 for his tinkering and general debugging help :cool:

    GitHub Repository:
    https://github.com/xNUTx/XZDualRecovery

    Downloads:
    All past, current and future releases will appear on http://nut.xperia-files.com/ for download, also providing a QR code for easy downloading on your mobile :) The flashable file will bring any previous version to the latest release.

    Well, enjoy! :fingers-crossed:

    The origins of this XZDualRecovery package are in the packages done by:
    Krabappel2548, Cpasjuste and DooMLoRD
    Thank you for your excellent work guys! :victory:
    Your thanks (and donations) should (also) go out to them, they deserve it! :highfive:

    XDA:DevDB Information
    XZDualRecovery, Tool/Utility for the Sony Xperia Z

    Contributors
    [NUT], AngelBob , shoey63 , Olivier, Krabappel2548, DooMLoRD, Cpasjuste, Tungstwenty, sijav, zxz0O0, MohammadAG, McBane87, oshmoun
    Source Code: https://github.com/xNUTx/XZDualRecovery


    Version Information
    Status: Stable
    Current Stable Version: 2.8.26
    Stable Release Date: 2016-02-22

    Created 2013-07-18
    Last Updated 2016-02-22
    250
    Hello guys,

    I noticed there are some problems getting dualrecovery to work on Lollipop. I created a small hack to bypass the SELinux enforcement (wonder why no one else created it already). Anyway I attached a little bat file to fix dualrecovery again (tested on Z3C).

    Source will be released in the next days and probably also integrated in the official dualrecovery.

    Happy eastern.

    Edit: Source available here https://github.com/dosomder/byeselinux
    136
    Known Issues and Frequently Asked Questions

    Known Issues:
    All known issues in PhilZ, TWRP and CWM on locked boot loaders apply, see their respective threads for more information.

    Busybox updaters can kill XZDualRecovery, see the FAQ below for more information.

    Frequently Asked Questions:

    How to set the correct time & date in PhilZ 6.59.0
    • Boot to PhilZ Touch;
    • Tap 'Recovery Settings';
    • Tap 'Gui Preferences';
    • Tap 'Time Settings';
    • Tap 'Change date and time';
    • Tic one of the last 3 options in this menu to try it;
    • Reboot to PhilZ Touch to see if it sticks, if not, try another and reboot to see if it helped, do this for all options to try them;
    • If one of them does help but does not stick at reboot, tic 'Try Force Persist on Reboot' once (it will un-tic itself after a reboot).
    • Done! :)

    NOTE: if it's close to being correct (max 15h difference before or after your time) you need to correct the timezone.


    About TWRP 2.6 and the use of INTERNAL STORAGE
    [snip]...but permissions are set like: Srw-Srw-r (644) (It seems like the 'S' is the problem, I'm sure GID and UID are ticked)...[snip]

    A workaround for this issue is to use TWRP's advanced options, after creating a backup you wish to move to the PC:

    1. go back to the main menu
    2. go to advanced
    3. go to filemanager
    4. navigate to /data/media/0/TWRP/BACKUPS/*SERIAL*/*BACKUPNAME*
    5. select one of the backup files
    6. press chmod button (the one without 755)
    7. type 0664 and press go
    8. repeat 5->7 for each of the files in the backup, you can skip boot and the md5 files.
    9. reboot to system and you should be able to copy the files without problems.

    Alternatively you can install adbd Insecure by @Chainfire (non-free app from Play, or for free from it's XDA thread) and run ADBd itself as root, which elevates the rights and omits the issue all together.

    I think it's a feature and not a bug (as it secures your backups), but I'll try to convince Team Win to make the setuid/setguid a choice rather then a default.


    Installation of XZDualRecovery on UNROOTED devices
    The 2.8.21 and older installer package uses Easy Root Tool for various Xperia phones, it is able to gain root on all of the currently supported devices, allowing to install XZDR.

    Confirmed working:
    • Z - C6603
    • Z1 Compact - D5503 (doesn't seem to work on JellyBean), SO-01F (docomo)
    • Z1 - C6903,
    • Z Ultra - C6802, C6833
    • ZR, C5502
    • Z2 - D6503
    • Z2 Tablet - SGP511, SGP512
    • ZL2 - SOL25

    If you want to help me perfect this list, use the tool done by @zxz0O0 in his topic and try to root your device. When testing also try older ROM versions, the latest FW versions may have been patched.

    Thanks @zxz0O0 for the initial list.

    The rootless installation has been made possible by:
    • @geohot: Root exploit
    • @MohammadAG: Disable RIC kernel module (Link)
    • @cubeundcube: Disable RIC on Z2 phone (findricaddr/writekmem)
    • @zxz0O0: for creating the initial tool where I have based this unrooted install option on.

    Thanks for your hard work guys! :highfive:

    The 2.8.22 and later installer package uses rootkitXperia for various Xperia phones, it is able to gain root on all of the currently supported devices -if they are running the correct Lollipop version- allowing to install XZDR.

    Thanks go to @cubeundcube and @zxz0O0 respectively for developing and making some changes to allow me to utilize it for XZDualRecovery installation. Thanks guys!


    XZDualRecovery's (2.8.21 and older) Busybox dependency and compatible Busybox updaters

    Busybox Updater/Installer: If you have XZDualRecovery installed, un-install any Busybox updating app/tool as most if not all of them will install a version of busybox which does not support the lzma compression applets XZDualRecovery depends on. The version installed together with XZDualRecovery is very stable and I have yet to hear anyone complain about it's stability.

    @vaisakh7 found a busybox updater which seems to be compatible with XZDualRecovery: Busybox On Rails, which installs a version of busybox created by stericson, which leads me to believe his Busybox installer should also install a version which works together with XZDualRecovery.

    Either case, be careful with updating busybox as there still is a possibility it will break your ability to enter recovery or even break full root, which means you might not be able to recover from the broken situation. Your best bet is the installer version, using that to break the lock on the system partition and reinstall the correct busybox.

    XZDualRecovery 2.8.22 and newer do not suffer from this dependency, you can use whatever busybox updater app you like when you have 2.8.22 or newer installed.


    I installed XPOSED on Lollipop and now I am experiencing a boot loop!

    @ondrejvaroscak found a workaround to fix your bootloop issues: [WORKAROUND] Bootloops with Xposed in Lollipop

    While using the installer I get the message "This device is unauthorized" and I can't install XZDualRecovery!

    Authorizations... The latest versions of adb and android need this, it's nothing XZDR related. If you have USB debugging turned on, and your mobile disconnected from your PC, just make sure you 'revoke all authorizations for USB debugging' in the developer options menu. Then reboot your phone and before doing anything else, make sure you're looking at the home screen on your device, then hook up your USB cable. Your mobile should then ask if the connected PC is authorized or not. Once answered you can start the installer.
    122
    A small update on progress:

    The issues with XZDR are mainly caused by Sony actually properly setting up SELinux support for the very first time on the LP ROM's, something they neglected in all of the KK releases. This makes the LP version a lot more secure, which is a good thing. The problem is that I now know what to fix, but am still looking in to how to fix it. :angel:

    For the techies among us:

    During INIT the hijack still works, but the script is not able to change anything on the rootfs, it allows you to create a folder and if you mount a tmpfs on it you can write stuff to it, but if you try to write anything to the folder as it is (without tmpfs) it will not allow you to do so. This is because the SELinux context of my scripts is not set correctly, so the kernel blocks just about everything I try to do. I'm busy configuring and compiling a new busybox to include in XZDR with better SELinux support, as the one I am currently using is lacking the extended SELinux support I will need to fix this.
    The other problem is that init is less easy to override with the init from the recoveries, it simply continues the LP boot, I am in the progress of including 2nd-init support ( created by SkrilaxCZ ) and will be integrating parts and ideas of the safestrap project by Hashcode to fix these issues.
    The last but not least problem is that I can still mount the SDCard, but I am unable to write to it, most likely also due to the SELinux restrictions. If you remove the SDCard from the device it will use /cache which seems to be set up with less strict permissions and it will be able to do just about everything, except boot the actual recoveries.

    Last night I worked from 23:00PM all the night up to 6:30AM, pulling an almost an all-nighter. I'm not giving up just yet :cowboy:

    My thanks go to @Hashcode for a late night chat (for me that is, he was at work as he is located on the other side of the globe!) which helped me find the most likely cause.