[TWRP][JOAN][V30/V30+/V30S][UNOFFICIAL] 3.2.3-7 Oreo final - LG V30 ROMs, Kernels, Recoveries, & Other Developm

Hi!
!!! First things first: big phat huge !!!THANKS!!! to the full TeamWin Team, SGCMarkus (initial twrp tree), Phoenix591 (for inspiration), Dees Troy (for his trees), z31s1g for his brilliant theme and Captain Throwback (inspiration, too) !!!
For Pie ROMs you should use 3.3.1 recovery, either OrangeFox (based on TWRP with many very useful additions, with Magisk module manager being only one of it :good: ), or good old TWRP itself. 3.3.1 needed for decryption of pie ROMs!​
Feature list:
- capable of installing treble and/or vendorized ROMs
- Possibility to leave out lockscreen settings when restoring a backup (sometimes you have to delete them manually, otherwise no login into your restored ROM possible -.- You can bypass this with this. Note: lockscreensettings are independent from your encryption settings)
- Time and date is showed correctly, independent of /data
- some extra partitions (see below)
- Oreo 3.2.3-7: compiled with (modified) 8.1 TWRP branch
- Oreo recovery: Decryption of AOSP up to 8.1 and stock ROMs userdata is working (cherrypicked stuff for bringing that up), so, with this recovery, the urgent need for flashing no-verity-opt-encrypt zip isn't there anymore
Pie is not decryptable for the moment, neither with old Oreo recovery nor with newer PIe recovery: this is being worked on. Encryption changed in Pie, this needs some extra "love"
- everything working: backup, restore, decryption, time, mtp, adb, installing of treble or vendorized builds, themeable, .........
- modem image support: backup, restore, flashing of modem images either taken directly from kdz or via diskdump (this already was available but then broken at some point of time, sry for that! ).
- Same for OP image
Don't forget your timezone settings after flashing. Also there are some extra partitions you can mount/backup/flash/explore, like LAF, persist-LG and OP configs. There's the thought of some people to flash TWRP as a second copy to LAF partition to be on the sure side when it comes to ROM switching or sth like that. You can do this, anyway it's not really recommended (by me and some others) because you'll lose download mode, but you now have the option.
Also, if you want to restore an older backup, don't restore 'firmware' from it!!! This will break your WLAN, at least, and you have to flash a modem.img to get it back working.
For extra partitions: Some of them are needed for decryption (modem / persist-lg (drm)), some are for VoLTE (OP), time is stored on /persist/time (and /data/vendor/time), modem should be known and the LAF partition should be known already (described above).
For decryption: it works as it should. Therefore it is a little bit tricky to restore a ROM which has encrypted userdata, when you'd installed any other ROM in between. or formatted data There are some points to remember when restoring, a little guide is available in 3rd post, and some tipps too.
Some instructions:
How to flash?
If starting fresh with an unmodified phone, this thread should help you installing it
When you already have TWRP installed, you can flash this recovery from within TWRP:
- Tap "Install"
- Tap "Install image" button, located down right
- Locate your downloaded image and select it
- Select "recovery" from the list which shows up then
- Install; and reboot to recovery after installing immediately, don't use it for any other tasks until rebooted pls, as it may not function. Things can go bollox when phone wasn't rebooted to recovery after installing.
And of course you can flash it via fastbootmode. Reboot to bootloader (adb reboot bootloader; when magisk is installed, you can use magisk manager => module => menu on the top right => reboot to bootloader. You can reboot to recovery from there too) and then:
fastboot flash recovery <twrp-image-name.img>
When you experience errors or sth isn't working as it should in your opinion:
When an error occurs, pls supply me a log from TWRP, taken immediately after the error showed up. You can use the "Copy to SDCard" option (advanced options) in TWRP for this. Grab this file then and upload its content to pastebin.org.
I can't help without as much detailed info as you can supply. This should include at least following information: phone model, used TWRP image (exact name of image), task you wanted to do (which ROM e.g.).
There's now an optional version of TWRP available, which contains the inclusion of internal storage in data backups (IntSD version). Exclusions (folders which won't be backed up): TWRP, Movies, Music and Download folders. These won't be included in backups, as they can be really big.
With the recovery including internal storage you can backup to internal and external storage, no matter. The data_image recovery can backup its data image to external sd only, of course.
If you want to use data_image, system_image or internal storage included in data backup, first check your filesystem on your external sdcard. It needs to be capable of writing big files, which isn't the case with fat/fat16/fat32. You need exFAT (for stock) or ext4/ntfs (only available with custom kernel and/or AOSP based builds).
DOWNLOADS:
Oreo and Pie capable 3.2.3-7 TWRP:
Download links (always the latest and newest only; one version for all):
File name: TWRP-3.2.3-7-DataIMG.img (default)
MD5sum: aac1525f9bd85d6efbc0fb65bda4a904
MAIN Download: AndroidFileHost - TWRP-3.2.3-7-DataIMG latest
File name: TWRP-3.2.3-7-IntSD.img (non-default, includes main part of internal storage in data backup)
MD5sum: 23113ad33772a5f783dcabd09fa97ebb
MAIN Download: AndroidFileHost - TWRP-3.2.3-7-IntSD latest
Some additional words to different versions;
I personally use internal w/ sdcard backup, all my pics and almost everything possible app related on my phone is on external SDcard. Some data always remains on intSD (e.g. whatsapp, the Android folder which contains settings and app data too, k-9 mail folder and others), this needs to be in a backup for me. This is, what the intSD version does: but it leaves out the big folders (download, music, movie and TWRP).
As always: Use it at your own risk! You are the one who changes stuff on your phone, I'm not responsible for anything which happens to your phone. TWRP is powerful, be careful at what you do with it :good: And it just works.
All you need to compile this yourself:
[url]https://github.com/seader/android_device_lge_joan-twrp[/url]
[url]https://github.com/minimal-manifest-twrp/platform_manifest_twrp_omni[/url]
[url]https://github.com/seader/android_kernel_lge_msm8998[/url] (not really needed as a prebuilt kernel is used)
[url]https://github.com/seader/bootable_recovery-twrp[/url] (copy of twrp recovery with encryption cherrypicks and the stuff added. encrypt-8.1 branch = intSD version, master branch = DataIMG version)

Features:
- Treblelized / vendorized: one recovery for all
- Time and date working, getting this from persist partition
- decryption working for both stock and AOSP up to 8.1; Pie is being worked on [break atm ]
- additional partitions available
- "data_image" (default) and "internalSD included" (non-default) available
- Checkbox for leaving out lockscreensettings when restoring data partition (available in main settings and restore settings; in supported themes in main settings only!)
- TWRP app removed
Changelog:
21. April 2019, TWRP 3.3.0-00, new Pie recovery:
- Newest sources used, pie branches everywhere
- tiny menu structure overhaul
- almost all the stuff from Oreo recovery back in, except:
-- decryption
-- data image function
-- inclusion of internal sdcard in backups
-- everything else is working and included (special partitions, time and date working, all the default functions working, exclusion of lockscreen settings when restoring, TWRP su and app removed)
08. Dec. 2018, TWRP 3.2.3-7, old Oreo recovery:
- OP image flashing function added
- Sources update
Older:
09. Nov. 2018:
- treble ROMs are now installable
- brought back modem partition, fully working (remember to NOT restore the "firmware" partition!)
02. Nov. 2018:
- switched from prebuilt kernel to inline kernel building for easier future updates in terms of pie / treble
- removed modem/firmware partition from backup list
- included some QCOM optimizations for buildtime
- excluded TWRP app, install prompt for this app shouldn't pop up anymore (not tested by me)
- disabled logcat
26. Oct. 2018:
- increased compatibility for some scripts / flashable zips
25. Oct. 2018:
- added optional recovery with internal sd content added to data backups (the "data_image" version is the one you already may have installed, like 3.2.3-4-f, just renamed and containing the fstab edits)
- little fstab changes regarding modem / firmware: pls update
18. Oct. 2018:
- removed decrypt files from RAMdisk and added a link to firmware instead
- added possibility to leave out lockscreen-db* files while restoring
- added data_image option; read post #3 pls
15. Oct. 2018
- added decryption of stock and AOSP based ROMs
12. Oct. 2018, pt. 2 (succesful)
- finally fixed the OP mysery... A typo from my side, sry!!
12. Oct. 2018, pt. 1 (failed)
- Added versioning, TWRP now is 3.2.3-1
- re-sorted partitions list
- OP partition won't cause an error anymore on phones where it doesn't exist; sry, didn't know, that US998 doesn't have a OP partition! In addition, it doesn't look for me like there is an equivalent partition on these phones...?
11. Oct. 2018:
- fixed some warnings
- added some additional partitions
- made OP flashable and backupable
- made vendor 'removable', so no warnings anymore for non-vendor devices
- included logcat
- added local_manifest, patch for timefix and a little description in readme
How to (re)boot to TWRP?:
If your phone is rooted:
- Magisk has options to reboot to different targets like bootloader or recovery, but this menu is a little bit hidden: you can access it by starting Magisk.Manager, going to the "Module" menu, tapping on the three dot menu on the top right. Then select your target
- If a terminal emulator is installed, open it, type "su" followed by enter and type "reboot recovery"
- You can do the same with an adb shell, open a shell and type the commands from above, they're the same
- There also are apps for rebooting to recovery or other targets. Just search around in PlayStore
- The good old "button dance" When phone is powered off, press the volume down key and power button at the same time. When a first sign of life is seen on display, immediately release the power button, but just to instantly press it again. A menu will show, which wants you to do a factory reset: do it You have to confirm this two times, and afterwards TWRP will boot without performing a factory reset. TWRP is compiled with a flag which recognizes this procedure and hinders the bootloader to pass the command for factory resetting.

Some additional infos:
- vendor partition: it's there for everyone (no more present in TWRP 3.3!). It is flagged as removable, so it can be leaved in fstab without producing errors. Ppl w/o a vendor partition (which you need to create via script when you want to flash treblelized AOSP builds) shouldn't let themselves get confused about that, it's an additional entry like external sdcard or USB OTG.
- kdzwriter: still untested (and no more present in 3.2, in 3.3 it never was), respectively tested with 21h kdz, which told me "not applicable for this device". I for know mark this as non-working. I'll leave it in this recovery, for future updates and other testers with other kdz file (no more inside).
- data image backup: chose SDCARD for backup location, and enable compression otherwise it's an ~55gb image lol. (<= it IS an 55gb image, no matter of compression. Compression doesn't work for images! So prepare for a huuuge file, and think about your filesystem on sdcard (can it handle big files? For AOSP you can chose ext4 or exfat, for stock exfat only)). This option includes internal sdcard, which is in /data/media. This can be used to do a real full backup with absolutely everything needed (incl. /sdcard/Android folder, your music, vids or anything else e.g.).
- time: when it goes wrong again, just delete the /persist/time folder from within recovery, boot up android and reboot to recovery. Should be "fixed" now. This folder isn't present in 3.3: here you can try to delete "/persist/.twrps" file (you need to re-setup TWRPs settings then) and the folder "/data/vendor/time", followed by a reboot to ROM and then to recovery again. May ned one or two reboots more to ROM or TWRP to get TWRP recognize the time correctly.
Encryption:
There's something you need to remember when restoring encrypted backups, after you have flashed another ROM (which differs from the one to restore): your secure startup settings. Write them down or have them in mind, you need it. Steps for restoring an stock or AOSP data partition encrypted backup:
- format data
- first restore your ROM only partially, means only boot and system (and only that)
- boot into your ROM you've restored
- go through the setup manager and afterwards hop into security and encryption settings
- encrypt your phone exactly the same way it was in your backup you want to restore encrypted userdata from; for 3.3 recovery it's only needed to set up any encryption config, you can put in what you want for yourpin / pattern / passwd
- if it is encrypted already, you only have to redo security settings. Use the same settings as in the backup, means pin/pattern/pw need to be the same *and* secure startup too, if you've chosen it before (see above for pie and 3.3 recovery: you can use anything. Youcan try this with oreo too, maybe it works too)
- reboot to recovery again and restore your encrypted data partition (from the backup you've already restored system and boot from)
- now you're good to go You should tick "Don't restore lockscreen settings" for leaving out the lockscreen.db* files. Otherwise you have to delete them manually to be able to get into your ROM, because lockscreen settings will prevent it. Lockscreen settings btw. are independent of encryption settings. It's the same pattern/pin/pw used, but another building site.
If you want to encrypt your AOSP ROMs userdata (only possible if you are on android up to 8.1), you can use the attached fstab file (it's for LOS 15.1 non treble), either as an example or to overwrite the existing one. Have a look at the line which contains "userdata". The fstab file is located in /system/vendor/etc/. Unzip the attachment (it is no flashable zip), put it in the correct location and overwrite the original file. Reboot your phone, then go into security settings, you should now be able to encrypt it.
This TWRP can't handle decryption of AOSP 9.0 encrypted data atm, you need 3.3 TWRP for that. There changed something from 8.1 to 9.0 which means the new stuff needed new recovery, which is included with 3.3 recovery.
Additional stuff:
- Recommended theme (original thread): [THEME][TWRP] TWRP Materialised - Black / Dark / Light / Play [27/01/18]
Edited versions of this theme, with menu entries added:
Black and Dark theme versions available here. There are two version of each: one showing "incl. internal" and one without, both have the lockscreen settings exclusion checkbox included. You'll now find this menu entry in main settings page only, it was there before too, but there was an additional entry when restoring a backup. This is gone in this theme as it didn't fit the way I wanted it to fit Pick the one you need.
Included storage: version for recovery "IntSD"
Without storage: version for recovery "DataIMG"

can i just update it by flashing it in the twrp 3.2.1-02 treble as img?

seadersn said:
reserved #2
Click to expand...
Click to collapse
What's the difference between the AFH file and Mega file?
Sent from my LG-H932 using XDA Labs

black metallic said:
can i just update it by flashing it in the twrp 3.2.1-02 treble as img?
Click to expand...
Click to collapse
yes, and then reboot to recovery again
TWRP can simply be updated that way.
BROKEN1981 said:
What's the difference between the AFH file and Mega file?
Sent from my LG-H932 using XDA Labs
Click to expand...
Click to collapse
Im 99.9% sure thats a mirror, incase AFH is slow again.

SGCMarkus said:
yes, and then reboot to recovery again
TWRP can simply be updated that way.
Im 99.9% sure thats a mirror, incase AFH is slow again.
Click to expand...
Click to collapse
I figured as much. I had a night that AFH wanted 3 hours to download TWRP. A Google speed test gave me 78mbps.
So yeah, seems Mega is the way to go
Sent from my LG-H932 using XDA Labs

First, thanks for this. Second, what's the difference b/w the earlier "tfp" img and this "tfp-kdz" img?

joarce said:
First, thanks for this. Second, what's the difference b/w the earlier "tfp" img and this "tfp-kdz" img?
Click to expand...
Click to collapse
Stated in op. This image allows for writing of some stuff from kdz files.
Sent from my LG-US998 using Tapatalk

jip, thx

SGCMarkus said:
yes, and then reboot to recovery again
TWRP can simply be updated that way.
Im 99.9% sure thats a mirror, incase AFH is slow again.
Click to expand...
Click to collapse
cool, can i still use treble and wipe tge vendor?

I don't know if I understand it correctly. Pls correct me If I'm wrong.
The benefit of KDZ Writer is that we can update system from KDZ in TWRP.

Thanks will try this

Running it now (H932). Thank you.

seadersn said:
So, here it is: a new (the third for v30...?) thread for an already existing recovery.
Click to expand...
Click to collapse
Actually the 4th, but thank you!
First one was "H930" (which confused US998 users when they got bootloader unlock and root), 2nd one was for "US998" to counteract the H930 confusion -- but really should have been "V30" or "JOAN". @SGCMarkus then made one which not only was Oreo compatible but was "unified". Now this is 4th.
The unification thing is important. I saw over in Moto Quark threads (Droid Turbo, Moto Maxx, Moto Turbo -- all the same phone) where one initial forum was split into two because Droid Turbo at first didn't have bootloader unlock and root, the OTHER Quarks (Moto Maxx, Moto Turbo) jumped ahead in development. Then a year later when Droid Turbo got bootloader unlock and root, thanks to Sunshine, the CM dev at the time generously modified his kernel to include Droid Turbo (which was in a different "dead" forum by then). Thus all the Quarks were unified in development and could all run the same ROMs, same TWRP.
Whereas with one LG flagship phone (which I can't find right now), starting having split development. TWRP and dedicated ROMs for European (which again got bootloader unlock first, thanks to LG's mysterious ways) but then separate older TWRP and a few ROMs for the North America open market. Maybe that's improved now, which is why I can't find it, but I remember thinking "that's not right" and I didn't want that to happen to the V30.

Is the vendor partition mountable ?
Are trebleized ROMs flashable ?

Thanks for providing the new, current version of TWRP. V30 really needed an update for this. No more incorrect times/dates and Magisk giving an error due to false time/date.

Can you give a quick "dummies " tutorial on how to replace the old twrp with this new version using twrp?
Thx.

gimpy1 said:
Can you give a quick "dummies " tutorial on how to replace the old twrp with this new version using twrp?
Thx.
Click to expand...
Click to collapse
I put the new image on sd card. Booted to current TWRP. Flashed new image to recovery partition. Rebooted to system.
Mine took a few reboots to settle in. Couldn't get to it using reboot manager app. Was getting ready to do button dance, but tried reboot app one more time and it booted me to new TWRP. Everything's great now. I don't know if you're supposed to boot back to recovery after flashing the new image. That's what I didn't do.
Sent from my LG-US998 using Tapatalk

Krekos/CZ/ said:
I don't know if I understand it correctly. Pls correct me If I'm wrong.
The benefit of KDZ Writer is that we can update system from KDZ in TWRP.
Click to expand...
Click to collapse
jep, that's the intention of this tool. have a look at the pic in first post there's more to flash via kdzwriter.
FcBayernMinga said:
Is the vendor partition mountable ?
Are trebleized ROMs flashable ?
Click to expand...
Click to collapse
comes this evening, i need a bit of time for relaxing now, but i don't get it because of kids xD
Ballroomblitz said:
... I don't know if you're supposed to boot back to recovery after flashing the new image. That's what I didn't do.
Sent from my LG-US998 using Tapatalk
Click to expand...
Click to collapse
jep, this is needed! after flashing of new recovery reboot to recovery. :good:

Related

[RECOVERY][nozomi] TWRP 3.0.0-0 touch recovery [2016-02-06]

Team Win Recovery Project 3.x, or twrp3 for short, is a custom recovery built with ease of use and customization in mind. Its a fully touch driven user interface no more volume rocker or power buttons to mash. The GUI is also fully XML driven and completely theme-able. You can change just about every aspect of the look and feel.
CHANGELOG for 3.0.0-0:
-Completely new theme - Much more modern and much nicer looking (by z31s1g)
-True Terminal Emulator - Includes arrow keys, tab and tab completion, etc. (by _that)
-Language translation - It won’t be perfect and especially some languages that require large font files like Chinese & Japanese won’t be availble on most devices. Also some languages may only be partially translated at this time. Feel free to submit more translations to OmniROM’s Gerrit. (mostly by Dees_Troy)
-Flashing of sparse images - On select devices you will be able to flash some parts of factory images via the TWRP GUI (by HashBang173)
-Adopted storage support for select devices - TWRP can now decrypt adopted storage partitions from Marshmallow
-Reworked graphics to bring us more up to date with AOSP - includes support for adf and drm graphics (by Dees_Troy)
-SuperSU prompt will no longer display if a Marshmallow ROM is installed
-Update exfat, exfat fuse, dosfstools (by mdmower)
-Update AOSP base to 6.0
-A huge laundry list of other minor fixes and tweaks
WARNING: This is our first release in a long time. We have a lot of new and somewhat aggressive changes in this new release. The changes to the graphics back-end may cause some devices to not boot up properly or have other display-related issues. If you are not in a position to reflash an older build of TWRP, then wait until you are or at least wait until others have tried the new version for your specific device. You don’t want to end up with a non-working recovery and have to wait several hours or days to get to a computer to be able to fix it.
Notes for themers: In addition to the udpated theme, we have introduced a theme version variable to the TWRP theme system. If the theme version does not match the version that TWRP expects, TWRP will reject the custom theme and load its stock theme. This change will ensure that people who update TWRP without updating their theme will still have a workable recovery. We have removed libjpeg support. The stock theme was only using a jpeg image for the splash / curtain. This change means that any custom themes will no longer be able to use jpeg images. It also means that tools used to repack recovery images with a different curtain / splash will need to be updated to use the new method.
Version number notes: For a while we’ve been using a 4 digit version number and reserved the 4th digit for device-specific updates. For instance, we find and fix a device-specific issue like decryption of data on Nexus 5, we would release that as a 2.8.7.1. After a while, some people would start asking where 2.8.7.1 was for other devices. So, going forward we have decided to change the numbering scheme to 3.0.0-2, etc. Our hope is that this version numbering scheme will more clearly identify that the 4th digit does not indicate a version change for the code base.
We need your help! The bulk of TWRP work is done by 3 people on a volunteer basis. We have pushed most of our device files to our github and we have a gerrit instance. If you have the ability, please help us maintain our official devices and/or add your device to our official device list. Thanks in advance!
CHANGELOG for 2.8.7.0:
-Initial ground work for software drawn keyboard (_that)
-Fix handling of wiping internal storage on datamedia devices (xuefer)
-Allow DataManager to set and read values from the system properties (xuefer)
-Fix crash when taking screenshots on arm64 devices (xuefer)
-Fix error message after an ORS script completes (Dees_Troy)
-Fix crashes / error when creating encrypted backups (_that, Dees_Troy)
-Add system read only option – more details below (Dees_Troy)
-Add resize2fs and GUI option to run resize2fs (Dees_Troy)
-Fix crash loop caused by empty lines in AOSP recovery command file (_that)
-Prevent duplicate page overlays such as multiple lock screens (mdmower)
Note: As always, be sure your custom theme is up to date (or remove your custom theme) before updating TWRP.
System read only option: Devices that ship with 5.0 and higher as their initial OS are using block level OTA updates. With this style of OTA update, the update script checks to see if the system partition has ever been mounted read/write. Further, the script also usually runs an SHA sum of the entire system partition to detect if any changes have been made. If any changes have been made, the OTA update will refuse to install. Since not all OEMs and devices have factory images available, we have created a new feature in TWRP that detects if the system partition has ever been mounted read/write. If not, you will be prompted asking if you want TWRP to mount system as read/write. If you choose not to allow TWRP to mount as read/write, TWRP won’t prompt to install SuperSU and TWRP won’t try to patch the stock ROM to prevent TWRP from being replaced by stock recovery. The goal of this option is to hopefully allow the user to make a raw system image backup that they can use to get back to a state where they can take OTA updates again.
resize2fs feature: On some devices like the Nexus 6, the factory images include a userdata image that is the proper size only for the 32GB units. If you flash the factory image to a 64GB Nexus 6, the data partition will appear as if it only has the free space of a 32GB device. Using the resize2fs option, TWRP can resize your data partition to take up the full space available. The resize2fs may also be useful to resize system partitions on devices where custom ROM system images don’t take up the full partition space. Lastly, resize2fs may be useful in some cases to reserve the proper space at the end of a data partition for a full disk encryption key, should your partition be formatted incorrectly for some reason.
This new version also marks our first set of full builds using our new jenkins build server. You can track the progress of builds at https://jenkins.twrp.me and we have taken additional steps to make it easier for device maintainers to step up and submit patches to our gerrit server at https://gerrit.twrp.me to help us keep devices up to date and working.
DOWNLOAD:
Most devices can be updated quickly and easily within TWRP if you already have version 2.8.4.0 or higher installed
1) Download the latest version from our website on your device
2) Reboot to TWRP
3) Hit Install and tap the "Images..." button in the lower right
4) Browse to the location of the TWRP image on your device and select it
5) Select recovery from the partition list and swipe to flash
OR:
You can find more information and download links on our NEW website! NOTE that the 2.8.6.0 version is ONLY available on our new site and is not available on our other, older mirrors!
BUGS:
If you have found a bug, please consider posting it to our github issues log. It's pretty much impossible for us to keep up with the more than 40 threads that we have for the devices that we "directly" support. If you have a significant problem that cannot be answered in this thread, your best bet is to PM me directly, contact us via our website, or find us in our IRC channel below. If you see someone that's struggling, feel free to point it out to us. We need your help to help us keep track of all of our devices! Thanks!
SUPPORT:
Live support is available via #twrp on Freenode with your IRC client or just click this link.
More information:
Most Xperia S kernels are probably including CWM by default in the boot image. About a month ago I submitted some changes to the CyanogenMod repos that were accepted. Newer builds of CM include a special extract_elf_ramdisk utility that I wrote to read and extract a recovery ramdisk from the FOTAKernel partition instead of using the ramdisk that is included in the boot image. If the ramdisk in the FOTAKernel partition is a stock Sony ramdisk or not present, then the existing ramdisk in the boot image is used instead. This setup allows users to choose which recovery they want to keep installed. This same setup is possible in other kernels including stock Sony kernels. On our website's download link you will find a copy of a recent stock ICS kernel for the Xperia S that includes TWRP as well as the extract_elf_ramdisk utility.
If the kernel you have installed doesn't support this extract_elf_ramdisk setup, then you won't be able to use the GooManager installed copy of TWRP. Bug your kernel or ROM developer and ask them to update their images so that you can choose what recovery you want.
What is the FOTAKernel partition?
The FOTAKernel partition is used by Sony to do FOTA updates when updating the boot image. Unlocked devices can't take Sony FOTA updates so using this partition for storing the recovery ramdisk seems like a good idea. Unlocked users aren't able to use this partition anyway and the FOTAKernel partition is effectively the "recovery" partition on Sony devices.
Thanks a lot but from your site can we get only 2.4.0.0. And it's for the oldest rom kernel (.452). Can you please update the ramdisk and modem for the our Xperia S?
anychange for locked BL?
Advance Stock Kernel 17 comes with CWM.
How Can I install this over CMW?
eScapeeXc said:
Thanks a lot but from your site can we get only 2.4.0.0. And it's for the oldest rom kernel (.452). Can you please update the ramdisk and modem for the our Xperia S?
Click to expand...
Click to collapse
You should take a look at the "Download - FOTAKernel Image" header. There's no need to install that stock kernel, you can also just push the recovery. The way described on the website requires you use Terminal Emulator but there's an easier way. (I also don't really understand which is the right version because there is 2.4.3.0 for nozomi and 2.4.3.0 for LT26i and afaik that's the same device).
Just install GooManager on your phone, select "Flash ROMs" and there should be a message asking if you have a custom recovery. Select to install one and the latest version of TWRP will be installed.
I'm using Stock+ kernel, that already had TWRP 2.4.1 recovery, after doing this with GooManager I have TWRP 2.4.3.0. If you're using any of the other .55 kernels it should be work as well.
mrkidvn said:
anychange for locked BL?
Click to expand...
Click to collapse
No idea.
darkerm said:
Advance Stock Kernel 17 comes with CWM.
How Can I install this over CMW?
Click to expand...
Click to collapse
That's basically the same question eScapeeXc asked so the answer is the same .
Re: [RECOVERY] TWRP 2.4.3.0 touch recovery [2013-03-01]
Is it works on locked bootloader?
Sent from my LT26i using xda app-developers app
Will:
dd if=/dev/zero of=/dev/block/mmcblk0p11
remove the recovery?
Is there a way to choose between the recovery from the kernel and this one on fota while booting?
How many space has the fota partition on our device?
algates said:
Is it works on locked bootloader?
Sent from my LT26i using xda app-developers app
Click to expand...
Click to collapse
It needs a modified ramdisk. So it will not work.
Sv: [RECOVERY] TWRP 2.4.3.0 touch recovery [2013-03-01]
Dees_Troy said:
More information:
Most Xperia S kernels are probably including CWM by default in the boot image. About a month ago I submitted some changes to the CyanogenMod repos that were accepted. Newer builds of CM include a special extract_elf_ramdisk utility that I wrote to read and extract a recovery ramdisk from the FOTAKernel partition instead of using the ramdisk that is included in the boot image. If the ramdisk in the FOTAKernel partition is a stock Sony ramdisk or not present, then the existing ramdisk in the boot image is used instead. This setup allows users to choose which recovery they want to keep installed. This same setup is possible in other kernels including stock Sony kernels. On our website's download link you will find a copy of a recent stock ICS kernel for the Xperia S that includes TWRP as well as the extract_elf_ramdisk utility.
If the kernel you have installed doesn't support this extract_elf_ramdisk setup, then you won't be able to use the GooManager installed copy of TWRP. Bug your kernel or ROM developer and ask them to update their images so that you can choose what recovery you want.
What is the FOTAKernel partition?
The FOTAKernel partition is used by Sony to do FOTA updates when updating the boot image. Unlocked devices can't take Sony FOTA updates so using this partition for storing the recovery ramdisk seems like a good idea. Unlocked users aren't able to use this partition anyway and the FOTAKernel partition is effectively the "recovery" partition on Sony devices.
Click to expand...
Click to collapse
Does this mean that flashing TWRP on Xperia S, this way, will prevent it from being overwritten every time a new kernel is flashed?
twk99 said:
Does this mean that flashing TWRP on Xperia S, this way, will prevent it from being overwritten every time a new kernel is flashed?
Click to expand...
Click to collapse
Yes.
twk99 said:
Does this mean that flashing TWRP on Xperia S, this way, will prevent it from being overwritten every time a new kernel is flashed?
Click to expand...
Click to collapse
[email protected] said:
Yes.
Click to expand...
Click to collapse
Keep in mind, if kernel you are using doesn't implement elf extract then it will not read FOTA partition so it still use recovery that came with kernel.
And almost all kernel came with CWM.
Sv: [RECOVERY] TWRP 2.4.3.0 touch recovery [2013-03-01]
tosa.th said:
Keep in mind, if kernel you are using doesn't implement elf extract then it will not read FOTA partition so it still use recovery that came with kernel.
And almost all kernel came with CWM.
Click to expand...
Click to collapse
I understand that. I am using latest FXP CM10 so it should work right?
i rooted my uncle sxs like this http://forum.xda-developers.com/showthread.php?t=2133063 after that i installed cmw with this http://forum.xda-developers.com/showthread.php?t=1756346
yes i have unlocked the bootloader. but now the recovery says cannot mount cache/recover/log etc.
i post this here because after installing opensemc 0.4 the problem is still there. only after a factory reset and installing 2 times it will boot.
is this a problem some one reconizes?
R: [RECOVERY] TWRP 2.4.3.0 touch recovery [2013-03-01]
raydekok said:
i rooted my uncle sxs like this http://forum.xda-developers.com/showthread.php?t=2133063 after that i installed cmw with this http://forum.xda-developers.com/showthread.php?t=1756346
yes i have unlocked the bootloader. but now the recovery says cannot mount cache/recover/log etc.
i post this here because after installing opensemc 0.4 the problem is still there. only after a factory reset and installing 2 times it will boot.
is this a problem some one reconizes?
Click to expand...
Click to collapse
I read that FXP official kernel support external recovery from 3-4 release
But maybe raymanfx has not implemented this
Btw that recovery is a crap.. Try advanced stock kernel
Sent from my Xperia S using xda app-developers app
just flash this thru the current recovery?
and install rom again?
twk99 said:
I understand that. I am using latest FXP CM10 so it should work right?
Click to expand...
Click to collapse
I don't use FXP, so I don't know is it support elf extract.
Check with FXP team about their kernel if it does support then you are good to go.
reading a bit more and i can instal the recovery thru goomanager and thats it. so i install the recovery again. is it so simpel?
Re: [RECOVERY] TWRP 2.4.3.0 touch recovery [2013-03-01]
Installing seems ok. But how can I uninstall twrp from fota?
Sent from my LT26i using xda premium
raydekok said:
reading a bit more and i can instal the recovery thru goomanager and thats it. so i install the recovery again. is it so simpel?
Click to expand...
Click to collapse
quote myself. this worked but under mount he can not select mount /system.
under my phone i can. what would that be?

[RECOVERY][UNOFFICIAL_MOD][DECRYPTION][UPDATED-02-01-2019] TWRP 3.2.3-4 for nitrogen

SUPPORTS ALL TYPES OF USERDATA DECRYPTION FOR BOTH OREO AND PIE ROMS - PASSWORD, DEFAULT_PASSWORD, PATTERN, PIN!!!
SUPPORTS BOTH FULL AND INCREMENTAL OTA UPDATE PACKAGES AUTOMATIC INSTALL!!!​​
Sharing my unofficial TWRP recovery mod for nitrogen which I have started about 2 years ago for hydrogen/helium. For more details visit https://forum.xda-developers.com/mi-max/development/recovery-twrp-3-0-2-2-hydrogen-helium-t3512981...
This is and will be work in progress with fixes and reasonable features to be added.
Download:
(02-01-2019)twrp_v323-4_nitrogen_nijel8-MOD.img​
To install:
- USB connect device to PC
- reboot to fastboot
- open Command prompt/Terminal in the folder with the recovery image and run these commands line by line:
Code:
fastboot flash recovery (XX-XX-XXXX)twrp_v323-X_nitrogen_nijel8-MOD.img
fastboot boot (XX-XX-XXXX)twrp_v323-X_nitrogen_nijel8-MOD.img
or just flash the image with TWRP selecting recovery partition
- reboot from the fresh recovery - it'll take few seconds... let it do its magic to survive MIUI stock recovery replace at system boot. This will happen whenever you install any new ROM.
Done... This TWRP will not go anywhere, /system is untouched so you can get MIUI OTAs, no need to root if you don't want to, no need to flash anything else, MIUI boots just fine having no idea about the recovery, everybody's happy...
NOTES:
ROM install:
- skip wiping Data even if switching different ROMs. Do dirty install, see how it runs, if no problems, great... you saved yourself from doing the initial
setup. If having issues then wipe Data and see how it goes...
- You do not need to wipe/format/factory reset anything before install(see above), especially System and Vendor.
- Do not install any patches like lazyflasher, sound or whatever mods, root-on-system etc that are altering System or Vendor partitions on stock MIUI without installing Magisk first or system will not boot!!!
MIUI OTA Install:
- Let MIUI download update and press "Reboot" when prompted
- Device will reboot to TWRP and start installing it.
- If device reboots to system automatically - all good, update successful
- If device does not reboot you should see some error in red
- Just flash the zip package in Internal storage -> downloaded_rom folder and reboot to system
- Done - you just got your OTA
Decryption:
If MIUI asks for decription password after reboot from TWRP don't panic!
You will most likely never see this but as anything in this live sh*t happens. I for example have seen this only once in hundreds of TWRP and MIUI flashings and reboots to system and it happen after reboot from MIUI OTA testing. Did I mentioned I never do clean installs? Why bother wiping if no post-install issues, right...
Anyway... here is how to get back to normal without loosing any data:
- Reboot back to recovery by pressing and holding POWER + VOLUME UP buttons
- Run Data backup in TWRP
- USB connect device to computer and copy all personal data you don't wanna loose from Internal storage to computer
- DO NOT FORGET TO COPY THE DATA BACKUP YOU JUST MADE FROM TWRP/BACKUPS/XXXXXX TO COMPUTER TOO!!!
- Click Wipe -> Format data -> type yes -> [ENTER]
- Reboot to MIUI and let it encrypt the device. You will see Setup new device wizard when its done
- Reboot back to recovery by pressing and holding POWER + VOLUME UP buttons
- Copy back all your personal data including the recent Data backup from computer to Internal storage -> TWRP/BACKUPS/XXXXXX
- Reboot recovery so TWRP can detect the Data backup you copied
- Restore Data backup and reboot to MIUI
- Done - MIUI should boot without complaining and all your data is intact... even your old lockscreen password and fingerprints should work
Backup/restore:
- normal backup includes Data only, you can always flash what you are running currently to restore boot, system and vendor
- if you have modified boot,system or vendor post install you can back them up to keep your changes
- You do not need to wipe/format/factory reset anything before restore... restore does that for you
Some observations during my extended decryption testing with China and Global MIUIs 8.1 and 9.0, EU MIUIs, MIUIPro, etc:
- Downgrading to ROM with lower security patch level brakes encryption in Android but not in TWRP so just boot back to recovery, backup your data to safe location, format data, restore data back and you are good to go...
- Some times switching back and forth passwords types(pin, pattern etc...) brakes encryption and you loose your data, no way back!!! This is ROM fault and not TWRP. Crypto footer just gets corrupted from Android... I have taken good measures for this not to happen in my TWRP so don't blame recovery if that happens to you...​
Changelog:
[02-01-2019
- hide navbar during running operarions
- more userdata decryption reliability improvements
- Mi bunny is terrified loosing recovery control
- sync with latest Omnirom android-9.0 sources
[01-28-2019
- fix decryption with good user password on next retry if wrong password was entered before that
- improve TWRP persist
- sync with latest Omnirom android-9.0 sources
[01-09-2019
- fix system boot after restoring regular file-for-file backup on ext4 file systems(System and Vendor) - now any backup type works for any partition of any ROM
- sync with latest Omnirom android-9.0 sources
[01-07-2019
- fix installing incremental OTA patching boot - this will start working properly after your first full ROM install with new recovery(boot.img flash)
- fix loading settings from /persist if decryption fails
- made sure we always keep current settings copy on /persist
- remove excessive save settings calls
- some minor improvements
- sync with latest Omnirom android-9.0 sources
[01-05-2019
- fix incremental OTA update automatic install
- sync with latest Omnirom android-9.0 sources
[01-04-2019
- new much smaller Pie kernel built from source with LineageOS 16.0
- much smaller recovery image(see above)
- sync with latest Omnirom android-9.0 sources
[12-29-2018
- improved decrypt routine
- some minor fixes and improvements
- sync with latest Omnirom android-9.0 sources
12-28-2018
- much improved and reliable decryption routine for preventing crypto footer corruption and loosing all your data - this update is highly recomended
- fix Android 9.0 userdata decryption with custom user set password, pin or pattern
- more reliable format data routine for crypto footer support
- disable useless and sometime buggy reboot check for system size(No OS installed msg)
- sync with latest Omnirom android-9.0 sources
12-27-2018
- migrate to Android-9.0 for android tree and TWRP sources
- switch to MIUI Pie prebuilt kernel
- speed up userdata decryption
- fix userdata decryption for Android-9.0 with default password only. At this time userdata decryption wit user set password is not supported! Working on it...
- sync with latest Omnirom android-9.0 sources
11-25-2018
- fix survival routine hang/bootloop after openrecoveryscript execution(OTA)
- improved decryption handling
11-23-2018
- fix userdata decryption - no more inaccessible userdata in TWRP
- fix vendor missing from partitions to restore list in some cases
- fix TWRP bootloop trying to apply survive magic in some cases
- finaly fix crypto footer for F2FS partition formating(tested and working!!! - you can format userdata in TWRP without any system boot issues now)
- skip survive magic for good ROMs to speed up reboot
- translatable and more user friendly survive system boot screen - If you want to help translate and PM me these strings:"
Code:
<!-- Survive system boot strings -->
<string name="survive_line1">Checking if TWRP will survive system boot!</string>
<string name="survive_line2">Please, wait...</string>
- sync with latest Omnirom android-8.1 TWRP sources
11-12-2018
- fix TWRP system boot survive - no need to flash anything to prevent stock recovery reflash at MIUI boot
- fix crypto footer for F2FS partition format - need no more fastboot format userdata for system boot with forced encription enabled(needs testing)
- fix error when creating ext2, ext3, or ext4 filesystem in some cases(needs testing)
- some minor fixes and optimizations
- kernel compiled from source at build time
- build with latest Lineage OS 15.1 sources
- sync with latest Omnirom android-8.1 TWRP sources
Github sources:
NITROGEN TWRP device tree
TWRP Mod repo
Kernel source
Thank you:
TeamWin for the initial device tree!
Omnirom/TeamWin for the TWRP source code!
@topjohnwu for the magiskboot source code!
Yes, You finally stepped in.
you save my life thankyou sir. unlocked bootloader today as i waited for 720 hrs. as i known i can skip by 9001 mode i just wait the official unlock to play safe. missed you so much since max1 thankyou sir
Just noticed on 4PDA forum there is a bug when you try restore vendor is missing from the list of available partitions at first... Well, it's not a bug... It's something I had to add for hydrogen...
Yeah, I know exactly what you guys are talking about... Back in the days when I was trying to bring treble to Max1 I added some code to detect in the fly if vendor partition is available on the running device so I can hide it in UI if ROM was Nougat or show it if was treblelized. I forgot about it and now it causes inconvenience on Max3. Will get it fixed in the next release.
Thaks for the reminder 4PDA guys...
nijel8 said:
Just noticed on 4PDA forum there is a bug when you try restore vendor is missing from the list of available partitions at first... Well, it's not a bug... It's something I had to add for hydrogen...
Yeah, I know exactly what you guys are talking about... Back in the days when I was trying to bring treble to Max1 I added some code to detect in the fly if vendor partition is available on the running device so I can hide it in UI if ROM was Nougat or show it if was treblelized. I forgot about it and now it causes inconvenience on Max3. Will get it fixed in the next release.
Thaks for the reminder 4PDA guys...
Click to expand...
Click to collapse
I hope that you are able to create an un-official build of LineageOS for Mi Max 3
I thank you for your time for creating this un-offical twrp build as its faster than the official one
have a great week!
Going to keep an eye on this.
300 hours left for my Mi Max 3, will flash this when I unlock.
What's different between this and official TWRP may I ask?
omer919 said:
I hope that you are able to create an un-official build of LineageOS for Mi Max 3
I thank you for your time for creating this un-offical twrp build as its faster than the official one
have a great week!
Click to expand...
Click to collapse
Don't know if it's faster but should be more bugs free...
AsadP2013 said:
...
What's different between this and official TWRP may I ask?
Click to expand...
Click to collapse
Read first post and changelog, then click the link for more info and read the looong changelog there as well.
But if I have to summarize the dev is listening and every bug terminated right away...
Oh... and the most important thing... Dev has the device and runs on it only what he builds himself... You get what the dev gets and he hates it when something's not working as intended.
Hope this helps...
nijel8 said:
Don't know if it's faster but should be more bugs free...
Read first post and changelog, then click the link for more info and read the looong changelog there as well.
But if I have to summarize the dev is listening and every bug terminated right away...
Click to expand...
Click to collapse
Thanks, no I have had a look but in short, what would you say?
Do you reckon that it has more features and is capable of doing slightly more?
Basically, should I use this TWRP over official as I'm a modder/tweaker?
Or should I flash it for the sake of it providing more than official?
Ohh Sir @nijel8 I've tried, but incremental OTA updates does not installable with this rec.
(Or I am making a mistake.)
JulianJenner said:
Ohh Sir @nijel8 I've tried, but incremental OTA updates does not installable with this rec.
(Or I am making a mistake.)
Click to expand...
Click to collapse
More specifics, please, recovery.log. What not installable means?
The only reason OTA would not install is if the updater-script checks boot partition checksum. Can you post its content?
I would test it myself but I am away from home right now...
Thx. I am back to miui with chinese PC suite (full clean install)
I will try again. When I have time again.
I've found on baidu a new TWRP a lot of settings and partition backup
http://www.mediafire.com/file/04xqp...-1030-XIAOMI_MAX3-CN-wzsx150-fastboot.7z/file
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
小米MIX标准版4GB128GB银色MIUI10中国开发者8.11.13
JulianJenner said:
Thx. I am back to miui with chinese PC suite (full clean install)
I will try again. When I have time again.
I've found on baidu a new TWRP a lot of settings and partition backup
http://www.mediafire.com/file/04xqp...-1030-XIAOMI_MAX3-CN-wzsx150-fastboot.7z/file
View attachment 4642012
View attachment 4642013
View attachment 4642014
View attachment 4642015
小米MIX标准版4GB128GB银色MIUI10中国开发者8.11.13
Click to expand...
Click to collapse
One thing I should've mentioned... Since recovery hardware decryption is not fixed yet after OTA update.zip is downloaded you have to move it to nonencrypted accessable location like external SD Card or OTG reboot to recovery and flash it manually.
Another thing I should mention is although decryption with default passwords is not working decryption with user password should work. Don't ask me how to switch from default to user password encryption... I am not familiar with MIUI.
I just testing. No problem.
小米MIX标准版4GB128GB银色MIUI10中国开发者8.11.13
nijel8 said:
One thing I should've mentioned... Since recovery hardware decryption is not fixed yet after OTA update.zip is downloaded you have to move it to nonencrypted accessable location like external SD Card or OTG reboot to recovery and flash it manually.
Another thing I should mention is although decryption with default passwords is not working decryption with user password should work. Don't ask me how to switch from default to user password encryption... I am not familiar with MIUI.
Click to expand...
Click to collapse
I think, there is not the encryption/decryption is the bigger problem.
Max3 MIUI ROMs contains a scrip, that it rewrite MiRecovery, but this action occurs across boot. Earlier rewriting supervened after system installing/flashing. So far, we could have avoided this with Lazyflasher or something. At the moment, we install TWRP versions in vain, because after successfully TWRP install, MIUI system immediately restore MiRecovery at rebooting.
In Mi Max 1 I solved the problem of recovering stock recovery by deleting the file "Recovery from boot.p" in the system directory. You must do this before the first start of the system.
Guys, you have system verify in the kernel on Oreo so LazyFlasher doesn't work on Oreo and deleting files in system causes bootloop. The new approach for disabling recovery replace is to patch rc scripts in boot image. That's how this recovery does it.
Edit: BTW vendor is verified as well so modifying anything in that partition causes bootloop as well...
nijel8 said:
Guys, you have system verify in the kernel on Oreo so LazyFlasher doesn't work on Oreo and deleting files in system causes bootloop. The new approach for disabling recovery replace is to patch rc scripts in boot image. That's how this recovery does it.
Edit: BTW vendor is verified as well so modifying anything in that partition causes bootloop as well...
Click to expand...
Click to collapse
"nice" new security items...
Installed the recovery today. It went well. When I tried to boot to the system afterward it started running OpenRecoveryScript 'checking if TWRP will survive system boot!'. It has been over 2 hours. Is this normal? If Any way to stop it? Rebooting doesn't stop it.
EDIT: Figured it out. Didn't have writer permissions for /data. Had to reformat it. After that it went ok.
lowfat said:
Installed the recovery today. It went well. When I tried to boot to the system afterward it started running OpenRecoveryScript 'checking if TWRP will survive system boot!'. It has been over 2 hours. Is this normal? If Any way to stop it? Rebooting doesn't stop it.
EDIT: Figured it out. Didn't have writer permissions for /data. Had to reformat it. After that it went ok.
Click to expand...
Click to collapse
Doesn't sound right. /data should not affect that. Post any recovery related log you find in /cache, please...
Thanks for the recovery mod. I think that a translation into Russian will eventually be added. I am also grateful to nijel8 for his work!

[RECOVERY][Unofficial][amami] TWRP 3.4.0

Finally there is a TWRP capable of decrypting /data on android versions > nougat.
Big thanks @NeoArian
I haven't tested everything in detail as I mostly focused on decryption. If you experience issues or can confirm something working that's not green in the table down below, please share.
Code:
#include <std_disclaimer.h>
/*
* Your warranty is now void.
*
* We are not responsible for bricked devices, dead SD cards,
* thermonuclear war or you getting fired because the alarm app failed. Please
* do some research if you have any concerns about features included in this ROM
* before flashing it! YOU are choosing to make these modifications, and if
* you point the finger at us for messing up your device, we will laugh at you. Hard & a lot.
*
*/
Status
List template by TWRP
Code:
[B]Blocking checks[/B]
- [COLOR="green"]Correct screen/recovery size[/COLOR]
- [COLOR="green"]Working Touch, screen[/COLOR]
- [COLOR="green"]Backup to internal/microSD[/COLOR]
- Restore from internal/microSD
- [COLOR="green"]reboot to system[/COLOR]
- [COLOR="green"]ADB[/COLOR]
[B]Medium checks[/B]
- update.zip sideload
- [COLOR="green"]UI colors (red/blue inversions)[/COLOR]
- [COLOR="green"]Screen goes off (and on :))[/COLOR]
- F2FS/EXT4 Support, exFAT/NTFS where supported
- [COLOR="green"]all important partitions listed in mount/backup lists[/COLOR]
- backup/restore to/from external (USB-OTG) storage
- backup/restore to/from adb
- [COLOR="green"]decrypt /data[/COLOR]
- Correct date
[B]Minor checks[/B]
- MTP export
- [COLOR="green"]reboot to bootloader[/COLOR]
- [COLOR="green"]reboot to recovery[/COLOR]
- [COLOR="green"]poweroff[/COLOR]
- [COLOR="green"]battery level[/COLOR]
- [COLOR="green"]temperature[/COLOR]
- encrypted backups
- [COLOR="green"]input devices via USB (USB-OTG) - keyboard, mouse[/COLOR]
- USB mass storage export
- [COLOR="green"]set brightness[/COLOR]
- [COLOR="green"]vibrate[/COLOR]
- [COLOR="green"]screenshot[/COLOR]
Limitations
Following limitations are known:
none
Click to expand...
Click to collapse
prerequisites
For reboot to recovery from your android system (and OTA updates) your ROM needs the following patches 1, 2 and 3. Following ROM's currently support this:
AICP 14
AICP 15
LineageOS 15
LineageOS 16
LineageOS 17
Click to expand...
Click to collapse
For correct time inside TWRP your ROM needs the following patch. Following ROM's currently support this:
AICP 15
LineageOS 16
LineageOS 17
Click to expand...
Click to collapse
Download
SourceForge
AndroidFileHost
Click to expand...
Click to collapse
How to build
https://github.com/115ek/manifest#build-twrp
Click to expand...
Click to collapse
XDA:DevDB Information
[RECOVERY][Unofficial][amami] TWRP 3.4.0, Tool/Utility for the Sony Xperia Z1 Compact
Contributors
115ek, NeoArian
Source Code: https://github.com/115ek/twrp_device_sony_amami
Version Information
Status: Beta
Created 2019-08-25
Last Updated 2020-08-22
Changelog
15.09.2020 3.4.0-1
again: fix non working OTA update in rare cases (rebooting to recovery and stucking there unable to install update automatically)
22.08.2020 3.4.0-0
latest TWRP changes
29.02.2020 3.3.1-0.4
display sony bootlogo at boot
show version number
remove TWRP app
19.09.2019 3.3.1-0.3
fix non working OTA update (rebooting to recovery and stucking there unable to install update automatically)
05.09.2019 3.3.1-0.2
enable reboot to bootloader (fastboot mode) (you have to connect the phone via usb BEFORE rebooting)
25.08.2019 3.3.1-0.1
decrease size
allow decryption in any case of patchlevel value
25.08.2019 3.3.1-0
initial release
Reserved
Backup to microSD seems to be working fine (haven't restored anything yet):good:
I uploaded a new build 3.3.1-0.1 with decreased size and a "more clean" way to allow /data decryption.
Furthermore I thought about getting this official.
BTW: You won't see the increased version number in TWRP. It's still 3.1.1-0
115ek said:
I uploaded a new build 3.3.1-0.1 with decreased size and a "more clean" way to allow /data decryption.
Furthermore I thought about getting this official.
BTW: You won't see the increased version number in TWRP. It's still 3.1.1-0
Click to expand...
Click to collapse
Hi, thank you for this build. I was waiting to try Pie on my z1 compact and I'm glad I did because the version of TWRP was blocking my use of encryption.
Sadly I didn't have luck installing the latest builds (the ones from 3 days ago and one week ago) on my Z1 Compact. I got this error:
Code:
fastboot: core/libsparse/sparse.cpp:131: int write_all_blocks(struct sparse_file *, struct output_file *): Assertion `pad >= 0' failed.
When trying to flash to recovery partition. The same command worked to flash back to 3.2.3 (not sure if necessary, done just in case). If there's any way you could look into these builds I'd appreciate it!
bananabytes said:
Hi, thank you for this build. I was waiting to try Pie on my z1 compact and I'm glad I did because the version of TWRP was blocking my use of encryption.
Sadly I didn't have luck installing the latest builds (the ones from 3 days ago and one week ago) on my Z1 Compact. I got this error:
Code:
fastboot: core/libsparse/sparse.cpp:131: int write_all_blocks(struct sparse_file *, struct output_file *): Assertion `pad >= 0' failed.
When trying to flash to recovery partition. The same command worked to flash back to 3.2.3 (not sure if necessary, done just in case). If there's any way you could look into these builds I'd appreciate it!
Click to expand...
Click to collapse
What command did you use?
Code:
fastboot flash recovery
or
Code:
fastboot flash FOTAKernel
Do you have the newest bootloader installed? So can you boot directly into recovery with VOL down and power pressed (with 3.2.3 version where flashing was successful)?
Or do you use the method with pressing VOL down when the LED lights up?
EDIT:
By looking at your error code I get the feeling it has something to do with fastboot directly. libsparse is a build dependency of the fastboot binary.
What version of fastboot are you using?
I'm using fastboot installed from the packetmanager with
Code:
apt install fastboot
.
Code:
fastboot --version
gives fastboot version 1:8.1.0+r23-5~18.04.
This would mean 27.0.0 or 27.0.1 according to this scheme. I don't know why they are using different naming schema
However, I'd guess you're using an outdated version (or a very current one - but I don't think so).
115ek said:
What command did you use?.
Click to expand...
Click to collapse
I used fastboot flash recovery, with the newest bootloader. This time I got into recovery by selecting it in my older TWRP because I always get the up/down method mixed up, I have done it before it's just easier that way.
115ek said:
By looking at your error code I get the feeling it has something to do with fastboot directly. libsparse is a build dependency of the fastboot binary.
...
However, I'd guess you're using an outdated version (or a very current one - but I don't think so).
Click to expand...
Click to collapse
I am actually indeed using a very current version, 29.0.2 (so your second less likely guess was correct!) I'm on Manjaro/Arch so we get the bleeding edge updates unlike if you are on a Debian/Ubuntu system that's tied to a lot of different libraries and held back. This is exactly why I stopped using those distros but this is the first time I've had the problem in reverse. I don't know if this is a bug that was introduced into fastboot or what. I do see that the more recent versions have things to do with partitioning. This may be a bug to open with fastboot or to look into further with them? But if it's not a bug with them it would be good to have the build working on the latest fastboot.
bananabytes said:
I used fastboot flash recovery, with the newest bootloader. This time I got into recovery by selecting it in my older TWRP because I always get the up/down method mixed up, I have done it before it's just easier that way.
I am actually indeed using a very current version, 29.0.2 (so your second less likely guess was correct!) I'm on Manjaro/Arch so we get the bleeding edge updates unlike if you are on a Debian/Ubuntu system that's tied to a lot of different libraries and held back. This is exactly why I stopped using those distros but this is the first time I've had the problem in reverse. I don't know if this is a bug that was introduced into fastboot or what. I do see that the more recent versions have things to do with partitioning. This may be a bug to open with fastboot or to look into further with them? But if it's not a bug with them it would be good to have the build working on the latest fastboot.
Click to expand...
Click to collapse
Can you please verify that you also fail with the fastboot binary from here
It's also 29.0.2 and it works fine for me.
I have tried this version with LOS 16 and it worked well. Some things to improve
boot to fastboot is not possible
backup and restore of boot is not possible
good catch with encryption, I have give it up :good:
Micha_Btz said:
boot to fastboot is not possible
Click to expand...
Click to collapse
Well, I actually didn't know this was possible in earlier versions. However it should work now --> see the changelog
You have to connect usb cable before rebooting to bootloader, otherwise it won't work and just reboot the system.
Micha_Btz said:
backup and restore of boot is not possible
Click to expand...
Click to collapse
I can't confirm that. What exactly was the problem for you? Backing up or restoring? Did you got any errors?
Have had a look yesterday, Backup and restore of boot is possible (don't now what happends)
@115ek,
I have a mysterious problem with 3.3.1-0.0.and 3.3.1-0.1:
I used all twrp versions before without problems and now your twrp did not show the correct date (1970-xx-xx) and time (7-8 hours back).
I tried the following several times:
1. reflash your twrp, clear recovery and flash again,
2. flash older versions: date and time was wrong even after reboot
The only way to get the correct date/time back in twrp was (at least for me) flash stock ROM with EMMA and after flashing twrp 3.2.3 my backup.
I do not want to repeat this as this is a lot of work incl. copying back the internal storage.
tramp20 said:
@115ek,
I have a mysterious problem with 3.3.1-0.0.and 3.3.1-0.1:
I used all twrp versions before without problems and now your twrp did not show the correct date (1970-xx-xx) and time (7-8 hours back).
I tried the following several times:
1. reflash your twrp, clear recovery and flash again,
2. flash older versions: date and time was wrong even after reboot
The only way to get the correct date/time back in twrp was (at least for me) flash stock ROM with EMMA and after flashing twrp 3.2.3 my backup.
I do not want to repeat this as this is a lot of work incl. copying back the internal storage.
Click to expand...
Click to collapse
Can you try the latest version?
At first you have to set the right timezone in TWRP settings.
The time is stored in a real time clock (RTC) which runs even if the device is powered off. Setting and reading it's value is done by a kernel driver. If you set the right time in android system it gets stored in the RTC. Then, if you boot into TWRP, the time is read again. And for me this works fine. However it takes some seconds (there's a wrong time at the beginning).
115ek said:
Can you try the latest version?
At first you have to set the right timezone in TWRP settings.
The time is stored in a real time clock (RTC) which runs even if the device is powered off. Setting and reading it's value is done by a kernel driver. If you set the right time in android system it gets stored in the RTC. Then, if you boot into TWRP, the time is read again.
Click to expand...
Click to collapse
Thank you. I know this all, I tried reset to default in TWRP and set TZ etc. but these two mentioned TWRP versions do not read the RTC time (AICP ROM).
All TWRP versions before were ok. I tried this several times.
I noticed this "bug" on my Z1c after a backup with your TWRP (Date from 1970 and a complete false time even after setting the TZ).
Even after flashing one of the older TWRP date/time are wrong (only in TWRP), after booting to Android date/time is correct until I boot to TWRP again.
As I wrote the way back to a correct date/time in TWRP was for me flashing stock ROM with EMMA.
Where is this "kernel driver"? In your TWRP version or in a hidden partition? Sorry I do not know much of these internals.
I assume you did not change in the newest version something regarding this problem.
I have not the time to try the last version for now
Generic question re: encrypting this device
Installed this twrp version and (unlike others) I don't see anything strange. Only thing I haven't tried so far is restoring a nandroid backup I created with this twrp release.
A few days back after I had installed this the first time Itried to encrypt my phone; after a while I received the message that encryption was completed.
Then upon reboot of the device I had to unlock it even before boot sequence had started. Aftter unlocking booting resumed and from then on everything appeared to be as before.
This surprised me a bit because on my other phone (OnePlus6 running stock OOS Pie) I have to unlock after boot sequence has completed. But OK, this may be the LOS 16 way.
Then I devided to unencrypt the phone (this is my secondary device and I only use it for playing around a bit, until I decide to sell it, maybe). Again, from my OP6 I'm used to the fact that if I remove any device locking pattern encryption is gone. But obviously not on my Z1c: after I had removed the security pattern (= set security to nothing) everything appeared to be normal. But after the next reboot all data were gone.
Question: is there a supported way to unencrypt this phone without losing any data?
If there isn't such a way: what happens to my Nandroid backups I took while the phone was encrypted? Are they still usable e.g. after I install a ROM update?
tramp20 said:
Thank you. I know this all, I tried reset to default in TWRP and set TZ etc. but these two mentioned TWRP versions do not read the RTC time (AICP ROM).
All TWRP versions before were ok. I tried this several times.
I noticed this "bug" on my Z1c after a backup with your TWRP (Date from 1970 and a complete false time even after setting the TZ).
Even after flashing one of the older TWRP date/time are wrong (only in TWRP), after booting to Android date/time is correct until I boot to TWRP again.
As I wrote the way back to a correct date/time in TWRP was for me flashing stock ROM with EMMA.
Where is this "kernel driver"? In your TWRP version or in a hidden partition? Sorry I do not know much of these internals.
I assume you did not change in the newest version something regarding this problem.
I have not the time to try the last version for now
Click to expand...
Click to collapse
Flashing stock ROM isn't necessary - I'm 99% sure. Maybe you can get a log with
Code:
adb pull /tmp/recovery.log
while your in TWRP and connected to a PC...
The kernel driver is - as the name says - located in the kernel, which is part of the recovery.img
So everyone flashing this image should have the same functionality (in theory). As it works for me (and some others) I'm just wondering.
lm089 said:
Installed this twrp version and (unlike others) I don't see anything strange. Only thing I haven't tried so far is restoring a nandroid backup I created with this twrp release.
A few days back after I had installed this the first time Itried to encrypt my phone; after a while I received the message that encryption was completed.
Then upon reboot of the device I had to unlock it even before boot sequence had started. Aftter unlocking booting resumed and from then on everything appeared to be as before.
This surprised me a bit because on my other phone (OnePlus6 running stock OOS Pie) I have to unlock after boot sequence has completed. But OK, this may be the LOS 16 way.
Then I devided to unencrypt the phone (this is my secondary device and I only use it for playing around a bit, until I decide to sell it, maybe). Again, from my OP6 I'm used to the fact that if I remove any device locking pattern encryption is gone. But obviously not on my Z1c: after I had removed the security pattern (= set security to nothing) everything appeared to be normal. But after the next reboot all data were gone.
Question: is there a supported way to unencrypt this phone without losing any data?
If there isn't such a way: what happens to my Nandroid backups I took while the phone was encrypted? Are they still usable e.g. after I install a ROM update?
Click to expand...
Click to collapse
The behaviour is totally expected as amami uses the deprecated full disk encryption (FDE). Most likely your oneplus 6 is using file based encryption (FBE). That's the reason it can boot to your lockscreen because some files necessary for booting aren't encrypted (or not encrypted using your password...). To boot a device with fully encrypted /data you have to decrypt it first. If you're interested in details have a look here.
The other thing sounds a bit strange. However I don't know if it's possible to remove the FDE completely. Maybe the device just sets a default password then?
Concerning your question:
What definitely should work is taking a backup in TWRP (of course need to decrypt /data before), then format /data and restore the backup. Anyhow - I didn't test such a case so far.
115ek said:
Flashing stock ROM isn't necessary - I'm 99% sure. Maybe you can get a log with
Code:
adb pull /tmp/recovery.log
while your in TWRP and connected to a PC...
The kernel driver is - as the name says - located in the kernel, which is part of the recovery.img
Click to expand...
Click to collapse
Flashing stock ROM was the only way that all older TWRP could read the correct date again after trying your twrp version.
I will try to get a log if I have enough time.
So the recovery.img = twrp.img or at least a part of it?
Thank you.
New update:
As I had problems with installing OTA updates (especially with /data encrypted, but not limited to) on LineageOS 16.0 I came up with a fix.
Download Currently only on sourceforge - android filehost is buggy at the moment...
19.09.2019 3.3.1-0.3
fix non working OTA update (rebooting to recovery and stucking there unable to install update automatically)
Edit:
As reminder for me / interested guys: This commit breaks the OTA updating in some cases (when mmap isn't sufficient). The buildflag
Code:
-D_FILE_OFFSET_BITS=64
doesn't work as intended on my setup. Maybe I missed something.
tramp20 said:
@115ek,
I used all twrp versions before without problems and now your twrp did not show the correct date (1970-xx-xx) and time (7-8 hours back).
Click to expand...
Click to collapse
Have the same time/date problem with twrp-3.3.1-0.3-amami.img
recovery.log >> https://pastebin.com/rBdHAmz2
Also does not reboot into the recovery from system (AICP 14), just shutdown and then power+volume down works.

[TWRP][JOAN][V30/V30+/V30S][UNOFFICIAL] 3.3.1-2, 2020-2-23, Pie Decryption, for N/O/P

This is the new thread for Pie & 10 TWRP Recovery 3.3.1-x​
Feature list:
- Pie stock ROMs are fully decryptable with this TWRP, either protected with secure startup or without :good: OREO encrypted userdata is not decryptable with 3.3 . However, if you're on encrypted oreo and update to pie stock, either via zip or kdz, crypto gets migrated and you're good to go in terms of access to your encrypted data with 3.3. So, with this recovery, the urgent need for flashing no-verity-opt-encrypt zip isn't really there anymore
- everything working: backup & restore even with encrypted userdata, no matter if it's from oreo or pie. If you restore a backup containing an encrypted userdata, you'll need to format userdata before, for crypto removal. But only when coming from another encrypted ROM, otherwise you can just restore, boot up (it will use the encryption settings you"ve set up) ; decryption; time & dat; mtp; adb; installing of ROMs and zips in general; themeable; .........
- Possibility to leave out lockscreen settings when restoring a backup (sometimes you were forced to delete them manually, otherwise no login into your restored ROM possible -.- You can bypass this with this. Note: lockscreensettings ≠ encryption pin/pw/pattern.)
- Time and date is shown correctly, independent of /data. This should work after a few boots of ROM and TWRP, TWRP needs to get the data once and later on it will then be calculated from persist's settings file.
- modem image support: backup, restore, flashing of modem images either taken directly from kdz or diskdump. Same for OP partition (not present on USA and some others possibly)
- For removing encryption completely you can now do it as already known, via format userdata. Crypto is removed with it now again.
- busybox instead of toolbox/toybox, for better zip compatibility as it looks for now
- Pie 3.3.1-x: compiled with full 9.0 TWRP sources
- capable of installing every ROM and zip files
- some extra partitions (see below)
Don't forget your timezone settings after flashing. Also there are some extra partitions you can mount/backup/flash/explore, like LAF, persist-LG and OP configs. There's the thought of some people to flash TWRP as a second copy to LAF partition to be on the sure side when it comes to ROM switching or sth like that. You can do this, anyway it's not really recommended (by me and some others) because you'll lose download mode, but you now have the option.
For extra partitions: Some of them are needed for decryption (modem / persist-lg (drm)), some are for VoLTE (OP), time is stored on /persist/time (and /data/vendor/time), modem should be known and the LAF partition should be known already too (described above).
For decryption: it works as it should. Therefore it is a little bit tricky to restore a backup of a ROM which had encrypted userdata, when you'd installed any other ROM in between. There are some points to remember when restoring, a little guide is available in old thread's third post (https://forum.xda-developers.com/showpost.php?p=77839649&postcount=3), and some tipps too.
Some instructions:
How to flash?
If starting fresh with an unmodified phone, this thread should help you installing it
When you already have TWRP installed, you can flash this recovery from within TWRP:
- Copy the new image file to one of your phone storages
- Tap "Install"
- Tap "Install image" button, located down right
- Locate your downloaded image and select it
- Select "recovery" from the list which shows up then
- Install; and reboot to recovery after installing immediately, don't use it for any other tasks until rebooted pls, as it may not function. Things can go bollox when phone wasn't rebooted to recovery after installing.
And of course you can flash it via fastbootmode. Reboot to bootloader (adb reboot bootloader; when magisk is installed, you can use magisk manager => module => menu on the top right => reboot to bootloader. You can reboot to recovery from there too) and then:
fastboot flash recovery <twrp-image-name.img>
How to (re)boot to TWRP?:
If your phone is rooted:
- Magisk has options to reboot to different targets like bootloader or recovery, but this menu is a little bit hidden: you can access it by starting Magisk.Manager, going to the "Module" menu, tapping on the three dot menu on the top right. Then select your target
- If a terminal emulator is installed, open it, type "su" followed by enter and type "reboot recovery"
- You can do the same with an adb shell, open a shell and type the commands from above, they're the same
- There also are apps for rebooting to recovery or other targets. Just search around in PlayStore
- The good old "button dance" When phone is powered off, press the volume down key and power button at the same time. When a first sign of life is seen on display, immediately release the power button, but just to instantly press it again. A menu will show, which wants you to do a factory reset: do it You have to confirm this two times, and afterwards TWRP will boot without performing a factory reset. TWRP is compiled with a flag which recognizes this procedure and hinders the bootloader to pass the command for factory resetting.
This time no optional version of TWRP is available, it's "one for all". This TWRP works for every V30 model, and only for them. I removed vendor partition too btw, there isn't any active development about that, so it's useless and only confuses ppl. DataImage function is available.
If you want to use data_image, system_image or internal storage included in data backup, first check your filesystem on your external sdcard. It needs to be capable of writing big files, which isn't the case with fat/fat16/fat32. You need exFAT (for stock) or ext4/ntfs (only available with custom kernel and/or AOSP based builds).
CHANGELOG:
February 23rd, 2020, TWRP 3.3.1-2:
- corrected blocksize for formatting crypto related partitions
- included timezone data, maybe helps some ppl with time still not showing correct; should speed up time calc
- used pre-compiled full mke2fs and e2fsdroid binaries
- enabled ntfs experimental support (rw in kernel, NTFS_3G flag in twrp / ofox)
- minimal tweaks
- enabled F2FS and NTFS support
January 1st, 2020, TWRP 3.3.1-1:
- Formatting problem solved, TWRP now removes crypto as it should when user initiates a data format
- small fixings like checkbox layout in restore menu
- Moved a LOGERR to LOGINFO: "E: Unable to decrypt FBE device". Couldn't get rid of it with our needed config...
Dec. 30th, 2019, TWRP 3.3.1-0:
- initial first version
- almost everything working like in 3.2 oreo TWRP
- Formatting your device doesn't remove crypto from disk, so a "fresh" (formatted) userdata gets disturbed by old security lock
DOWNLOADS:
Nougat, Oreo and Pie capable 3.3.1-0 TWRP, but decrypting support only for PIE (AOSP untested, stock confirmed):
Download links below (always the latest and newest only; one version for all):
File name: TWRP-JOAN-3312_2020-02-23.img
MD5sum: 2fd78a606b65274977f1cd63080d5f23
MAIN Download: MEGA, TWRP-JOAN-3312_2020-02-23.img
As always: Use it at your own risk! You are the one who changes stuff on your phone, I'm not responsible for anything which happens to your phone. TWRP is powerful, be careful at what you do with it :good: And it just works.
All you need to compile this yourself:
[url]https://github.com/seader/android_device_lge_joan-twrp[/url]
[url]https://github.com/minimal-manifest-twrp/platform_manifest_twrp_omni[/url]
[url]https://github.com/seader/android_kernel_lge_msm8998[/url] (not really needed as a prebuilt kernel is used)
[url]https://github.com/seader/bootable_recovery-twrp[/url] (copy of twrp recovery with the stuff added. Pie is "encrypt-9.0" branch. omni's android-9.0 branch almost fully compatible, beside not being able to remove crypto (dirty hack, sry )
Much appreciated for your hard work. Twrp after all is the base for all customization
Thanks!
sure, enjoy it
btw, is there someone with oreo encrypted...? would be nice to know if it's decryptable with this new twrp too, and we therefore only need this one (and the other one can be archived...?)?
which is spoken very early, there's a lot left to do for 3.3 running really flawlessly. but, of course, this will be continued and being further worked on :good: starting right now xD
@ChazzMatt: it will take a while until wtf can be updated with this new one here. this is in an late beta stage, it works but has some quirks left. nothing that can destroy a phone but this twrp isn't fully working at this point of time and therefore not possible to use "in productive threads".
Everything works as well as the previous stable recovery.
I have tried:
1. backing up and restoring ROMs
2. Flashing, ROMs(stock pie and aosp Q), kernels and other mods.
Big thanks ??
In my case time is still not correct, I have to choose a different timezone compared to actual.... When booted up normally, it is correct.
kanehun said:
In my case time is still not correct, I have to choose a different timezone compared to actual.... When booted up normally, it is correct.
Click to expand...
Click to collapse
it needs some boots and reboots to recovery. after setting up everything it showed in twrp as it should :good: i'll add the tzdata back, a registry of all timezones, used for calculation of time, maybe it helps.
Time zone is beyond screwed up, 3 hours off without DST. Also, I'm on Oreo and it's asking for the decrypt password to access internal SD.Going back to 3.2.3-7.
ldeveraux said:
, I'm on Oreo and it's asking for the decrypt password to access internal SD.Going back to 3.2.3-7.
Click to expand...
Click to collapse
Try using the Pie compatible Decryption Disabler and then Reformatting data...
Have you tried flashing the @Zackptg5 Disable_Dm-Verity_ForceEncrypt_08.18.2019 (encryption disabler) before reformatting?
Flash Magisk,
Flash Pie-compatible encryption disabler,
Flash JohnFawkes Root Checker disabler,
Reformat data (where you type yes),
Reboot to recovery from within TWRP,
Flash Magisk AGAIN,
Reboot phone.
See this post: https://forum.xda-developers.com/showpost.php?p=79972563&postcount=107
_____________
7. MORE TWRP ACTIONS - Now turn off data encryption and install essential items… all in TWRP:
(This is not a "menu" in TWRP, it's merely a list of what you NEED to do before booting to the OS)
a. Wipe Data – Factory Reset
b. Install – set storage to the External SD (if you have a microSD card) OR drag necessary files over from PC once in TWRP.
c. Install the Magisk zip. (This is to give the encryption disabler root privileges)
d. Install @Zackptg5 Disable_Dm-Verity_ForceEncrypt_08.18.2019 (encryption disabler).
e. Install @JohnFawkes AnyKernel 3 RCTD Remover (root checker disabler); this disables LG's firmware root checks, which may impede performance.
f. FORMAT DATA (Select WIPE, then FORMAT DATA, then select yes.)
Do NOT delete your OS, but you do need to FORMAT your data , not just "wipe" it this time. Otherwise you may get an encryption error when you boot up the first time. If you get any red mount errors, go back to the TWRP reboot menu and select reboot to recovery and try to FORMAT DATA again. Then, after successfully formatting...
g. Reboot – "Reboot Recovery" from TWRP reboot menu (choose to reboot back to Recovery). Now that the data partition has been formatted, TWRP needs to reload the recovery partition for usage. If you skip this step, when Magisk is installed again below, it may think that /data is still encrypted and set "preserve force encryption". This is also a good sanity check that LG encryption has been removed from /data.
h. Re-flash the Magisk zip again. (This is to make sure, due to Pie changes.)
i. Reboot – to System (NOW you are finally rebooting your phone! Until now this whole section has been done within TWRP.)
ChazzMatt said:
Try using the Pie compatible Decryption Disabler and then Reformatting data...
Have you tried flashing the @Zackptg5 Disable_Dm-Verity_ForceEncrypt_08.18.2019 (encryption disabler) before reformatting?
Flash Magisk,
Flash Pie-compatible encryption disabler,
Flash Root Checker disabler,
reformat data (where you type yes),
reboot to recovery from within TWRP,
flash Magisk AGAIN,
reboot phone.
See this post: https://forum.xda-developers.com/showpost.php?p=79972563&postcount=107
_____________
7. MORE TWRP ACTIONS - Now turn off data encryption and install essential items… all in TWRP:
(This is not a "menu" in TWRP, it's merely a list of what you NEED to do before booting to the OS)
a. Wipe Data – Factory Reset
b. Install – set storage to the External SD (if you have a microSD card) OR drag necessary files over from PC once in TWRP.
c. Install the Magisk zip. (This is to give the encryption disabler root privileges)
d. Install @Zackptg5 Disable_Dm-Verity_ForceEncrypt_08.18.2019 (encryption disabler).
e. Install @JohnFawkes AnyKernel 3 RCTD Remover (root checker disabler); this disables LG's firmware root checks, which may impede performance.
f. FORMAT DATA (Select WIPE, then FORMAT DATA, then select yes.)
Do NOT delete your OS, but you do need to FORMAT your data , not just "wipe" it this time. Otherwise you may get an encryption error when you boot up the first time. If you get any red mount errors, go back to the TWRP reboot menu and select reboot to recovery and try to FORMAT DATA again. Then, after successfully formatting...
g. Reboot – "Reboot Recovery" from TWRP reboot menu (choose to reboot back to Recovery). Now that the data partition has been formatted, TWRP needs to reload the recovery partition for usage. If you skip this step, when Magisk is installed again below, it may think that /data is still encrypted and set "preserve force encryption". This is also a good sanity check that LG encryption has been removed from /data.
h. Re-flash the Magisk zip again. (This is to make sure, due to Pie changes.)
i. Reboot – to System (NOW you are finally rebooting your phone! Until now this whole section has been done within TWRP.)
Click to expand...
Click to collapse
No, that's an insane amount of hassle for no apparent gain! I'm just sticking with the older TWRP [emoji6]
ldeveraux said:
No, that's an insane amount of hassle for no apparent gain! I'm just sticking with the older TWRP [emoji6]
Click to expand...
Click to collapse
Were you already on a decrypted ROM using the older version of TWRP? Trying to figure out if the same encrypted internal storage situation will happen to me if I bother to try this Pie version of TWRP. Just would stick with Oreo TWRP if it's going to be this whole hassle to upgrade.
Thanks!
:victory: thank you seadersn!
ldeveraux said:
No, that's an insane amount of hassle for no apparent gain! I'm just sticking with the older TWRP [emoji6]
Click to expand...
Click to collapse
It's the exact steps people have to do when installing TWRP to work with bootloader unlocked Pie KDZ.
We needed new Encryption Disabler and we needed new Root Checker Disabler and we needed to flash Magisk twice.
The order of steps had to be rewritten besides new files.
Those have been in effect ever since EU H930 got Pie. Works on Oreo AND Pie bootloader unlocked KDZ.
drewcu said:
Were you already on a decrypted ROM using the older version of TWRP? Trying to figure out if the same encrypted internal storage situation will happen to me if I bother to try this Pie version of TWRP. Just would stick with Oreo TWRP if it's going to be this whole hassle to upgrade.
Thanks!
Click to expand...
Click to collapse
I'm on the TWRP flashable US99820H, so no clue
ChazzMatt said:
It's the exact steps people have to do when installing TWRP to work with bootloader unlocked Pie KDZ.
Those have been in effect ever since EU H930 got Pie.
Click to expand...
Click to collapse
I guess. I don't have Pie and don't plan on updating soon. I don't even know what the decryption password was all about. My TWRP was working fine, I've learned one thing with Android: if it ain't broke...
ldeveraux said:
I'm on the TWRP flashable US99820H, so no clue
I guess. I don't have Pie and don't plan on updating soon. I don't even know what the decryption password was all about. My TWRP was working fine, I've learned one thing with Android: if it ain't broke...
Click to expand...
Click to collapse
Any TWRP flashable ROM was likely decrypted and is similar to my situation (except I'm on Pie VS99630c). Sounds like upgrading to TWRP 3.3.1 Pie is more hassle than it's worth and I'll stay put.
Thanks.
ldeveraux said:
I'm on the TWRP flashable US99820H, so no clue
I guess. I don't have Pie and don't plan on updating soon. I don't even know what the decryption password was all about. My TWRP was working fine, I've learned one thing with Android: if it ain't broke...
Click to expand...
Click to collapse
Sure. I'm still on stock rooted Oreo firmware, also.
But those two new files, different order of steps work with both Oreo AND Pie Bootloader Unlocked KDZ with 3 2.3.7 -- whereas the older method and (with original decryption and root check disabler files) were in place before Pie.
WTF has always had decryption and root check disabler files and reformat of data to install TWRP.
What's different now is newer files to be effective on Pie KDZ as well as different order of steps -- as well as flashing Magisk at the beginning and again at the end.
I am hoping those files and steps also work with this new TWRP 3.3.1.
---------- Post added at 05:54 PM ---------- Previous post was at 05:51 PM ----------
drewcu said:
Any TWRP flashable ROM was likely decrypted and is similar to my situation (except I'm on Pie VS99630c). Sounds like upgrading to TWRP 3.3.1 Pie is more hassle than it's worth and I'll stay put.
Thanks.
Click to expand...
Click to collapse
Those files and steps I posted work with all Pie KDZ on 3.2.3.7. If they don't work on this 3.3.1 that's strange.
ChazzMatt said:
Sure. I'm still on stock rooted Oreo firmware, also.
But those two new files, different order of steps work with both Oreo AND Pie Bootloader Unlocked KDZ with 3 2.3.7 -- whereas the older method and (with original decryption and root check disabler files) were in place before Pie.
WTF has always had decryption and root check disabler files and reformat of data to install TWRP.
What's different now is newer files to be effective on Pie KDZ as well as different order of steps -- as well as flashing Magisk at the beginning and again at the end.
I am hoping those files and steps also work with this new TWRP 3.3.1.
---------- Post added at 05:54 PM ---------- Previous post was at 05:51 PM ----------
Those files and steps I posted work with all Pie KDZ on 3.2.3.7. If they don't work on this 3.3.1 that's strange.
Click to expand...
Click to collapse
I am on John Fawkes' Pie VS99630c TWRP flashable ZIP using TWRP 3.2.3.7. The concern is whether upgrading TWRP to 3.3.1 is as simple is flashing the IMG file within TWRP 3.2.3.7, or whether we'll have to reflash multiple things in a whole list of steps. If it's the latter, then why not just stay on TWRP 3.2.3.7 which seems to do everything we need in terms of flashing Pie ROMs?
ChazzMatt said:
Those files and steps I posted work with all Pie KDZ on 3.2.3.7. If they don't work on this 3.3.1 that's strange.
Click to expand...
Click to collapse
it's only formatting data switched to "fastboot -w" (reformats cache and data) or "fastboot erase userdata" (reformats data). both remove eventually present encryptions. everything else works like in the default wtf recovery :good: and that's really an enerving point... i want to simply format my userdata in twrp and not have to switch to fastboot...
formatting now works :good:
drewcu said:
I am on John Fawkes' Pie VS99630c TWRP flashable ZIP using TWRP 3.2.3.7. The concern is whether upgrading TWRP to 3.3.1 is as simple is flashing the IMG file within TWRP 3.2.3.7, or whether we'll have to reflash multiple things in a whole list of steps. If it's the latter, then why not just stay on TWRP 3.2.3.7 which seems to do everything we need in terms of flashing Pie ROMs?
Click to expand...
Click to collapse
it's the first: flashing image easily. only thing is, as described above, removing encryption requires fastboot. atm not possible to do this in recovery as usual. therefore nod suitable for wtf thread, but for anybody else, especially the ones who have pie installed and want to acces their data in twrp when encrypted. i'll test oreo decryption compatibility soon, zip needs downloading time lol
oreo decryption compatibility not given with 3.3 but: you can easily migrate from encrypted oreo via fw zip to pie, it adopts the storage encryption then and 3.3 is able to unlock :good: i've got a solution for 3.3 not being able to remove encryption: i keep a copyof 3.2.3-7 image on external sd and install it when formatting needed xD then back to 3.3 and good to go.
workaround no more needed, working now

[RECOVERY][OFFICIAL] TWRP for ASUS ZenFone 7 Series

Code:
*** Disclaimer ***
All flashing is done at your own risk!
While nothing from this thread should break your device,
don't come back here blaming anyone if it does!
Introduction
Team Win Recovery Project 3.x, or twrp3 for short, is a custom recovery built with ease of use and customization in mind. Its a fully touch driven user interface no more volume rocker or power buttons to mash. The GUI is also fully XML driven and completely theme-able. You can change just about every aspect of the look and feel!
Click to expand...
Click to collapse
Images
Prerequisites
Unlocked Bootloader
Click to expand...
Click to collapse
Installation instructions
Fastboot Install Method:
You will need the platform-tools from the Android SDK on your computer. Find the Android command line tools section on the page linked and install the SDK tools package. From the SDK Manager, download only the platform-tools to get adb and fastboot binaries.
Windows users will need proper drivers installed on their computer. You can try the Naked ADB drivers or the Universal ADB drivers if you don't already have a working driver installed
On your device, go into Settings -> About and find the Build Number and tap on it 7 times to enable developer settings. Press back and go into Developer Options and enable USB debugging. From your computer, open a command prompt and type:
Code:
adb reboot bootloader
You should now be in fastboot mode.
Download the correct image file and copy the file into the same folder as your adb and fastboot binaries. Rename the image to twrp.img and type:
Code:
fastboot flash recovery_a twrp.img
fastboot flash recovery_b twrp.img
Code:
fastboot reboot
Alternate Installation Method (requires prior TWRP installation):
TWRP Image Install method:
Most devices can be updated quickly and easily within TWRP if you already have version 2.8.4.0 or higher installed. NOTE: This will only flash TWRP to the active slot!
Download the latest version of TWRP appropriate for your device/firmware
Reboot to TWRP
Hit Install and tap the "Install Image" button in the lower right
Browse to the location of the TWRP image on your device and select it
Select recovery from the partition list and swipe to flash
Click to expand...
Click to collapse
Device Changelog
Current version: 3.6.0_11-0:
Initial version
Click to expand...
Click to collapse
Older Device-specific versions:
N/A
Click to expand...
Click to collapse
Click to expand...
Click to collapse
TWRP Official Change Log
Frequently Asked Questions (FAQ)
Downloads
Download
Latest Official versions
Sources
TWRP
Device tree
Common tree
Kernel source
Click to expand...
Click to collapse
Known Issues
Device-specific
N/A
TWRP Upstream
N/A
Click to expand...
Click to collapse
Bug Reporting
If you have an issue, the first step is to post a recovery log so we can determine the cause of the issue. This is done in recovery using Advanced -> Copy Log, or adb pull /tmp/recovery.log. Once a log is uploaded we can determine how best to proceed. NOTE: Posts that are reporting bugs or issues without an accompanying recovery log will be ignored! Additionally, providing details about your device setup, including variant, firmware version, and exact steps to reproduce your issue will also be helpful in diagnosing the problem.
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
If your issue is determined to be a bug, please consider posting it to our github issues log. It's pretty much impossible for us to keep up with the more than 40 threads that we have for the devices that we "directly" support. If you have a significant problem that cannot be answered in this thread, your best bet is to contact us via our website. If you see someone that's struggling, feel free to point it out to us. We need your help to help us keep track of all of our devices! Thanks!
Click to expand...
Click to collapse
Additional Help/Support
Live support is available on Zulip.
Click to expand...
Click to collapse
Frequently Asked Questions (FAQ):
How do I install an OTA while rooted and keep TWRP/root?
Full Firmware zip - in Android
Prerequisites:
Full Firmware zip for new software
TWRP installed to the current slot
Magisk Manager
Steps:
Put Full Firmware zip on root of internal storage
Reboot the device so that the update is detected
Install the update
After install completes BUT BEFORE REBOOTING, install "TWRP A/B Retention Script" module by @osm0sis in Magisk Manager
Install Magisk "to Inactive Slot (After OTA)" in Magisk Manager
Reboot and you're updated with TWRP and root retained
Full Firmware zip - Through TWRP
Prerequisites:
Full Firmware zip for new software
TWRP_Flash_tpposite_Slot-CPTBv2.zip
Magisk zip (optional)
Steps:
Reboot into TWRP
Navigate to Full Firmware zip and install, or sideload zip over adb
Flash TWRP_Flash_tpposite_Slot-CPTBv2.zip to retain TWRP.
(Optional) Reboot into TWRP and flash Magisk for root.
Incremental OTA package - Through TWRP ONLY
Prerequisites:
Current software stock boot.img
Current software stock recovery.img
Current software stock dtbo.img (only if modified by Magisk or custom ROM)
Incremental OTA zip for current software to new software
TWRP_Flash_tpposite_Slot-CPTBv2.zip
Magisk zip (optional)
Steps:
Ensure you have the latest version of TWRP installed. If you don't, follow the instructions in the OP to flash it.
Boot into TWRP.
Use the "Install Image" feature to flash the stock boot and recovery (and dtbo) images.
Flash the incremental OTA zip.
Flash TWRP_Flash_tpposite_Slot-CPTBv2.zip to retain TWRP.
(Optional) Reboot into TWRP and flash Magisk for root.
The key here is making sure the current slot is fully stock (including boot and recovery images) in order for the incremental OTA zip to install successfully.
What's the deal with these dynamic partitions?
Here's Google's explanation.
Why can't I write to system?
Dynamic partitions (see link above). See @topjohnwu's detailed explanation here.
How do I make modifications to system?
On the stock ROM, you don't. However, you can modify system "systemlessly" with Magisk.
Can I boot the recovery image without flashing it?
No. Fastboot boot isn't possible on this device, but since there's a separate recovery partition (two in fact), and ASUS provides full stock firmware, this isn't a big concern.
What is fastbootd?
Here's Google's explanation.
Can I back up the system/vendor partition separately?
No. Because dynamic partitions. The Super partition is backed up and restored in its entirety. If you need to flash the individual images, use fastbootd.
Why can't I restore X partition (read-only error)?
Some of the partitions that can be backed up in TWRP include sensitive device data which, if corrupted, backed up, and then restored, can irreparably damage the device. Therefore, while these partitions can be backed up in TWRP, only experienced users should restore them, which can be done manually via the dd command.
(I will not provide any additional details on this procedure)
Click to expand...
Click to collapse
Reserved
Big thanks to @Buffydamion for all his tireless testing and log-providing to get this TWRP in fully working order!!
Hopefully there aren't any bugs besides the upstream ones listed in the OP, but if there are, I'll do my best to figure them out.
Since I don't have the device, I'll have to rely on all of you for logs and feedback.
Enjoy!!
--Cap
How did you make it boot on this android 10 device? Official TWRP doesn't support android 10. Dees_Troy is still working on the solution.
Volski_ said:
How did you make it boot on this android 10 device? Official TWRP doesn't support android 10. Dees_Troy is still working on the solution.
Click to expand...
Click to collapse
@Dees_Troy isn't the only person on the TWRP team.
@bigbiff has been working tirelessly to add Android 10 support to TWRP, with help from @mauronofrio, @androiabledroid, myself and others. TWRP is open-source and a team effort. As you'll notice, there are still some upstream bugs that need to be fixed, which is why the official TWRP hasn't been updated yet. But it's working well enough to release it for devices that need it, and when the official TWRP is ready, these devices will have official support.
Works fine for me. Thanks!
The data partition was already partitioned to f2fs.
Flashed magisk and have a rooted phone now. Perfect!
Update - new 20200920 build with stock kernel with f2fs support thanks to a proper fix from @aleasto.
I've also unified the dtb & dtbo with the ROG3 build, so this one needs testing to confirm it's booting for everyone. Please report back here once you have a chance to update.
--Cap
Captain_Throwback said:
Update - new 20200920 build with stock kernel with f2fs support thanks to a proper fix from @aleasto.
I've also unified the dtb & dtbo with the ROG3 build, so this one needs testing to confirm it's booting for everyone. Please report back here once you have a chance to update.
--Cap
Click to expand...
Click to collapse
So I had to remove the above build as it didn't boot. Building a new one now and hopefully it'll work. I'll keep everyone posted.
New release 20200922-14
There's a new release available today, which I recommend everyone switch to at their earliest convenience. I've also added a zip attachment to the first post that will allow you to flash a TWRP installed to your current slot to the opposite/inactive slot after an OTA is installed, so that you keep TWRP (otherwise it gets replaced by the OTA/firmware zip). The zip can be flashed either in Magisk Manager after the OTA completes installing (but BEFORE rebooting) or in TWRP after manually flashing a full firmware update zip (but PRIOR to rebooting). The zip simply duplicates the recovery from the existing recovery partition to the opposite slot, so it will only work if TWRP is currently installed to the active slot.
Change Log:
Update prebuilt kernel to source built with @aleasto's patch for f2fs
Set data filesystem to f2fs in recovery fstab
Add TWRP flags to disable screen blank to ensure touchscreen gets initialized on boot and screen wake works
Hi guys, i tried on mine and worked smoothly...the only thing I still cant do is writing in system folder...I tried multiple app as Root explorer but still can't manage to write anything even with root permission...
Any thoughts?
luiscaproducer said:
Hi guys, i tried on mine and worked smoothly...the only thing I still cant do is writing in system folder...I tried multiple app as Root explorer but still can't manage to write anything even with root permission...
Any thoughts?
Click to expand...
Click to collapse
That is normal for dynamic partitions. The full super partition can be written but not the individual block devices.
Thanks Captain! So basically I will have to wait for the official release of the TWRP? Or it will just never happen to have a super partition...Excuse the ignorance
luiscaproducer said:
Thanks Captain! So basically I will have to wait for the official release of the TWRP? Or it will just never happen to have a super partition...Excuse the ignorance
Click to expand...
Click to collapse
That is unrelated to TWRP being official or not, lol.
TWRP upstream will soon be updated to allow read/write of the system partition, but keep in mind that verity will need to be disabled for you to change any of the content, unless you don't want your device to boot .
--Cap
P.S. If you need to make modifications to system, you should use Magisk - it's made for this exact situation.
Captain_Throwback said:
There's a new release available today, which I recommend everyone switch to at their earliest convenience. I've also added a zip attachment to the first post that will allow you to flash a TWRP installed to your current slot to the opposite/inactive slot after an OTA is installed, so that you keep TWRP (otherwise it gets replaced by the OTA/firmware zip). The zip can be flashed either in Magisk Manager after the OTA completes installing (but BEFORE rebooting) or in TWRP after manually flashing a full firmware update zip (but PRIOR to rebooting). The zip simply duplicates the recovery from the existing recovery partition to the opposite slot, so it will only work if TWRP is currently installed to the active slot.
Change Log:
Set data filesystem to f2fs in recovery fstab
Add TWRP flags to disable screen blank to ensure touchscreen gets initialized on boot and screen wake works
Click to expand...
Click to collapse
Works perfect for me. Thank you
Update 20201001-02
Changelog:
- Add support for installing incremental OTAs (requires flashing/restoring stock boot and recovery images while in TWRP)
- Add all relevant partitions to dynamic partition list and improve display of Super partition in Backup screen
- Add asusfw, EFS, Modem, & Persist partitions as backup options (USE WITH CAUTION!!)
Captain_Throwback said:
Changelog:
- Add support for installing incremental OTAs (requires flashing/restoring stock boot and recovery images while in TWRP)
- Add all relevant partitions to dynamic partition list and improve display of Super partition in Backup screen
- Add asusfw, EFS, Modem, & Persist partitions as backup options (USE WITH CAUTION!!)
Click to expand...
Click to collapse
------------------------------------------------------------------------------------------------------------------------
Hi,
I would like to install TWRP. if I understood correctly you have to do this:
1. Unlock Bootloader
2. Install TWRP on both partitions.
3. Install TWRP_Flash_tpposite_Slot-CPTB.zip
4. Install Magisk.
Is it right?
And the correct procedure to update OTA? can you remove magisk and module before?
Thank you for your answers.
[email protected] said:
------------------------------------------------------------------------------------------------------------------------
Hi,
I would like to install TWRP. if I understood correctly you have to do this:
1. Unlock Bootloader
2. Install TWRP on both partitions.
3. Install TWRP_Flash_tpposite_Slot-CPTB.zip
4. Install Magisk.
Is it right?
And the correct procedure to update OTA? can you remove magisk and module before?
Thank you for your answers.
Click to expand...
Click to collapse
You don't need #3, as you're flashing TWRP to both slots in #2. That zip is for keeping TWRP after flashing a full firmware zip.
To update with an incremental OTA, you have to have the stock boot and recovery images from the current firmware available to be flashed in TWRP. You have to boot to TWRP and flash both stock boot and recovery, and then you can flash the incremental OTA. Then reboot to bootloader and flash TWRP, then reboot to recovery and flash Magisk for root.
Great and thanks Captain T.
Just a clarification, if i flash a full OTA (not incremental OTA) i don't need flash the stock boot, right?
[email protected] said:
Great and thanks Captain T.
Just a clarification, if i flash a full OTA (not incremental OTA) i don't need flash the stock boot, right?
Click to expand...
Click to collapse
Correct.
And then you need to flash the zip that flashes TWRP to the opposite slot so you keep TWRP once you reboot. You'll have to reboot back into TWRP and flash Magisk if you want to keep root.

Categories

Resources