Have you forgotten your phones’ password? or can’t get access to your phone because of any other reasons follow this Guide.
This is what happened to me last week.
I wanted to change my phones’ Screenlock for some reasons. And I changed it, guess what? I forgot it the next day when I woke up(’cause my stupid brain can’t remember things at least passwords).
So I thought about using forgot password option and recover my phone but after realizing that there is no such thing in my Lineage ROM these are the things I tried.
I took my Laptop and navigated to Googles’ Find My Phone which is given administrator access in every popular phone and ROM these days. I tried to lock my phone with a new pin so that it could replace my last pattern. But it didn’t work.
I tried installing Software like Dr.Fone which sadly is not available for my phone manufacturer (btw mine is Oneplus) but if your phone is of any other brand then check their Support Page if your Device is available here.
After a lot of futile tries, I came to know that I am really wrecked. I have nothing but to reinstall the ROM and Hoping that Wiping System partition would help. Then I Booted into TWRP Recovery and wiped my System Partition. For my luck, I didn’t delete the ROM and Gapps which I flashed last time. So I installed them without any errors hoping it would unlock my phone. Little did I hope nothing is changed.
So, after all these futile tries I tried checking online if anyone had this problem before (Should have done this before) with Lineage ROM as it is very popular and available for many phones.
And actually, I found Something useful.
Here’s exactly what I did to unlock my phone and what you should do if you are stuck like me.
With Custom Recovery Installed
Requirements: PC and a Phone which is stuck (which has TWRP or Clock mod Recovery).
Turn off your phone and boot into Recovery mode.
As you don’t have access to advanced or developer settings just turn off your phone and Use Physical Buttons to boot into Recovery mode. Don’t know your Phones’ Boot Pattern then check from here.
Connect your phone to Computer with a USB cable.
Open CMD on your Computer and Type ‘adb devices‘
Here are some results which you might get.
You might get an Error that
'adb devices' is not recognized as an internal or external command,
operable program or batch file.
Or else if you have done some flashing and stuff, at some point you might have installed ADB or Android Debug Bridge drivers. If you have then good for you or else follow How to install ADB drivers on your computer. It really is a quick process so don’t worry much about it.
If you have Installed it then Try type ‘adb devices’ again. Then you should have something like this.
Type in ‘adb shell’ in Command Prompt
This takes you to something like this. What ADB shell is like a terminal bridge between your PC and Phone.
Type this following line and you are done
mv /data/system/gatekeeper.* /sdcard/
This will help you to delete your Passwords and let you through the Lockscreen.
I know some of you have no custom recovery installed. Don’t worry guys I got you covered
- Open your Custom Recovery.
- Open the File manager and go to sd card.
- Search for these files.
- Select them and delete them
- Reboot your phone.
Without Custom Recovery Installed
a.k.a ADB method. Just follow these steps to recover your phone.
How to install adb
- Open Command Prompt
- Type in
sudo apt-get install android-tools-adb
- Just follow what it says until its done. Now you have installed adb on your pc
Connect your Phone to PC. Now open your Command Prompt and Type in the following lines of code and you are done.
adb devices adb shell cd data/system su rm *.key
Reboot your Phone.
Even after this, you see some lock screen then try some random password and pin you will be fine.
For everyone who has an SD card with them, here is a simple thing to do.
- Download this File. (Scroll down to download)
- Copy this file to SD card. Insert your SD card into your phone.
- Flash it! and you are done.
No SD card but want to use this method? Okay, this Will guide you through How you can Transfer Files Using Custom Recovery. After you have done that Follow those previous steps.