Lineage-16.0 (Android Pie) Beta

Hi, hope this helps:

  1. if a encryption is method is really old (low key size), it does not cost so much time/cpu-power to “brute-force” it -> so maybe a new encryption after several android version is useful
  2. it is also to install it from scratch again, so the keys does not matter ->this works since my install at tuesday really well

(except some apps AntennaPod import issue is already closed but not released, SilenceIM import but the development seens to be dead)
It look like IPv6 support becomes a little bit worse again (with clat in wifi) - but thats i am still testing, and does not matter for “usually” users.

To clarify: Encryption in LineageOS 16.0 works.

The problem: TWRP as of 3.2.3-0 can not decrypt encrypted data which was encrypted with Android 8 or (now) 9. TWRP would have to catch up here, but this seems to be extremely tricky for developers.
TWRP being able to decrypt is desirable, because TWRP has a really neat backup feature, which loses much of its charme when the data partition (the only thing that really gets encrypted) is missing in the backup.

Workaround for LineageOS 15.1: 15.1. could be installed and ran totally fine with encryption already in place from a former Android (e.g. LineageOS 14.1 = Android 7). So TWRP was happy with that, too.

Workaround for LineageOS 16.0: There’s the problem now. 16.0 seemingly doesn’t behave like 15.1. with the old encryption already in place and doesn’t even boot.

3 Likes

Thanks for the info that encryption work in principle.
But as you also mentioned it, I like TWRP’s backup/restore functionality, and I don’t want to miss it.

This is exaxtly the problem! I need a backup and if it does not even boot it is for me useless.
I understood that I can encrypt 16.1. but not backup data via TWRP because TWRP does not decrypt.
What can we do?

  1. Run encrypted phone with 16.1 but without TWRP backup ?
  2. Look for another good backup method. I do not know one. Platinum backup needs rooted phone. Basically I do not want to root, but does Platinum work with encrypted 16.1.?
  3. Any other suggestions?

Keep using official 15.1 until currently unofficial 16.0 becomes official, and hope for some workaround until then?

It’s still testing stage … we’ve been there before :wink: .

6 Likes

Has anyone tried out Netguard? It doesn’t work with Lineage 15.1. (Thread: Netguard blocks all traffic. I’m not brave and clever enough to try out an unofficial version. But I really hope it works again with Lineage 16.0.

Hello !
I installed the upgrade and it works, thank you chris!
Didn’t migrate the keys, though, but it works anyway (*).
What I had to do is to reinstall the openGapps pico for android 9, before doing that google play services was crashing continuously…

(*) EDIT: I desactivated “signature verification” in Parameters > Security and localisation > Trust

Tried it some time ago and it worked with Lineage 15.1 . Download was via F-Droid (now again available there). I tried the free version which is in my opinion fully sufficient. Upgrade is - as far as I remember - possible via a donation to the developer.
It was a test only for me because it is not really necessary with Lineage and I deleted it some time later. How to do installation and adjustments please read info from Mike Kuketz

Yes, you need to install via recovery a new version of gapps when upgrading to a new major release.

You should also migrate keys, as apparently you lose system app settings.

Chris

1 Like

I would like to test this coming from FPOOS. Can I just wipe and flash in TWRP (as per usual)?

If you have a backup of everything you consider important, and if your phone is not encrypted, then yes.

If your phone is encrypted, you will have to remove encryption with Format Data in TWRP before installing 16.0 (currently), else it will not boot (currently). You can encrypt in 16.0 after it is installed, but TWRP can’t handle this 16.0-encrypted data partition then (currently, but TWRP will work with the other partitions, so e.g. updates should work).

1 Like

Heyho,

many thanks to @chrmhoffmann and @z3ntu!!!
After I finally understood howto change the keys, I updated today.
It worked like charm! All system settings have been kept. Except the homescreen (widgets and nearly all icons lost; wallpaper stayed the same) and the preferred SIM card for calls .

A first Bug I’ve found: After setting the display size and tabbing the button “recent items” the screen just shows the wallpaper and I’ve to reboot the phone.

For all who want to change the keys. This is what I did:

adb root 
adb shell stop
adb push ./migration.sh /data/local/tmp/migration.sh
adb shell chmod +x /data/local/tmp/migration.sh
adb shell sh /data/local/tmp/migration.sh unofficial
adb reboot recovery
# Now install the LineageOS install zip

The file migration.sh can be found here: migration.sh

14 Likes

Just tried to run the migration script as described above.
I get these error messages:
C:\Program Files (x86)\Minimal ADB and Fastboot>adb push c:/temp/migration.sh /data/local/tmp/migration.sh
[100%] /data/local/tmp/migration.sh

C:\Program Files (x86)\Minimal ADB and Fastboot>adb shell chmod +x /data/local/tmp/migration.sh

C:\Program Files (x86)\Minimal ADB and Fastboot>adb shell sh /data/local/tmp/migration.sh unofficial
: not found/tmp/migration.sh: line 2:
: not found/tmp/migration.sh: line 12:
: not found/tmp/migration.sh: line 22:
: not found/tmp/migration.sh: line 23:
: not found/tmp/migration.sh: line 26:
/data/local/tmp/migration.sh: line 27: syntax error: unexpected word (expecting “in”)

What I did wrong?

Solved the issue, replaced Windows line end with line ends in Unix format.
Tried the first installation with my encrypted mobile, but restart failed, it was mentioned that corrupt data partition can’t be opend, please reset your phone.
I’m now recovering latest backup, continue tomorrow.

2 Likes

Maybe this problem wouldn’t exist if you downloaded the script via git or repo. But I don’t understand git enough to extract the URL. So I downloaded 66 GB of data just for this little script. :wink:

Since I’ve been using Unix for decades, how exactly did you replace the line ends?

Maybe this problem could be avoided by downloading the script directly to the phone.

I followed the instruction / advice from here:

"In Notepad++, use replace all with regular expression. This has advantage over conversion command in menu that you can operate on entire folder w/o having to open each file or drag n drop (on several hundred files it will noticeably become slower) plus you can also set filename wildcard filter.

From
(\r?\n)|(\r\n?)
to
\n
This will match every possible line ending pattern (single \r, \n or \r\n) back to \n.

This I’ll try next time

Notepad++ has a built-in function to convert between Unix/Linux, Windows and Mac style line-endings.

Simply (right?) click on the current ending mode (“Windows (CR LF)” in the screenshot below) to change it.

3 Likes

dos2unix/unix2dos or sed [1] would also work.

[1] sed ':a;N;$!ba;s/\n//g' input_file > output_file

1 Like

For a more permanent solution when using git on Windows, look here: https://help.github.com/en/articles/dealing-with-line-endings

Depending on the tool with which you installed git, it may default to transforming LF to CRLF on Windows. When your sources are primarily targeted for Windows platform, that’s the right choice. For Unix, Java, Python, XML, HTML, Javascript etc, you will probably want to use LF anyway.

… and if you got the script from github using zip, that means the developer commited a Unix script with alien EOLs :slight_smile:

1 Like

Just did a fresh install with complete wipe on my device for testing. I flashed the following extra packages

  • opengapps pico
  • addonsu
  • fdroid priviledge extensions

Also installed my most relevant apps and am now in the process of setting everything up. Will report later what works (and maybe what doesn’t).

Took me some time to find how to enable the new Android 9 navigation bar. In the German settings it’s under “System > Erweitert > Bewegungen” and then enable “Auf Startbildschirmtaste nach oben wischen”. I think in English it’s called “Gestures” in the settings. Should have been translated to “Gesten”…

2 Likes