[RECOVERY][OFFICIAL] TWRP for MIX 2S

Search This thread

pquinqu

Senior Member
May 7, 2007
108
118
Paris
Hi,

Can *anyone* make a backup of /data without error 255?

Is there a fix for this?

Thanks
Sorry to say that but all is working correctly for me. Mi Mix 2S under lineageos16, magisk, opengapps and encrypted data partition.
Backup and restore /data are working fine. Maybe it's related to the backup size, or a backup to an external device, or a no more space condition during the backup or the firmware or... don't know.

---------- Post added at 05:28 PM ---------- Previous post was at 05:22 PM ----------

Hi,

Can *anyone* make a backup of /data without error 255?

Is there a fix for this?

Thanks
Sorry to say that but all is working correctly for me. Mi Mix 2S under lineageos16, magisk, opengapps and encrypted data partition.
Backup and restore /data are working fine. Maybe it's related to the backup size, or a backup to an external device, or a no more space condition during the backup or the firmware or... don't know.
 

kleinholzinferno

Senior Member
Feb 4, 2009
375
114
Can anyone explain to me what exactly I need to backup if I update a ROM, clean install it with gapps and wipe/format data during the Installation process?

I got Google authenticator running for 2 step authentication on some account and I do t want to enter the backup codes everytime I setup a ROM from scratch.

So what do i need to backup and restore to get the fresh updated system to the last available backup point? Tried many different types but all failed in some way.

A little help wod be appreciated...thanks in advance
 

aurocha

Senior Member
May 24, 2013
315
72
Oporto
Xiaomi Poco X3 Pro
Sorry to say that but all is working correctly for me. Mi Mix 2S under lineageos16, magisk, opengapps and encrypted data partition.
Backup and restore /data are working fine. Maybe it's related to the backup size, or a backup to an external device, or a no more space condition during the backup or the firmware or... don't know.

Thanks for you input. I started all over again, flashed latest official MIUI stable, flashed TWRP, backed up all available Partitions and it worked; wiped /data /cache and /system and installed official LOS 16.0 and gapps.

Everything is now working as expected.

Thanks and best regards,

-aurocha
 

liverhook

Senior Member
Aug 7, 2015
50
2
Xiaomi Mi Mix 2S
problem backup with twrp recovery when choosing "data" !
Without this selection it runs successfully.
I've attached the log file with the "error 255" at teh end of the log file.
Could it be, that backing up the data partition is not a logic choice, since twrp wants to write its backup file onto exact this partition, it wants to backup ???
How can I choose an external storage, the windows pc, since twrp supports mtp, or USB OTG, if it is supported.

---------- Post added at 04:36 PM ---------- Previous post was at 04:32 PM ----------

here the log file:
.......
........
I:addFile '/data/system_ce/0/launch_params/com.android.bips_.ImagePrintActivity.xml' including root: 0
==> set selinux context: u:eek:bject_r:system_data_file:s0
I:addFile '/data/system_ce/0/launch_params/com.android.deskclock_.DeskClock.xml' including root: 0
==> set selinux context: u:eek:bject_r:system_data_file:s0
I:addFile '/data/system_ce/0/launch_params/org.lineageos.setupwizard_.SetupWizardActivity.xml' including root: 0
==> set selinux context: u:eek:bject_r:system_data_file:s0
I:addFile '/data/system_ce/0/snapshots' including root: 0
==> set selinux context: u:eek:bject_r:system_data_file:s0
found policy '/data/system_ce/0/snapshots' - '1CE0' - '7e6ba1538c1341b7'
I:addFile '/data/system_ce/0/snapshots/4_reduced.jpg' including root: 0
==> set selinux context: u:eek:bject_r:system_data_file:s0
I:addFile '/data/system_ce/0/snapshots/4.proto' including root: 0
==> set selinux context: u:eek:bject_r:system_data_file:s0
I:addFile '/data/system_ce/0/snapshots/4.jpg' including root: 0
==> set selinux context: u:eek:bject_r:system_data_file:s0
I:addFile '/data/system_ce/0/backup' including root: 0
==> set selinux context: u:eek:bject_r:backup_data_file:s0
found policy '/data/system_ce/0/backup' - '1CE0' - '7e6ba1538c1341b7'
I:addFile '/data/per_boot' including root: 0
==> set selinux context: u:eek:bject_r:system_data_file:s0
failed to lookup tar policy for '/data/per_boot' - '4b09945924a856bb'
I:Error adding file '/data/per_boot' to '/data/media/0/TWRP/BACKUPS/c047bdc0/2020-04-08--15-40-43_lineage_polaris-userdebug_10_QQ2A200305003/data.ext4.win'
Error creating backup.
I:ERROR tarList for thread ID 0
Error creating backup.
createTarFork() process ended with ERROR: 255
Backup Failed. Cleaning Backup Folder.
 
Last edited:

evronetwork

Senior Member
Jan 19, 2012
1,551
404
North
Guys twrp is not optimized for android 10 ...of course it has problems, I get error 255 myself

You can try this twrp mod - https://forum.xda-developers.com/xi...nt/recovery-unofficial-twrp-recovery-t3967939

It says it works with android 10, didn't test it so I have no clue if it works but give it a try and let us know

P.S. TWRP stuff the main dev said he has a 4rth child so updating would take a while and android 10 is complex so...don't expect anything soon :D
 
Last edited:
  • Like
Reactions: davidzqj

cvamoose

Senior Member
To the people having trouble backing up data and gettings the tarfork error 255. If you delete /data/per_boot you can backup data successfully.

Edit: Or just use orangefox, which actually gets updated XD
 
Last edited:

MiniBlu

Senior Member
Aug 2, 2013
706
748
brisbane
Orangefox has the following "feature"/bug

When you boot to recovery, it asks you for password to decrypt data, you press back and voila! ...you "bypass" the password and data are decrypted. I moan to the developer of orangefox and all I got was:

A report to a mod(probably from the dev? which told me in private I should be more respectful - what?)
The developer moaning this is the default mode and it's for convenience and it can't be turned off

P.S. Frankly I'd stay away from a recovery like that - not being disrespectful, I just want my phone if lost or stolen to have encypted data, that's all. I'm waiting for a TWRP update, the main developer has a new family member(kid) according to their website and also twrp support for android 10 is harder than expected so we can only wait for it

That's only because your device wasn't encrypted because you left "disable force encryption" checked when you clean installed the rom from orangefox. If you were encrypted, no recovery or rom can decrypt without a password.
 
Last edited by a moderator:
  • Like
Reactions: DarthJabba9

evronetwork

Senior Member
Jan 19, 2012
1,551
404
North
That's only because your device wasn't encrypted because you left "disable force encryption" checked when you clean installed the rom from orangefox. If you were encrypted, no recovery or rom can decrypt without a password. You need to stop blaming others for your own stupidity.

You are offensive, deleted my stuff and send you a pm
 
Last edited:

MiniBlu

Senior Member
Aug 2, 2013
706
748
brisbane
It was encypted as expected

Did factory restore to miui(through fastboot)

I'm telling you, I've talked to the dev and told me that orangefox has this "feature" to help you out somehow

P.S. Rom itself showed data were encypted, rom couldn't be used without the password so "devices wasn't encypted"? ...not true. Flash TWRP and everything went as they should, encyption was still on and working, cancel button gave me giberish data unlike orangefox which showed everything.

"You need to stop blaming others for your own stupidity" won't comment on that as you are offensive, I've just told you what I've experience and I'm stopping now even if you reply with even more offensive comment
Your wrong, and you confirmed it in our last discussion when admitted you had flashed it from orangefox without unchecking "disable force encryption". Again, no recovery can decrypt an encrypted device without having the password. It is not possible
 
  • Like
Reactions: DarthJabba9

evronetwork

Senior Member
Jan 19, 2012
1,551
404
North
Your wrong, and you confirmed it in our last discussion when admitted you had flashed it from orangefox without unchecking "disable force encryption". Again, no recovery can decrypt an encrypted device without having the password. It is not possible

deleting my stuff and sending u pm - we're off topic and you are basically wrong :D
 
Last edited:

BaamAlex

Senior Member
May 1, 2017
289
44
I have one question. I reinstalled twrp because the orangefox recovery is stuttering on my device. Dunno why.y question is, how can i remove the pattern at recovery startup? If i don't "unlock" it, my folders are very weird descripted. Or should i wait for the next twrp release (if a new version will come)?
 

evronetwork

Senior Member
Jan 19, 2012
1,551
404
North
I have one question. I reinstalled twrp because the orangefox recovery is stuttering on my device. Dunno why.y question is, how can i remove the pattern at recovery startup? If i don't "unlock" it, my folders are very weird descripted. Or should i wait for the next twrp release (if a new version will come)?

If you don't enter your password to the TWRP your files/folders should be gibberish which is good and means your data are encrypted
 

Top Liked Posts

  • There are no posts matching your filters.
  • 75
    Self-made TWRP 3.2.3-0 recovery for MIX 2S

    It's official now!
    Please go to https://twrp.me/xiaomi/xiaomimimix2s.html to download.

    Updates:

    v15 (2019-01-09):
    Built against latest omni-9.0 tree and lineage-16.0 polaris kernel
    This should fix the decryption issue on android 9.0 roms with 2019-01 security patches. If v14 works for you, then no need to flash this.

    v14 (2018-12-09):
    Built against latest omni-9.0 tree
    This should fix the decryption issue on latest android 9.0 roms. If v13 works for you, then no need to flash this.

    v13 (2018-11-21):
    Fixed wiping issue

    v12 (2018-11-16):
    Built against latest omni-9.0 tree
    This should fix the decryption issue on latest android 9.0 roms. If v11 works for you, then no need to flash this.

    v11 (2018-10-12):
    Built against latest omni-9.0 tree
    This should fix the decryption issue on latest android 9.0 roms

    v10 (2018-09-25):
    Fixed wiping issue

    v9 (2018-09-24):
    Built against omni-9.0 tree, updated blobs from MIUI 10 Pie
    Fixed android 9.0 decryption
    NOTE: If you are on android 8.0/8.1, please use v8, I don't know if v9 would work with oreo

    v8 (2018-08-03):
    Synced with latest twrp code, version number now 3.2.3-0

    v7 (2018-07-20):
    Updated kernel and blobs to MIUI 10 8.7.19, fixed the non-booting issue after 8.7.16. Thanks for @simonsmh for fixing!
    Synced with latest twrp code, version number now 3.2.2-0
    Re-enabled MTP mode. If you have problems like crashing, please detach your device from usb.

    v6 (2018-06-09):
    Fixed wrong color in screenshots (thanks @wzsx150 for reporting)
    Disabled USB MTP mode.

    Note: This version has disabled USB MTP mode to take a try to fix the non-responsive problem as @TimesLeader suggested. If you need MTP feature, please stick to v5 and wait for TWRP fixing it.

    v5 (2018-06-06):
    Synced with latest omni and TWRP code (git-25b850d to git-ff9d097).
    touch vibration now works.
    removed the TW_BLANK_SCREEN_ON_BOOT option.

    note: If you encountered the non-responsive problem, please try to get me some logs (adb logcat, dmesg, etc). Reboot will recover from it.

    v4 (2018-06-03):
    Synced with latest TWRP code (git-72638b6 to git-bf4f24f, reverted 34ad728).
    Thanks @simonsmh for various fixes and cleanups!

    v3 (2018-05-26):
    No longer laggy UI! Thanks TWRP for their fix!
    Also thanks @joemossjr for a stuck-in-blank-screen problem.

    v2 (2018-05-21):
    Fixed the keystore problem. Now you can safely decrypt the /data partition.

    Disclaimer:

    Use this at your own risk!

    Works:

    ADB
    Decryption of /data
    Screen brightness settings
    Smooth UI
    Touch vibration


    Usage:

    Reboot to fastboot mode (unplug, poweroff, vol-dn+power until fastboot appears), then execute:

    fastboot boot recovery.img

    If your phone got stuck in "Downloading boot.img...", just reboot phone (long press power button) and try again.

    Flash to recovery partition (thanks for @sytayeth for testing):

    fastboot flash recovery recovery.img

    Source code and compile guide:

    https://github.com/notsyncing/android_device_xiaomi_polaris

    v15 Download: https://drive.google.com/open?id=10jqnlc0sVv0oWH2hYkxUglO5QhJwmnQd
    sha256: 508695c7b82933c413cf6521a3deb1b012fe34e155ebf21d2a6f2e69338e9ce4
    md5: baf3fa355339e0574b95897ec6a961a7

    v14 Download: https://drive.google.com/open?id=1Mhe0BF613HGWwt1gc_95vuXB-ETci6sb
    sha256: 16a977900abf77dedf75195239f122e0368d512ba9feb7fe0803823a3585c607
    md5: bbb2b7054cd52b72326bf2c39188ebe2

    v13 Download: https://drive.google.com/open?id=1nzqC1gKeI-XogjcUX4ZURz0OUT9Rshcg
    sha256: dc4c37fdeeaa2a12de9c54c292f0275de02497b0ec0866dca254b625fbc494a7
    md5: 404b9d4f22fa22d862c7b60db9d933bc

    v8 Download: https://drive.google.com/open?id=1Ge3WuWjjKoHWPIe9jvCtK2kGihHDE8Pm

    v8 recovery.img:
    sha256: 12b864620650ce55efa9971be89c14eb497cc9ca65cea2e5cee3d5e7b623bb9e
    md5: 6c55b55b6408111e9b8bbc50b4364317

    Thanks:

    @Travismills82 for his TWRP tree used as skeleton: https://github.com/travismills82/twrp_android_device_samsung_star2qltechn
    @teamwin for sagit TWRP tree used for partial decryption works: https://github.com/TeamWin/android_device_xiaomi_sagit
    @TimesLeader for dipper TWRP tree used for adb works:android_device_xiaomi_dipper
    @wuxianlin for enchilada TWRP tree used for init.rc works:android_device_oneplus_enchilada
    28
    It's official now! People can go to https://twrp.me/xiaomi/xiaomimimix2s.html to download the latest TWRP for MIX 2S.
    13
    TWRP 3.3.1-0 Unofficial v3 by palaych​

    • Add Vendor to the Wipe section
    • Update los kernel sources and compile with clang 9.0.5
    • Update twrp sources

    Download: https://drive.google.com/file/d/1JuD_pDGYoUqxq6ywXGtZbENwiFIsCYbG/view?usp=drivesdk
    13
    TWRP 3.3.1-0 Unofficial v1 by palaych

    Base on official device repo ( https://github.com/TeamWin/android_device_xiaomi_polaris ), tnx official maintainer.
    Update twrp sources.
    Work encryption with Android_r37+.

    Download: https://drive.google.com/file/d/17Mp1QqpNs4W5F9WSqxxM3kfLKy_h_P8a/view?usp=sharing
    10
    v7 is out now. The non-booting issue should be fixed. Please see OP for download.