English

LOS update problem via TWRP

Thanks for this. I got this now, too, while playing around with my encryption, and as though by chance …

My personal speculation …

To never show this Keep Read Only screen again, TWRP would have to store this choice somewhere (probably along with its settings).
It seems it can’t do this when data is still encrypted, so it doesn’t present the choice in this case.

Normally though, TWRP would ask for the decryption password first thing before everything else, but now the current TWRP 3.2.2-0 comes into play, which introduced

“OTA style update zips will now install automatically without prompting for decrypt”

So TWRP 3.2.2-0 seems to recognize it should install an update, and it doesn’t need to prompt for the decryption password in this case because those updates don’t do anything to the data partition … but that leaves data encrypted and so TWRP 3.2.2-0 doesn’t know its settings and starts from scratch with the Keep Read Only screen as well as doesn’t present the choice to never show this screen again.

If that’s how it is, then TWRP 3.2.1-0, prompting for decryption everytime, should work.
If not … don’t mind me and carry on … lalala (off playing around more, causing more mischief and mayhem) :innocent:

3 Likes

@AnotherElk Can you summarize quickly:
What works or doesn’t work on what version of TWRP?

From the Lineage thread I’ve taken that TWRP 3.2.2-0 has problems with LineageOS 15.1 encryption.

LineageOS 15.1 encryption:
TWRP 3.2.2-0 and TWRP 3.2.1-0 detect there is encryption, but fail to decrypt even with the correct password, or with a default password (?) if Screen Lock was set to “None” before encrypting.

Automatically installing updates from the LineageOS 14.1 Updater:
TWRP 3.2.2-0 doesn’t ask for the decryption password anymore when just installing OTA updates, now instead presenting the initial “Keep Read Only” prompt first, afterwards not doing the intended automatic install regardless of the user’s choice in this screen.
TWRP 3.2.1-0 worked in this case before, and still should (just needs confirmation now).

1 Like

So everything basically still works on 14.1 except that this prompt is annoying? Now I understood the message. Will report upstream.
EDIT: Use https://paste.omnirom.org/ and upload /tmp/recovery.log and the output of dmesg - the issue template wants this :slight_smile:

For 15.1 the problem is reported in https://github.com/omnirom/android_bootable_recovery/issues/224 - can you check if the log listed in the issue is the same as on the device in /tmp/recovery.log?

For the 14.1 stuff I can do the logs when I’m back on 14.1.
As for 15.1 …

The few lines listed there under ADDITIONAL INFORMATION are not the recovery.log, but the TWRP console (?) output you can view with the button at the bottom right.

For Screen Lock in LineageOS 15.1 set to “None” it reads:

Failed to decrypt data.
Unable to decrypt with default password. You may need to perform a Format Data.
Updating partition details...
...done
Unable to mount storage
Full SELinux support is present.

At this point TWRP prompts for a decryption password, but there is none. Every attempt to enter one adds the following line to the output:

Failed to decrypt data.

For Screen Lock set to an actual lock (pattern/ PIN/ password) it reads

Updating partition details...
...done
Unable to mount storage
Full SELinux support is present.

At this point TWRP prompts for the decryption pattern/ password (TWRP doesn’t distinguish between PIN and password with this prompt, worked with PINs nonetheless in the past).
Every attempt to decrypt with the pattern/ PIN/ password given by the user adds the following line to the output:

Failed to decrypt data.

recovery.log for Screen Lock set to “None” … Edit: is on GitHub.

recovery.log for Screen Lock set to an actual lock … Edit: is on GitHub.

Sorry, I can’t really help there… Maybe put it into the issue I linked above…

Have done so.

TWRP 3.2.2-0 recovery.log: https://paste.omnirom.org/view/d0991ad4

TWRP 3.2.2-0 dmesg.log: https://paste.omnirom.org/view/e2fd6fc4

And I can confirm: TWRP 3.2.1-0 works for the LineageOS 14.1 Updater and encrypted data.
(Yay, I used the Updater for the first time :slight_smile: .)

1 Like

Filed an issue: https://github.com/omnirom/android_bootable_recovery/issues/229

2 Likes

I noticed TWRP 3.2.1-0 also doesn’t automatically install OTA updates if it has to present the “Keep Read Only” prompt first.
So this prompt seems to break the OTA installation, encrypted data “only” triggers the prompt.

Please add your comments to the issue if they are of interest to it. I won’t copy-paste them there :wink:

I copy-pasted them here :slight_smile: .

As far as I get it, the solution to the Problem here is either

  1. Go back to TWRP 3.2.1
    or
  2. Install updates manually?

Am I right?

1 Like

I’m on the same page.

Yes.
And if you want to have the automatic install feature working, boot into TWRP 3.2.1-0 after installing it and enable “Never show this screen during boot again” at the Keep Read Only prompt.

1 Like

Back to TWRP 3.2.1. Since I didn’t have any problems with that version I’m fine with it.

1 Like

After updating to the lastest LOS version, I can confirm that the problem must be included in the last update. With TWRP 3.2.1-0 the update went like a charm.

1 Like

TWRP 3.2.3 is released:
https://twrp.me/site/update/2018/08/06/twrp-3.2.3-0-released.html

  • Fix automatic installing of OTA zips on encrypted devices
  • Remove SuperSU from TWRP
  • Support both md5 and md5sum file extensions when doing MD5 checking for zip files
5 Likes

I’m not sure if it belongs in this topic, but I have the problem that I can’t enter anymore the recovery mode.

Last week I did the upgrade to LOS 15.1 and wanted to update to this weeks update of LOS today, but couldn’t install anything because it seems like I can’t enter TWRP anymore? Afterwards the failed update, my FP2 simply rebooted instead of enter the recovery mode, so I tried to reboot into recovery without the LOS updater app, but even this didn’t work.

So I’m not sure what is wrong? Do I need to reflash TWRP or did I brick something?
In LOS everything seems to work, at least I didn’t imagine anything wrong.

before the update to 15.1 I installed the latest version of TWRP.

@Roboe, @z3ntu, @AnotherElk: any ideas?

Please confirm … if you press Vol + all the way through rebooting (from the moment the screen goes blank to the moment TWRP appears) … this doesn’t work?

If in doubt, you can do this anytime.

Well, there’s always booting TWRP without flashing it …

2 Likes