[Redmi Note 8 Guides, News, & Discussion] JellyfishSprinkle:
This is an entertaining and educational review of degoogling my first android device.

The Goal: A LineageOS device without GAPPS, with TWRP, Magisk, and MicroG

Finding a phone that is available new in Australia, has a decent camera, and supports both TWRP and LineageOS officially is a suprisingly hard ask. After a couple of days of cross-referencing and researching I found one device: the Xiaomi Redmi Note 8.

In the days before the delivery of this new phone, I pieced together a guide for installing everything I needed in nice step by step order, I downloaded everything I thought I would need, TWRP, LineageOS, Magisk both apk and zip, MicroG, and the SmaliPatcher, as well as the Mi Unlocker and USB Drivers, and I made a Mi account hooked up to an email address. I was prepared, everything was set up for smooth sailing.

As we all know, things rarely turn out so easy.

The first hurdle was unlocking the bootloader. In order to unlock the bootloader, you have to unlock Developer Options and enable OEM Unlocking, USB Debugging, and USB Debugging (Security Settings). I'm not stuttering, there are two USB Debuggings. I had unlocked Developer Permissions on my Smart E9 before, but that runs Oreo Go edition, and in that one you have to go Settings -> About and tap the build version 7 times. In a Xiaomi, you have to tap MIUI version 7 times. This is not obvious, as 'build version' is also visible in 'About'.

Enabling the correct permissions was also not so simple. Enabling OEM Unlocking and USB Debugging was as simple as tapping the switches, but USB Debugging (Security Settings) has three seperate warning popups and only lets you know you NEED a Sim card AFTER you've tapped through.

The Redmi Note 8 takes Nano Sims. I only have my regular sized Sim. So, on the phone with my carrier I go to order a replacement Nano Sim. After a frustrating conversation online in which they tell me to ring my local branch and won't give me the number, I ring my local branch. Who then won't replace it unless I come in, which I point blank refuse to do due to the whole plague situation. I decide to phone the main branch, who tells me they'll send a replacement out right away free of charge. Okay then.

To insert the Sim (And a MicroSD if you want) there's a small hole in left the side of the phone, where you stick the little pokey key thing that comes with the phone (A paperclip is too thick), and the Sim tray pops out. The Sim and SD card just sit on the tray, balanced precariously, as you gently stuff that tray back where it came from.

Sim inserted successfully, so now I try to enable USB Debugging (Security Settings) again. Tap through the three warning popups and success! All permissions were now set, and it was time to unlock the bootloader!

I turn off the phone, boot into fastboot, log into the Mi Unlock App on the PC and...

Turns out: You have to have a recovery phone number for the Mi Account before you can see any unlocking options on the PC App. I guess the chinese government has my phone number now.

So, after setting up that recovery phone number on the website I tried again, log the phone into fastboot, log into the Mi Unlock App, plug in the phone and...

I get told to use the Mi Unlock Status option on the phone to unlock the option to unlock. Huh. Fine then.

This is where things get a little bit more ring around the rosy, because I had already hooked the Mi Account up to the phone and logged in, for some reason the Mi Unlock Status option in the phone point blank refused to log in using mobile data. I logged out of the Mi Account on the phone, rebooted the phone, and then tapped straight through to the Mi Unlock Status, logging in there using Mobile Data. It worked this time!

NOW it was time to use the Mi Unlock App. I opened it up, signed in to the Mi Account, and received a verification SMS on the phone. Verification dealt with, I turned off the phone, logged it into fastboot, use the USB to connect to the PC, and press Unlock. Success! Well, sort of. I get told I need to wait 168 hours before I can unlock the bootloader, but progress is progress.

Waiting 168 hours (7 days) to play with a new toy is difficult. I also had to make sure I kept using the device during this time. I browsed reddit and mi community for a few minutes a day and played a bit of tetris. Other than that the phone was left on but idle. This is an example of bare minimum usage because A: I'm not really a phone person, I'm a PC person, and B: At this point I am referring to my phone as 'the spy machine' due to just how utterly violating of privacy I know this thing to be. Thus the degoogling.

After waiting the requisite amount of time it was time to ACTUALLY unlock the bootloader. At this point I was regretting not buying a Motorola G7, but I couldn't have purchased one new anyway.

So again, I open the Mi Unlock App, sign in, boot the phone into fastboot, and plug that sucker in. Press Unlock. Success! Actual success this time, bootloader is unlocked. It reboots and has a little unlock symbol at the bottom of the screen. When the phone boots up, it asks for my Mi Account password before it will set up the OS again. No problem.

Now it was time for TWRP. Developer Options and both kinds of USB Debugging had been reset after unlocking the bootloader, so they all had to be enabled again.

I copy the TWRP recovery image into my platform-tools folder and open a command prompt in said folder. I connect my phone to the PC, and in the command window I type

adb devices

. It lists the devices, which is to say none. Freaking what.

I read a couple of guides. Okay, drivers are needed. The Mi Unlock App straight up came with the necessary drivers so, double clicky the USB drivers exe and boom. All fixed.

adb devices

now lists my phone and it's unauthorized. Back to the phone, allow this computer and press the checkbox for always allow it. Now it's authorized.

Now that ADB is working it's time to install TWRP. I reboot the phone into fastboot using the command window with

adb reboot bootloader

. I'm not sure its actually necessary to boot into fastboot this way, I'm pretty sure doing it manually while it's plugged in works just fine, but that's what the guide said and at this point I am too nervous to deviate.

Alright, now the phone is in fastboot and I still have a command window up. I make sure the device is still connected with

adb devices

Nothing. Okay what now, oh, oopsie. Turns out that's the wrong command when in fastboot. Okay

fastboot devices

That's much better.

Now I type

fastboot flash recovery twrp-3.4.0-1-ginkgo.img

Successfully flashed, now to boot into it.

fastboot boot twrp-3.4.0-1-ginkgo.img

The phone booted into TWRP! I am excited, I'd never gotten this far before.

With TWRP flashed it was time for LineageOS. This was a little odd because to install it, the guide said to 'sideload' the zip file, and I had no idea what this actually meant. But, it had step by step instructions, and you don't learn unless you try. Onwards I went.

First, I move the LineageOS zip file to my platform-tools directory. Then I use TWRP to make a backup, then I head back to the home screen, press wipe, and format data. Don't ask me why I did this, it was in my guide and I'm pretty sure a youtube video told me to. I don't think this step is necessary, and quite frankly the_weird_aquarian's guide says it's not recommended.

Now it was time to actually sideload the LineageOS zip. On the TWRP home screen, I choose Advanced -> ADB Sideload and swipe the little slider. On the command window I type

adb sideload lineage-17.1-20201026-nightly-ginkgo-signed.zip

I didn't actually type out that whole zip name by hand, that'd be ridiculous, I pressed tab to autofill it after typing "lin". This step took a while to finish.

After it was done, it offered to reboot. This was it. I rebooted and there it was, the LineageOS system. I had done the bulk of it!

(I had not done the bulk of it)

One thing I immediately noticed was that the little triangle and little square symbols for navigation were reversed from what they were in MIUI (original xiaomi phone OS).

I played with the device for a while, installed F-Droid and a few apps, made sure I could still make phone calls, that sort of thing.

Next it was time to install Magisk. First I needed to set the permissions again. This time 'build number' is the thing to tap, right at the bottom of the About page.

Developer Options are in a different spot in LineageOS, this time they're under Settings -> System -> Advanced, and now I enable Android Debugging, which is the same as USB Debugging but everyone needs their own name for it.

Now I transfer the Magisk apk and zip file onto the phone and install the apk. Opening up the app, I notice that it says "ramdisk: no". The Magisk Wiki says that if my device’s boot partition does not include ramdisk, I have to patch Magisk into the TWRP recovery, and it has instructions on how to do that.

I grab the TWRP image and copy it onto the phone, then go back into the Magisk Manager app and press 'Install' on the Magisk card. I make sure 'Recovery' is checked, choose the 'Select and Patch a File' option and pick said recovery image.

After it finished patching, I pull it back to the computer with

adb pull /sdcard/Download/magisk_patched.img

Then I reboot the phone into fastboot and flash this patched recovery with

fastboot flash recovery magisk_patched.img

After rebooting I check the Magisk Manager app, which reports that Magisk was NOT installed. Okay, so the Wiki says that in order to boot into the Magisk system I have to hold down Volume Up + Power just like I would if I was booting into recovery, but then let go of everything after the splash screen. Okay, I do that.

It boots to fastboot. Huh, odd. Okay, I turn the phone off and try it again. It boots normally this time, but Magisk is still not installed. I looked up the problem, Magisk Manager didn't install twice, it wasn't installed to external storage, I reinstalled the Manager and it didn't help.

I had nothing. No idea at all. I gave it a break for a day.

This was when I encountered one thing I really didn't like about LineageOS: the Camera.

The default LineageOS Camera is not great. The pictures are fine, but the Redmi Note 8 comes with a macro lens, an ultrawide lens, and the ability to do panorama shots. None of these were accessible in the default camera.

I tried Open Camera and FreeDCam, I didn't like either of them. Camera MX wasn't available on Aurora Store.

So after some googling I came to what was to be my saviour: ANXCamera. It's the MIUI Camera App, retrofitted for Custom ROMs.

There was one problem: It needed Magisk.

Back to XDA I go, back to the beginners guides. Specifically the_weird_aquarian's guide. Here, the instructions for Magisk were different. These said to just install the zip from inside TWRP. The Wiki said this was not recommended. I do it anyway.

I rebooted, crossing my fingers. It booted, a good start. I tapped into the Magisk App and... "Installed". I had done it!

Now I had to figure out how to install the two modules I had downloaded: ANXCamera and ANXFramework. It's simple after Magisk is actually installed, there's a little puzzle piece logo on the bottom right for AddOns. Next, I install both modules and reboot, excited for a new camera.

Then, disaster struck. I bootlooped.

The first step was obviously to panic, which I did with great diligence and enthusiasm. Then I boot into the recovery and try to restore from the backup I made. Only to discover that there was no backup there. It had gotten deleted when I wiped the device the first time.

I googled and found a bootloop hotfix addon for ANXCamera, listed in bold right on the page where I downloaded the other modules. But it needed to be installed in Magisk, and I didn't have access to Magisk.

Next, I tried to 'reinstall' LineageOS by sideloading it again. This did absolutely squat diddly.

Factory reset came to the rescue.

It was only after this that I found that the ANXCamera wiki straight up tells you that if you bootloop you should use the recovery file manager to remove '/data/adb/modules/ANXFramework' and '/data/adb/modules/ANXCamera'. Oh well.

My phone was working again, but all my apps and contacts had been deleted. Strangely, all the pictures I'd taken and all the files I had transferred to the phone were untouched. I wasn't about to look a gift horse in the mouth.

I reinstalled Magisk Manager, determined to get this camera app working. It said Magisk was already installed, and that it needed to download and install a few files to get everything working. Alrighty, no worries there. I let it reboot and hoped really hard that it wasn't about to reinstall the modules that had bootlooped my phone the first time.

It didn't. The files were technically there, but they weren't counted as installed in the AddOn's section of Magisk's Manager. I reinstall them, along with the bootloop fix and a 48MP fix. It rebooted. No bootloop. Everything was okay.

Now I needed the actual camera app, because this wasn't complicated enough yet. So, I install F-Droid, and then install Aurora Store from F-Droid, and, in Aurora Store, I find the ANX Camera Pro app. I install that, open it up and press save, then start up the actual camera app. Everything was black. It wasn't working. I had to enable all the permissions for the app manually.

Sweet, no more black screen. Everything looked good! Then I tried the front camera, and it crashed. Damn. Okay, the FAQ says to hop back into ANXCamera Pro and turn off Hand Gestures. I do that, and the front camera works now, awesome.

Portrait mode crashed the app again. The 48MP fix was supposed to fix that. Okay, uninstall that and install an older version... nothing. Uninstall that and install ANXCustlibs instead. Nothing. Installed the latest version of 48MP fix. Still nope.

I could not get portrait mode working at all, it just crashes the camera app every time. Everything else works nicely, so I just moved that mode out of the main section in the app's own settings.

I still haven't installed MicroG. I haven't found a good reason to install it, and truth be told I am a little scared of what traps and tripwires lie in wait on that particular journey. One day I will make it, but for now, I have a degoogled phone.