How to Install Official TWRP on the Samsung Galaxy S9 and Galaxy S9+
One of the most beautiful aspects of the Android Operating system is its open source nature, which opens up a whole new world of possibilities. However, none of it is possible without, a custom recovery such as TWRP. Its primary purpose is to recover your device should any custom software flashing go awry. Without a custom recovery, it’s often straight up impossible to even flash a custom ROM as the stock recovery will usually restrict non-official software from being installed.
Unfortunately, due to most Snapdragon-based devices being carrier locked, TWRP is available only on Exynos variants of the Galaxy S9 and S9+. Here's how to flash TWRP on your Galaxy S9 and S9+ from scratch. Ensure that your phone is connected to your PC via USB. Please be patient as the process may take some time. If the process is interrupted in any way, you could risk bricking your device. As the process trips Samsung's Know, it will void any warranties that come with it, and you will no longer be able to receive OTA updates from Samsung. You should be ok if you follow the guide to the tee, however, things do go wrong every now and then so proceed with caution.
Step 1: In your ROM, go to Settings -> About device. Tap seven times on Build number to enable Developer options.
Step 2: Go to Settings -> Developer options and enable OEM Unlock option.
Step 4: Download and extract Odin to your computer. It's recommended that you save it at an easy to access location.
Step 6: Enter the Download Mode on your device by pressing and holding the Volume down + Bixby+ Power keys for 15 seconds and then press Volume Up to enter download mode
press [VOLUME UP] to get into Download Mode.
Step 7: On your PC, open Odin (which was previously downloaded) and place that TWRP tar (also previously downloaded) file in the [AP] slot. The next steps are critical, so ensure that you follow them to the tee
Step 8: Hold the Volume Up, Power and Bixby keys on your phone and then press start on Odin.
Wait for the phone to reboot. It is essential that you DO NOT release the Volume Up, Power and Bixby keys or you may not reboot into TWRP.
Step 9: After your phone has finished rebooting, you should be in TWRP now. Now, you will be presented with a screen asking you if you want to allow system modifications.On the screen, select "Keep /system RO" and swipe right to allow modifications.
Step 10: Go to "Wipe" menu of TWRP. From there, select "Format Data" and type "yes" to continue. Ensure that the process has completed before processing.
Step 11: Go to "Reboot" menu and Press "Recovery" to reboot TWRP.
Step 12: Download the special dm-verity and force encryption disabler on your computer and copy it to the internal storage or an SD card, which needs to be inserted later.
Step 13: Go to "Install" menu of TWRP, locate the file on your phone/SD card and flash it.
Step 14: Once the process is complete, reboot your phone. If everything is done right, it should take you to your home screen, and you now have a fully functional version of TWRP on your phone.
With the availability of official TWRP, you can flash a custom ROM on your Galaxy S9 or S9+, and since both phones are Project Treble compatible, you can even flash Stock Android on it. However, no builds exist for the devices right now, but we'll let you know as soon as they are released.
News Source: XDA developers