yashsingh1/xdaforums huggingface dataset:
[Xperia Z1 Original Android Development] [NUT]:
[MENTION=1346722]Bin4ry[/MENTION]

For many countries (unlike ours!) have less or no warranty laws prohibiting manufacturers to decline a repair based on factory failure/faults even when the bootloaders are unlocked. Those owners want to keep the warranty, not to forget the DRM as well. Me myself, I don't care, I've unlocked my XZ's bootloader within a month of receiving it, but I made a TA backup prior to doing so... never can be too careful sometimes ;)

Besides, the recoveries are a useful and extremely powerful tool, also to them: it will allow you to make a TRUE backup of your phone, unlike many of the backup app's available... a personal view is: I use STOCK rom's, because I like them as they are, but sometimes I do want to make a small adjustment, even if my bootloader was locked, I would still have that urge! Recoveries on locked bootloader devices allow that to be installed easily, without the risks involved when unlocking the bootloader (warranty/DRM issue mentioned before).

I'm sure it's a service haunting us, but the problem is what I said before: krabappel2548 and DooMLoRD are too busy and I (currently) don't have the cash to purchase a Z1...

---------- Post added 11th October 2013 at 12:06 AM ---------- Previous post was 10th October 2013 at 11:50 PM ----------

I just realized that actually sounds incredibly corny and fake... but it's for real: My cat has Hyperthyroidism (WIKI) and one of the solutions to it is treatment with radio iodine, which will in a sense be the same as a chemo for human cancer patients. The treatment lasts 5 days will cost € 675,- and then she will remain there for 2 weeks while the radioactivity will diminish for a further € 532,- :eek:

Me and my cat live in The Netherlands and she will get the treatment at the University clinic in Gent, Belgium and it will start on the 21st of October...

I'd be able to purchase 2 brand new Z1's for that kind of money, but I would actually not be able to live with myself if I skipped the treatment :(
[Xperia Z1 Original Android Development] Michealtbh:
I would donate a small amount towards getting dual recovery working, but I fear it would be pointless as there won't be enough people donating to make it worthwhile
[Xperia Z1 Original Android Development] Bin4ry:
I see. But the warranty thing is a problem which we can circumvence for the last 2 years by simply applying the Relock bootloader script bundled by ftf! For drm keys just backup and restore which will also Relock y I urge bootloader undetectable!

I said before: requesting a unlockkey is no proof you really used it! So i dont see any reason for being on locked bootloader except the actual camera problem ofc! Even if one likes advanced stock roms it's again better and more powerful to flash a custom kernel for this ;)

Still i am not getting why people buy phones in contracts at all and pay extra money every month. Why not buy a phone for the money you have cash? In a perfect mobile world no crappy provider****ed phones would exist and the people would realise that the higher amount on money a phone costs cash is smaller that the extra costs you pay monthly for the phone at your provider ;) atleast it is like this here in Germany if you don't take one of the very very high priced Tarifs!

Sorry for your cat, if you need a phone you can try if sony may provide you one via the device borrowing they offer on their developerworld!

But again once I have time I will try to look again, but I am in the end of my master thesis, so my time is very limited till the end of the year :)

Regards

Gesendet von meinem C6903 mit Tapatalk 4
[Xperia Z1 Original Android Development] [NUT]:
Yah, if everyone would say that, it will never happen :p

Every euro/dollar gained speeds up my ability to pick a Z1 up soon :)

[MENTION=1346722]Bin4ry[/MENTION] don't worry about the lack of time, I can relate to that, I'm just happy you are willing to help :)

In some countries the phones are just as expensive as in Germany and The Netherlands but the monthly wages are half (or even less then that!) of that what we can earn. People are forced in to a provider lock contract with that... There is no way around it.

I doubt Sony will borrow me a phone, I'm no app dev and in fact I'm promoting that what they don't want to happen...

[EDIT]

I've found what program you mean, it's for Canada and the US only: http://developer.sonymobile.com/services/borrow-a-phone/ so no dice :(

[/EDIT]

I welcome the day Sony integrates a recovery partition in their partitioning scheme... That would make it all soooooooo much easier... ;)
[Xperia Z1 Original Android Development] jeroenqui:
I think I managed to compile a working TWRP recovery. Tested it, and it works perfectly fine for me.

If someone could test it, it would be great..

http://d-h.st/6KE
[Xperia Z1 Original Android Development] Desperanto86:
File Not Found
[Xperia Z1 Original Android Development] delewer:
File is expired
[Xperia Z1 Original Android Development] [NUT]:
He removed the file because he misunderstood the actual problems we are facing, his test was on an unlocked device with the recoveries in the ramdisk.... The problem does not occur in that case.
[Xperia Z1 Original Android Development] Shaky156:
A Sony binary
[Xperia Z1 Original Android Development] [NUT]:
Seriously...
[Xperia Z1 Original Android Development] delewer:
OK..

I have no more 40sec reboot bug now.

I backup my system by TWRP in this moment... work fine

I can't mount external storage for now... another bug..

I have change a lot of stuff in cpio CWM (cleam cpio), but not relevant for now.

To repair the 40sec bug, do this :

change in /system/bin/dualrecovery.sh

<code>

ECHOL "Start time_daemon..."

/system/bin/time_daemon &

EXECL sleep 2

ECHOL "Kill time_daemon..."

EXECL kill -9 $(ps | grep time_daemon | grep -v "grep" | awk -F' ' '{print $1}')

</code>

by

<code>

#ECHOL "Start time_daemon..."

#/system/bin/time_daemon &

#EXECL sleep 2

#ECHOL "Kill time_daemon..."

#EXECL kill -9 $(ps | grep time_daemon | grep -v "grep" | awk -F' ' '{print $1}')

</code>
[Xperia Z1 Original Android Development] [NUT]:
Thanks a lot!!

I'll release a beta based on this before this Sunday ends :D :thumbup:
[Xperia Z1 Original Android Development] Desperanto86:
PERFECT! TWPR works fine, and I have no BUG :) THX MAN!
[Xperia Z1 Original Android Development] Michealtbh:
Finally! Great work guys! I was beginning to lose hope and consider selling my Z1 but it looks like I'll be holding on to it for a bit longer.

Now all we need is Sony to fix the camera bootloader unlock bug and I'll be a happy man.
[Xperia Z1 Original Android Development] gregbradley:
Many thanks.. it is working now.

I finally have a backup of my rom, not so worried about messing around with it now :D
[Xperia Z1 Original Android Development] delewer:
Additionnal information :

"time_daemon" provide to give a correct time to device in "recovery mode" ; So, now the lines are unactivated in the "recovery.sh" script, we have bad time and hour in device and with the NANDROID files.

It seem what it's not the daemon which reboot the device, but the "kill -9"

So, i have tested, and work fine with this line activated :

/system/bin/time_daemon &

So, just add comment before the other lines i have notice in previous post, and let the time_daemon line "activated"

Hour and date are correct, and no boot problems.

It's just the beginning....
[Xperia Z1 Original Android Development] gregbradley:
Just made that change and am in TWRP, but it says the time is 09:53 when its actually 15:53...

Backing up now and I will look at the backup name, the previous one was dated sometime in 1970..

EDIT

The new backup had the correct time and date, even though the clock in TWRP was 6 hours out on the correct time
[Xperia Z1 Original Android Development] jagdesh:
The new V2 version has been uploaded? i will wait for V2 version to install and get the 40 sec reboot timer removed.
[Xperia Z1 Original Android Development] gregbradley:
not yet, but you can make the changes yourself.

Just open the dualrecovery.sh from the downloaded files and edit it with notepad++, then run the install.bat
[Xperia Z1 Original Android Development] monx®:
u r the man.

so the conclusion, just this is needed : no need to kill time_daemon

#ECHOL "Kill time_daemon..."
#EXECL kill -9 $(ps | grep time_daemon | grep -v "grep" | awk -F' ' '{print $1}')
[Xperia Z1 Original Android Development] Desperanto86:
yes! with this fix recovery in your rom works fine except mounting from pc. :)
[Xperia Z1 Original Android Development] monx®:
fixed em all. but got delays before device listed in adb when in recovery. (same like happens to XZ, only shows up <= 2mins) :good:

Here is complete package + my modded TWRP

DooMLoRD-NUT-Z1-DualRecovery-LOCKED.7z (6.0 MB)
[Xperia Z1 Original Android Development] shem2409:
Thank you developers for getting this to work. I have recorded a video for noobs on how to install.

[YOUTUBE]ob1D-bQkDWc[/YOUTUBE]
[Xperia Z1 Original Android Development] pikeylfc:
hello i just did the same as the video and i can get into both recoverys but when i reboot to system it dont i get to the sony logo and it viberates thats when it says to push up for cwm or down for other one i dont push anything and the led lights up and it viberates every 3 to 4 seconds and im stuck there any ideas what i should do
[Xperia Z1 Original Android Development] [NUT]:
Take out your external SD if you have it, then put it in your pc.

Look for the folder XZDualRecovery and put in a file called 'donotrun' without any extension. Then put the SD card back and reboot your phone with Power+VolUP.

It should then boot normally.

---------- Post added at 01:22 AM ---------- Previous post was at 01:12 AM ----------

Actually, that delay is from the TWRP binary, it checks the keys before it will start up the service daemon... but for some weird reason it's extremely slow on the XZ and Z1 ...

Was actually looking in to that almost a month ago, but I totally forgot about it... needs some TLC again ;)
[Xperia Z1 Original Android Development] pikeylfc:
sorry im a bit stupid ha when you say put the file donotrun how do i make that file or find it what i did do is have a file on my laptop i renamed it to that and when i put my sd card back in the led was red it didnt vibarate and just the sony logo sorry to hassle you like this
[Xperia Z1 Original Android Development] [NUT]:
Really, you should re-read what you type bro... it took me a while before i got what you wrote...

Go to the folder you where before, then get in to the folder options and untick the box in the attached image. You will then see it with an extension still... you need to rename it to be called _EXACTLY_ 'donotrun'.
[Xperia Z1 Original Android Development] Klaus N.:
Thanks a lot, works fine so far. Backup via TWRP onto ext sd and flashing krabappel's deodex-patch went through without problems :D
[Xperia Z1 Original Android Development] xyagnesh.davex:
Q] Swapping Of Partition

Swapping Of System Partition 12gb with SDCARD ??

is it possible ?

tried this app not working

https://play.google.com/store/apps/d....int2ext&hl=en

even tried to edit vold.fstab

not working :/

it mount to

System Part.

/Storage/emulated/legacy and

Sdcard to

/Storage/removable/sdcard1

Help ! Want To Increase Internal Memory
[Xperia Z1 Original Android Development] 301stSpartan:
Ummm yes, that is what this thread is about. Did you read it?
[Xperia Z1 Original Android Development] Militace:
Hi,

I don't understand.

can you explain me, step by step, how to install this recovery ?

Thanks very much ;)
[Xperia Z1 Original Android Development] [NUT]:
Read the top 2 quotes and then enable USB debugging. Once done, follow the video guide, it's clear enough!
[Xperia Z1 Original Android Development] xyagnesh.davex:
Sry Just Copy Pasted Mah 10 Days Old Question So Forgot to remove last line :P

So Is There Any Way To Swap SDCARD With Internal SDCARD For Z1 ?

I Think Link2sd Also Fail In This Device :(
[Xperia Z1 Original Android Development] jagdesh:
Okay so now I have made nandroid backup using TWRP finally ... thanks all

But I want to confirm that the external sd card cannot be mounted nor backup can be performed on external sd card... this is issue yet to be resolved correct.
[Xperia Z1 Original Android Development] homer285:
I do believe already stated, ungrateful, arrogance, or respectively have you contributed/donated?
[Xperia Z1 Original Android Development] jagdesh:
Dude dont get started on donation, everyone has a right to donate or not and this is free forum and by not donating you do not become ungreatful or arogrant

Let not start this argument, you are requested to keep your thoughts to yourself about donation ...
[Xperia Z1 Original Android Development] homer285:
OT, I am not requested to do anything, I am not arguing, however this is not a public forum, you are required to register and agree to forum rules. It isnt about donating but about your agreement to adhere to forum rules!
[Xperia Z1 Original Android Development] delewer:
Please, don't be so rude. English is not the native language for all...

To answer : yes we have a few bugs.

In cwm, nandroid "tar" have 0 octet size

Adb don't work in both recovery (only in one)

External_sd is not mount in twrp recovery (may be wrong recovery.fstab in etc in cpio disk), but ok in cwm for external nandroid

And don't forget, it's a dev thread... this is not a public release, we help to finish a tool that can be use in public roms...
[Xperia Z1 Original Android Development] monx®:
adb works on my modded TWRP (got delays before shows up in adb)

External_sd & USB OTG works on my modded TWRP
[Xperia Z1 Original Android Development] delewer:
Your right, i forget ;)

Except for externel_sd, don't work on mine on twrp, only in cwm :what:
[Xperia Z1 Original Android Development] jagdesh:
How does external sd works on TRWP with the 40sec timer deactivated..

I tried to make android backup through twrp and it does not let me backup on external sd card only on the internal memory..

---------- Post added at 03:48 PM ---------- Previous post was at 03:46 PM ----------

And to add to the above I am using your uploaded dual recovery zip file which you uploaded on page 9 I downloaded it and flashed it using install.bat file but I can't mount external sd when in twrp
[Xperia Z1 Original Android Development] monx®:
i hv no issue
[Xperia Z1 Original Android Development] delewer:
Don't work on mine, but i pretty sure it's the sdcard format

Mine is extNTFS, and your not

So, may be, can you test with :

In cpio twrp, in etc, in recovery.fstab, change for sdcard line, auto or datamedia in place of vfat ??

I have issu on my cpio, i cannot mod for now

Thx..
[Xperia Z1 Original Android Development] jagdesh:
MY SD card is ExFat 64gb San disk class 10 card.

I am not able to mount sd card in TWRP
[Xperia Z1 Original Android Development] monx®:
ok can u try attached? package is flashable thru any recovery.
[Xperia Z1 Original Android Development] jagdesh:
Flashed this mod using TWRP and nope, does not let me mount external sd card nor it lets me select external sd card for installing files from...
[Xperia Z1 Original Android Development] monx®:
means it doesnt support other than FAT32 for mSD atm.
[Xperia Z1 Original Android Development] [NUT]:
Does your exfat sdcard1 hold a folder called XZDualRecovery? If not, have a look at /cache.

Check /tmp and see if there is a XZDualRecovery folder there.

Gather all of the logs inside all of the folders mentioned and zip&attach them here.

Also, there is an issue with the TWRP exfat support on the XZ too, while in recovery, try to physically remove the sdcard and re-insert it. That allows you to mount it on the XZ.
[Xperia Z1 Original Android Development] delewer:
Not working, but strange thinks...

when i try to mount /external_sd, i have this error :

unnabled to mount '/external_sd'

But, my sdcard is mount in another dir :

/storage/removable/sdcard1

So, something is bad linked

i try to force mount in /external_sd without succes...

When i try with :

ln -s /storage/removable/sdcard1 /external_sd

I have a file created in /external_sd, not a valid link.... may be symlink is bugged... but i don't see why (busybox ?)

Same file exists in /storage (3 files sdcard0 sdcar1 usbdisk), but no link or usable dir...

well well...

Additionnal informations :

I see in recovery.log :

I:cmd: /sbin/exfat-fuse -o big_writes,max_read=131072,max_write=131072 /dev/block/mmcblk1p1 /external_sd

fuse: mount failed: Device or resource busy

I:exfat-fuse failed to mount with result 'FUSE exfat 1.0.0

', trying vfat

I:Unable to mount '/external_sd'

I:Actual block device: '/dev/block/mmcblk1p1', current file system: 'vfat'

I:Switching packages (TWRP)

I:Set page: 'mount'

I:cmd: /sbin/exfat-fuse -o big_writes,max_read=131072,max_write=131072 /dev/block/mmcblk1p1 /external_sd

fuse: mount failed: Device or resource busy

I:exfat-fuse failed to mount with result 'FUSE exfat 1.0.0

', trying vfat

E:Unable to mount '/external_sd'

and this :

I:cmd: /sbin/exfat-fuse -o big_writes,max_read=131072,max_write=131072 /dev/block/mmcblk1p1 /external_sd

fuse: mountpoint is not empty

fuse: if you are sure this is safe, use the 'nonempty' mount option

I:exfat-fuse failed to mount with result 'FUSE exfat 1.0.0

', trying vfat

E:Unable to mount '/external_sd'

I:Actual block device: '/dev/block/mmcblk1p1', current file system: 'vfat'

I:Set page: 'selectstorage'

I:cmd: /sbin/exfat-fuse -o big_writes,max_read=131072,max_write=131072 /dev/block/mmcblk1p1 /external_sd

fuse: mountpoint is not empty

fuse: if you are sure this is safe, use the 'nonempty' mount option

So, ressource is "busy", and option 'nonempty' must be use... I reboot and test
[Xperia Z1 Original Android Development] [NUT]:
Well... that COULD very well already be the case, as the chargemon script will already have your sdcard mounted for logging...

Does your exfat formatted sdcard have a folder called XZDualRecovery?

EDIT: updated the OP and included the file uploaded by [MENTION=273310]monx®[/MENTION] to the thread, so people can't download the wrong (not fixed) version. Also modified the 'what doesn't work' portion of the OP.

Thanks where they are due ;)
[Xperia Z1 Original Android Development] slonn:
Delete....
[Xperia Z1 Original Android Development] [NUT]:
What ROM version do you have? If it's an updated version... could you install this app: https://code.google.com/p/android-event-injector/downloads/list and run it by tapping the button 'Scan Input Devs'? Tap every single device node and when it turns green go to the next, then when done (the list is probably longer then just 1 screen) take a screenshot for me to see the input devices.

Thanks :)
[Xperia Z1 Original Android Development] jagdesh:
Here you go, this folder is present in the External SD Card.
[Xperia Z1 Original Android Development] delewer:
Good point...i have the XZDualRecovy folder... and of course i see in :p

May be CWM use /storage to work, so, no issue, but TWRP use /external_sd, and of course, no mount for "busy affairs"

I see how to disable XZ folder to test....
[Xperia Z1 Original Android Development] jagdesh:
File found on external sd card.
[Xperia Z1 Original Android Development] slonn:
Thanks for the quick reply. I tried again and it worked. Not sure why I messed it up the first few times :-/

Sendt fra SGS4
[Xperia Z1 Original Android Development] delewer:
in the TWRP recovery, i have try this,

umount -l /storage/removable/sdcard1

mount -o rw /dev/block/mmcblk1p1 /external_sd

And now, sdcard1 can be access

Now, i don't know where the "/storage/removable/sdcard1" folder is mount....

The bugg is present to CWM too

Edit1 :

I have try to add in dualrecovery.sh" the lines before the INIT :

umount -l /external_sd

umount -l /storage/removable/sdcard1

without succes ...
[Xperia Z1 Original Android Development] jagdesh:
I don't know if this info has been shared but...

In CWM after installing the Monx modded dual recovery. Zip file the 40 sec timer is also deactivated in CWM and I have just made a nandroid backup to my external sd card using CWM recovery and it's successful..

For now twrp recovery is not mounting my external sd... Which is okay since my backup happened in CWM to my external as card
[Xperia Z1 Original Android Development] Shaky156:
Issue is TWRP Specific i went through the dualrecovery.sh and all looks fine, so the issue is within the twrp code since CWM can write to external_sd

External sdcard this is in:

Rootfs/sdcard1

Rootfs/ext_card

Rootfs/storage/sdcard1

Rootfs/storage/removable/sdcard1

Under mnt/ is only internal storage and not external sd

Edit: I changed my lines to

# Setting cpu frequencies, to speed up things up

#ECHOL "Setting CPU max frequency to 2.1Ghz..."

echo 2150400 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq

echo 2150400 > /sys/devices/system/cpu/cpu1/cpufreq/scaling_max_freq

echo 2150400 > /sys/devices/system/cpu/cpu2/cpufreq/scaling_max_freq

echo 2150400 > /sys/devices/system/cpu/cpu3/cpufreq/scaling_max_freq

#ECHOL "Setting CPU min frequency to 300mhz..."

echo 300000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq

echo 300000 > /sys/devices/system/cpu/cpu1/cpufreq/scaling_min_freq

echo 300000 > /sys/devices/system/cpu/cpu2/cpufreq/scaling_min_freq

echo 300000 > /sys/devices/system/cpu/cpu3/cpufreq/scaling_min_freq

Thats just to increase core cpu clocks for superspeed max @ 2.15ghz min [MENTION=1785406]300m[/MENTION]hz

What we want to do is use this in dualrecovery.sh
[Xperia Z1 Original Android Development] y2grae:
I run the exe as described in video, but phone doesn't reboot

when i restart phone, no colour led to signal recovery

exe from Doom states it worked fine

any hints anyone ?
[Xperia Z1 Original Android Development] pikeylfc:
Thanks for your help my friend
[Xperia Z1 Original Android Development] Shaky156:
Sdcard fixed
[Xperia Z1 Original Android Development] [NUT]:
Eh, if you look inside /system/bin do you see chargemon.stock, chargemon, dualrecovery.sh and the ramdisk.*.cpio.lzma files?

You did enable USB debugging before you tried to install the recoveries?

---------- Post added at 08:41 PM ---------- Previous post was at 08:40 PM ----------

Did you do anything different then what delewer suggested?
[Xperia Z1 Original Android Development] delewer:
Fixed ? Where ?

To help those who have, like me, the sdcard bug, i use a little zip to flash in first when enter in recovery

This zip repair the sdcard selection on TWRP recovery.

After the flash, you can select the "sdcard" choice in settings

It's a temporary solution...
[Xperia Z1 Original Android Development] y2grae:
usb debugging = yes

I see chargemon only out of those
[Xperia Z1 Original Android Development] Shaky156:
Yeah edit dualrecovery.sh and replace both lines:

umount -l /storage/sdcard1

With this line

umount -f /storage/sdcard1

TWRP Works perfectly fine

Would like to ask who originally wrote this whole script?

---------- Post added at 07:51 PM ---------- Previous post was at 07:50 PM ----------

Also if this could be implemented would benefit everyone
[Xperia Z1 Original Android Development] delewer:
Thx for sharing... but the "mount -f" don't work with me... i have alway the sdcard bug...
[Xperia Z1 Original Android Development] Shaky156:
Did u change both lines?

Heres my dualrecovery.sh give it a try

https://db.tt/H8Bb5Rbj
[Xperia Z1 Original Android Development] delewer:
No, this don't work for me... sdcard1 always mounted...

I have try a lot of solution without success

I think it's host fstab which is not umount for any reason (Log ??)

So, the only way i have is to umount after enter in guest disk (in TWRP recovery)..

My zip file to flash is made for that....

Thx man.
[Xperia Z1 Original Android Development] gregbradley:
I had to run the process twice, first time it didn't work, second it did..try doing it again "But better" *bop it