![](/style/images/good.png)
![](/style/images/bad.png)
Forgot pin to decrypt volume on Lineage
source link: https://forum.xda-developers.com/t/forgot-pin-to-decrypt-volume-on-lineage.4481687/#post-87457631
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
Forgot pin to decrypt volume on Lineage
Last year I installed LineageOS on a S9+ (now discontinued) and I encrypted the device. Now I have completely forgotten the pin to decrypt it, so it returns a message which states it will wipe all my data after some failed attempts. How to solve this problem before it's too late? Can I reset the attempts count, change the pin or backup the encrypted data?
The good news is I can access TWRP (v3.4.0) recovery mode. I read some tutorials, but I shouldn't remove decryption by cleaning the partition. Unlike normal boot, can I try to decrypt it as many times as I want, until I retrieve the pin, without worrying about my data being automatically erased? What if normal boot won't recognize the correct pin after recovering/changing it from TWRP? Do you know any terminal commands to execute the above tasks?
Go into TWRP.
Click the file manager.
Now go to data/system and find "locksettings.db" and delete it.
Reboot phone and see if pin is gone. If not.
Beck to TWRP. Back into data/system. And delete all of these and anything else that starts with "locksettings" that I forgot.
"gatekeeper.password.key
-gatekeeper.pattern.key
-locksettings.db
-locksettings.db-shm
-locksettings.db-wa
Reboot and pin should be gone.
Look into these as well.
![forum.xda-developers.com](https://forum.xda-developers.com/data/assets/logo/header-forum.jpeg)
[Solution] How to Delete Your Android Security PIN & PATTERN
![forum.xda-developers.com](https://forum.xda-developers.com/data/assets/logo/favicon-32x32.png)
![forum.xda-developers.com](https://forum.xda-developers.com/data/assets/logo/header-forum.jpeg)
[Tool][Tested]Remove lockscreen password/pin
![forum.xda-developers.com](https://forum.xda-developers.com/data/assets/logo/favicon-32x32.png)
Recommend
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK