Jump to content
Sign in to follow this  
david

Team Win Recovery Project [TWRP]

Recommended Posts

Moderator: This is a split from this sailfish thread

 

 

On 11/16/2019 at 7:41 AM, Craig said:

 

I tried pinging the TWRP developer Chen thanked and will start a new thread (if he doesn't) if he replies with more info.  But even the early reports said it could flash, so for installing SFOS it's fine, and for stock backup, we already have a flashall so no worries that way either.

Thanks for pinging him.  I would like to be able to use TWRP to make nandroid backups of my /data partition (for Android use).  Since this is shared in A/B, maybe that works already.  I'd also like to be able to use "adb pull" to get the backup off the device, as well as backup the media files (TWRP doesn't include media files in /data backups).  I believe "adb pull" only works in recovery mode, with the partition unmounted.  I don't know if stock recovery can do that.

UPDATE:  Thinking about this more, as long as the phone will allow booting off images on a USB connected computer (fastboot boot boot.img), an insecure boot.img could be made and booted off of.  This should allow "adb pull/push" to be used to backup/restore /data and /data/media.  I haven't used this method before, so I am speaking from theory.

The benefit of doing a nandroid backup of /data in recovery mode is that it will pack all the files into one or more tar files.  These may transfer easier with adb pull than pulling thousands of individual files.  I have had cases where adb pull has hung after some number of files.  Running it again, multiple times, allowed it to finish, but it is annoying and increases the time to complete the task.

I'll do some testing and create some tutorials on various file transfer methods once I get my phone.

  • Like 1

Share this post


Link to post
Share on other sites

The version of TWRP linked from the first post in the Sailfish OS thread works well enough to install Sailfish OS, but YMMV if you want to use it for any other purpose. It cannot decrypt the userdata partition (so you can't use it to make a backup), and you're better off using fastboot to restore the other partitions rather than a nandroid backup made with TWRP.

Also, the current bootloader does not support 'fastboot boot boot.img'. ☹️

  • Like 1
  • Thanks 2

Share this post


Link to post
Share on other sites
31 minutes ago, Sean McCreary said:

Also, the current bootloader does not support 'fastboot boot boot.img'. ☹️

Wow, that's really surprising.  I know not every phone supports that, but I really have to think that was just an oversight for fxtec and not done intentionally, since they seem to want to keep things open and available.  Maybe @Waxberry can comment on that limitation and whether it will be opened up.

Thank you for the information about TWRP.  I guess that means there is no way, currently, to do a partition backup with the Pro1 via ADB or Recovery.  There might be a way to do it from within Android when rooted, but that's atypical.

  • Like 1

Share this post


Link to post
Share on other sites

There is a twrp build for Pro1 by Sean MccReary.   The info is currently in the SailfishOS thread, but for better visibility I think it deserves it's own thread.

TWRP 3.3.1 for Pro1: Download here

 

 

Edited by Craig
this was the first post, reordered by mods
  • Like 3

Share this post


Link to post
Share on other sites

Please move this post to this thread too.  It isn't Sailfish related.  It is about TWRP and/or alternative ways to backup partitions.

 

Share this post


Link to post
Share on other sites
On 11/17/2019 at 8:09 PM, Sean McCreary said:

The version of TWRP linked from the first post in the Sailfish OS thread works well enough to install Sailfish OS, but YMMV if you want to use it for any other purpose. It cannot decrypt the userdata partition (so you can't use it to make a backup), and you're better off using fastboot to restore the other partitions rather than a nandroid backup made with TWRP.

Also, the current bootloader does not support 'fastboot boot boot.img'. ☹️

I believe this to be one of the causes for the following behaviour that I'm encountering while trying to simply flash TWRP without continuing the Sailfish OS install:

  • Can't mount /data or /system or /data/system
  • Can't seem to check off the "Mount as read-only" check box
  • After flashing it Android asks me for a password which is NOT my password, and I cannot boot boot into Android at all
  • Doing a "Wipe Data" results in an endless boot
  • Doing a "Factory Reset" fails with multiple errors

I encountered this while attempting to get Magisk installed, more on my thread: 

 

  • Thanks 1

Share this post


Link to post
Share on other sites

I tried the instructions in the Sailfish thread to install TWRP, but it's failing at the first step to set_active. The set_active command returns different errors every time I run it.

Quote

C:\Program Files (x86)\Minimal ADB and Fastboot>fastboot devices
3b93039e        fastboot

C:\Program Files (x86)\Minimal ADB and Fastboot>fastboot set_active a
error: Device does not support slots

C:\Program Files (x86)\Minimal ADB and Fastboot>fastboot set_active a
Setting current slot to 'a'...
FAILED (remote: Invalid Slot)
finished. total time: 0.003s

C:\Program Files (x86)\Minimal ADB and Fastboot>

I have tried various USB cords (mostly the one that came with the phone) and various usb ports and even two different machines, but with the same result.

Any suggestions?

Share this post


Link to post
Share on other sites

If two machines, with two different cables, both do it, sounds like something wrong with the version of fastboot (if you used the same exact version on both?) or your device...

Share this post


Link to post
Share on other sites

Great success!
I have a linux box in the basement, and it was able to fastboot flash on the first try. Must be some software or driver issue on *both* my windows machines. 😞

  • Thanks 3

Share this post


Link to post
Share on other sites
On 12/11/2019 at 5:10 PM, zurvan2 said:

Great success!
I have a linux box in the basement, and it was able to fastboot flash on the first try. Must be some software or driver issue on *both* my windows machines. 😞

All silliness aside, that is good to know. It seems that the more "secure" Windows becomes, the more fussy it becomes about actually working. Bah humbug.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

×
×
  • Create New...

Important Information

Terms