[RECOVERY][EXYNOS] TWRP 3.4.0-0 for S10e|S10|S10+ (UPDATE: 2020-06-12)

JohnDandel

Member
Apr 15, 2020
16
0
0
@modpunk I built this TWRP based on you recommendations. I was able to build it successfully. I created a tar file with the recovery image and your vbmeta image. When I try to flash it on using ODIN. When the phone restarts it goes back to download mode with this message. Any idea what it means? Thanks

BIN MODE (DT Load Fail)
[OTH] dt table header check Fail: <unknown error>
Load_Kernel: Could not do Normal boot (DT LOAD Fail)
vbmeta: Error verifying vbmeta image: OK_NOT_SIGNED (3)
CUSTOM VBMETA
VBMETA : No sign info
VBMETA .
 

modpunk

Recognized Contributor
Oct 14, 2011
1,699
6,465
143
@modpunk I built this TWRP based on you recommendations. I was able to build it successfully. I created a tar file with the recovery image and your vbmeta image. When I try to flash it on using ODIN. When the phone restarts it goes back to download mode with this message. Any idea what it means? Thanks

BIN MODE (DT Load Fail)
[OTH] dt table header check Fail: <unknown error>
Load_Kernel: Could not do Normal boot (DT LOAD Fail)
vbmeta: Error verifying vbmeta image: OK_NOT_SIGNED (3)
CUSTOM VBMETA
VBMETA : No sign info
VBMETA .
Did you also falsh a vbmeta-disabled?
 

JohnDandel

Member
Apr 15, 2020
16
0
0
Building What a Wurst! TWRP

Did you also falsh a vbmeta-disabled?
I verified that vbmeta-disabled.img has the same MD5 hash.
I renamed vbmeta-disabled.img to vbmeta.img and I TAR'd that and recovery.img into TWRP.tar file. (So TWRP.tar only has two files vbmeta.img and recovery.img). I used ODIN to flash TWRP.tar. After restating the phone it boots back to Download mode. Unfortunately I get the same error message displayed on the Download Mode screen

Error verifying vbmeta image OK_NOT_SIGNED (3)

I also tried flashing the original TWRP to the phone, then flash multidisabled-samsung-2.3.zip, then flash vbmeta-disabler.zip, then finally flash your TWRP.tar over the original TWRP. Now the phone only boots into TWRP.

I'm sure I am missing one step to build and flash your TWRP. Any additional help would be appreciated.
 

modpunk

Recognized Contributor
Oct 14, 2011
1,699
6,465
143
I verified that vbmeta-disabled.img has the same MD5 hash.
I renamed vbmeta-disabled.img to vbmeta.img and I TAR'd that and recovery.img into TWRP.tar file. (So TWRP.tar only has two files vbmeta.img and recovery.img). I used ODIN to flash TWRP.tar. After restating the phone it boots back to Download mode. Unfortunately I get the same error message displayed on the Download Mode screen

Error verifying vbmeta image OK_NOT_SIGNED (3)

I also tried flashing the original TWRP to the phone, then flash multidisabled-samsung-2.3.zip, then flash vbmeta-disabler.zip, then finally flash your TWRP.tar over the original TWRP. Now the phone only boots into TWRP.

I'm sure I am missing one step to build and flash your TWRP. Any additional help would be appreciated.
You really have an unlocked bootloader?
 

trancinguy

Senior Member
Feb 4, 2013
351
82
48
I verified that vbmeta-disabled.img has the same MD5 hash.
I renamed vbmeta-disabled.img to vbmeta.img and I TAR'd that and recovery.img into TWRP.tar file.
I'm sure I am missing one step to build and flash your TWRP. Any additional help would be appreciated.
Did you extract the recovery IMG after download?
 

JohnDandel

Member
Apr 15, 2020
16
0
0
Did you extract the recovery IMG after download?
I do not need to extract the recovery.img file because I'm trying to build this TWRP from source.

---------- Post added at 01:01 PM ---------- Previous post was at 12:59 PM ----------

You really have an unlocked bootloader?
The bootloader is unlocked and I have root privileges from installing Magisk.
What are your steps to build this TWRP project so I can build it for my self?
Thanks.
 

modpunk

Recognized Contributor
Oct 14, 2011
1,699
6,465
143
I do not need to extract the recovery.img file because I'm trying to build this TWRP from source.

---------- Post added at 01:01 PM ---------- Previous post was at 12:59 PM ----------


The bootloader is unlocked and I have root privileges from installing Magisk.
What are your steps to build this TWRP project so I can build it for my self?
Thanks.
The build steps are documented here: https://github.com/whatawurst/android_device_samsung_beyond0lte/tree/twrp-9.0

Are you sure the recovery.img is correct? Did you inspect the boot image? The android source comes with a unpack_bootimg.py ...
 

JohnDandel

Member
Apr 15, 2020
16
0
0
Building TWRP

@modpunk Here are the steps I take to build this TWRP and the three errors I encounter.
Initialize the repo:
repo init --depth=1 -u git://github.com/minimal-manifest-twrp/platform_manifest_twrp_omni.git -b twrp-9.0

Create a local manifest:
vim .repo/local_manifests/roomservice.xml

<?xml version="1.0" encoding="UTF-8"?>
<manifest>
<project name="whatawurst/android_device_samsung_beyond0lte" path="device/samsung/beyond0lte" />
</manifest>

Sync the repo:
repo sync

Error 1:
After the repo sync I get an error
Checking out projects: 4% (9/224) platform/dalvikerror: Cannot checkout whatawurst/android_device_samsung_beyond0lte: ManifestInvalidRevisionError: revision refs/tags/android-9.0.0_r47 in whatawurst/android_device_samsung_beyond0lte not found
error: in `sync`: revision refs/tags/android-9.0.0_r47 in whatawurst/android_device_samsung_beyond0lte not found

Error 1 fix:
I changed the <project> tag to
<project name="whatawurst/android_device_samsung_beyond0lte" path="device/samsung/beyond0lte" remote="github" revision="twrp-9.0"/>

Extract vendor blobs
cd device/samsung/beyond0lte
./extract-files.sh

Error 2:
Some of the blobs will not transfer because you need permission to move them.

Error 2 fix:
I copied them manually one by one based on what is in the proprietary-files.txt, proprietary-files-twrp.txt, and proprietary-files-vendor.txt
Then put them in the correct place.

Setup the environment

export ALLOW_MISSING_DEPENDENCIES=true
source build/envsetup.sh
lunch lineage_beyond0lte-userdebug

Error 3
build/make/core/product_config.mk:234: error: Can not locate config makefile for product "lineage_beyond0lte".

Lunch gives these options, none of them is lineage_beyond0lte-userdebug
Lunch menu... pick a combo:
1. aosp_arm-eng
2. aosp_arm64-eng
3. aosp_mips-eng
4. aosp_mips64-eng
5. aosp_x86-eng
6. aosp_x86_64-eng
7. omni_emulator-userdebug

Error 3 fix
I don't know what to do here. Does anyone have any idea? Are there previous 2 error fixes correct?
 

Meemo23

Senior Member
Nov 17, 2010
1,195
644
0
Under my bed...
This is the only recovery that works and goes to the menu but the recovery thinks my S10 plus is a Beyond1lte when it is a Beyond2lte and gives me error 7 saying this device is not a beyondlte2 device to flash your Beta 2 for the samsung galaxy s10 plus and I cannot flash any other firmwares because it thinks it is a beyond1lte. Please can you help me.


Edit: never mind I am an idiot I figured it out sorry and thank you!!
 
Last edited:

modpunk

Recognized Contributor
Oct 14, 2011
1,699
6,465
143
@modpunk Here are the steps I take to build this TWRP and the three errors I encounter.
Initialize the repo:
repo init --depth=1 -u git://github.com/minimal-manifest-twrp/platform_manifest_twrp_omni.git -b twrp-9.0

Create a local manifest:
vim .repo/local_manifests/roomservice.xml

<?xml version="1.0" encoding="UTF-8"?>
<manifest>
<project name="whatawurst/android_device_samsung_beyond0lte" path="device/samsung/beyond0lte" />
</manifest>

Sync the repo:
repo sync

Error 1:
After the repo sync I get an error
Checking out projects: 4% (9/224) platform/dalvikerror: Cannot checkout whatawurst/android_device_samsung_beyond0lte: ManifestInvalidRevisionError: revision refs/tags/android-9.0.0_r47 in whatawurst/android_device_samsung_beyond0lte not found
error: in `sync`: revision refs/tags/android-9.0.0_r47 in whatawurst/android_device_samsung_beyond0lte not found

Error 1 fix:
I changed the <project> tag to
<project name="whatawurst/android_device_samsung_beyond0lte" path="device/samsung/beyond0lte" remote="github" revision="twrp-9.0"/>

Extract vendor blobs
cd device/samsung/beyond0lte
./extract-files.sh

Error 2:
Some of the blobs will not transfer because you need permission to move them.

Error 2 fix:
I copied them manually one by one based on what is in the proprietary-files.txt, proprietary-files-twrp.txt, and proprietary-files-vendor.txt
Then put them in the correct place.
I don't think that this will work. The script creates several .mk files. You can mount the images of the stock rom and copy together the tree and then run ./extract-utils.sh /path/to/rom/[/QUOTE]
 

Donkeykong307

Member
Dec 31, 2016
8
2
3
How to build TWRP

Steps i used to build TWRP

Code:
Make a workspace:
mkdir -p ~/twrp/repo
cd ~/twrp/repo

Initialize the repo:
repo init --depth=1 -u git://github.com/minimal-manifest-twrp/platform_manifest_twrp_omni.git -b twrp-9.0

Create a local manifest:
vim .repo/local_manifests/roomservice.xml

<?xml version="1.0" encoding="UTF-8"?>
<manifest>
    <project name="whatawurst/android_device_samsung_beyond0lte" path="device/samsung/beyond0lte" remote="github" revision="twrp-9.0" />
    <project name="whatawurst/android_device_samsung_exynos9820-common" path="device/samsung/exynos9820-common" remote="github" revision="twrp-9.0" />
</manifest>

Sync the repo:
repo sync

Extract vendor blobs
cd device/samsung/beyond0lte
./extract-files.sh

export ALLOW_MISSING_DEPENDENCIES=true
source build/envsetup.sh
lunch omni_beyond0lte-userdebug <--- NOTE omni NOT lineage

mka recoveryimage
 
Last edited:

JohnDandel

Member
Apr 15, 2020
16
0
0
Building TWRP

@modpunk @Donkeykong307
I finally built this project.
My issues was when I manually copied the proprietary files off the phone. I put two files in the wrong folder.

Now when I try to flash the TWRP.img file using ODIN, containing the recovery.img. and vbmeta.img file. I try to go into recovery mode, but the phone goes back to download mode with an error message
Error verifying vbmeta image: OK_NOT_SIGNED (3)
Any idea on this error?

I have noticed that there is a difference in file size between the one ModPunk built at 65,328kb and the one I built at 66,048kb. Any idea on this file size difference?
 
Last edited:

angela5246

Senior Member
Mar 27, 2020
62
13
0
Steps i used to build TWRP

Code:
Make a workspace:
mkdir -p ~/twrp/repo
cd ~/twrp/repo

Initialize the repo:
repo init --depth=1 -u git://github.com/minimal-manifest-twrp/platform_manifest_twrp_omni.git -b twrp-9.0

Create a local manifest:
vim .repo/local_manifests/roomservice.xml

<?xml version="1.0" encoding="UTF-8"?>
<manifest>
    <project name="whatawurst/android_device_samsung_beyond0lte" path="device/samsung/beyond0lte" remote="github" revision="twrp-9.0" />
    <project name="whatawurst/android_device_samsung_exynos9820-common" path="device/samsung/exynos9820-common" remote="github" revision="twrp-9.0" />
</manifest>

Sync the repo:
repo sync

Extract vendor blobs
cd device/samsung/beyond0lte
./extract-files.sh

export ALLOW_MISSING_DEPENDENCIES=true
source build/envsetup.sh
lunch omni_beyond0lte-userdebug <--- NOTE omni NOT lineage

mka recoveryimage
If you use lunch omni_beyond0lte-userdebug the recovery works but then you don't have access via adb. It throws you an error about vendor key not set.

If you want to have adb access you need to build like this:
Code:
lunch omni_beyond0lte-eng


---------- Post added at 01:53 PM ---------- Previous post was at 01:50 PM ----------

You need to modify the fstab of TWRP and rebuild the recovery. The file for the recovery is here:

https://github.com/whatawurst/andro...9820-common/blob/twrp-9.0/recovery/twrp.fstab
I did. My twrp.fstab looks like this:
Code:
/data            ext4      /dev/block/platform/13d60000.ufs/by-name/userdata    flags=fileencryption=footer,length=-20480
However, logcat throws this error when I try to mount /data:
Code:
06-09 11:47:16.143  4983  4983 F linker  : CANNOT LINK EXECUTABLE "/sbin/[email protected]": cannot locate symbol "sk_pop_free_ex" referenced by "/sbin/libkeymaster_helper_vendor.so"...
What might be the reason for that? Could it have to do with the lenght?
 

modpunk

Recognized Contributor
Oct 14, 2011
1,699
6,465
143
If you use lunch omni_beyond0lte-userdebug the recovery works but then you don't have access via adb. It throws you an error about vendor key not set.

If you want to have adb access you need to build like this:
Code:
lunch omni_beyond0lte-eng


---------- Post added at 01:53 PM ---------- Previous post was at 01:50 PM ----------



I did. My twrp.fstab looks like this:
Code:
/data            ext4      /dev/block/platform/13d60000.ufs/by-name/userdata    flags=fileencryption=footer,length=-20480
However, logcat throws this error when I try to mount /data:
Code:
06-09 11:47:16.143  4983  4983 F linker  : CANNOT LINK EXECUTABLE "/sbin/[email protected]": cannot locate symbol "sk_pop_free_ex" referenced by "/sbin/libkeymaster_helper_vendor.so"...
What might be the reason for that? Could it have to do with the lenght?
Oh, you should throw out the keymaster and gatekeeper stuff in the init file.