-
Notifications
You must be signed in to change notification settings - Fork 0
/
how to root
104 lines (73 loc) · 3.52 KB
/
how to root
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
Device: Oneplus 5 | CPU artitecture: ARM-64
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Root the phone <<<<<<<<<<<<<<<<<<<<<<<<<<<<<
i) Download Twrp
twrp.me/devices/
[Warning: If you didn't find Twrp for your model, DO NOT proceed further. Leave.]
ii) Download platfrom-tools for Linux:
sudo apt install android-tools-adb
or
sudo apt install abd (optional)
For Windows, download & extract "platform-tools" for Windows.
https://dl.google.com/android/repository/platform-tools-latest-windows.zip
Go instde that folder, and hold SHIFT key and open powershell or Termainl.
[Optional]
sudo dnf install adb-enhanced //A swiss-knife to do lot of things. Check its repo
iii) Download Magisk installer zip & uninstaller zip from the link below:
To download uninstaller: https://github.com/topjohnwu/Magisk
iv) In phone remove Pin/Password/Pattern & Enable:
USB Debugging, OEM unlock, Advance Reboot, etc
Attach the phone to laptop and type:
(Adb = Android Debug Bridge)
adb devices //should show mobile connected & working
adb reboot bootloader //should take u to fastboot mode
fastboot devices //should show mobile
fastboot oem device-info //shows "True" or "False".
//True = Oem unlocked = Flashable.
//False = OEM Locked = Don't flash
fastboot oem unlock //Will unlock the bootloader.
fastboot reboot //Now the system gets reset.
//After Reboot, Enable USB debugging, OEM unlock.
Flash:
fastboot flash recovery xxxxx.img //Old command
fastboot boot xxxx.img //New command
After installing Twrp recovery, do this:
1. Flash Magisk zip from twrp. //Download the zip from offical github repo
2. Wipe Cache & Dalvik.
3. Reboot the device.
Now you have succesfully rooted your phone.
>>>>>>>>>>>>>>>>>>> Flash a new OS <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
i) Backup using Twrp
ii) Download OS (Custom or Stock)
iii) Check the hash for OS for file corruption using this command: md5 <file-name.zip>
iv) Clear Dalvik/ART Cache, Cache, System, Vendor, Data using Twrp's Wipe option.
(Dalvik is the java based Virtual Machine that runs Android Apps on Android. Dalvik-cache is the cache area for Dalvik VM, it is created when the Dalvik VM optimizes your app for running.)
v) Selete new OS and flash.
vi) Clear Dalvik/ART Cache, Cache.
>>>>>>>>>>>>>>>>>>>>> Forget the password/pin of the phone <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
Using the TWRP, navigate to /data/sytsem/ and delete the following files:
locksettings.db
device_policies.xml
locksettings.db-shm //optional
gatekeeper.password.key
gatekeeper.pattern.key
>>>>>>>>>>>>> Optional: Flash this only if ur phone gets decryted <<<<<<<<<<<<<<<<
no-verity-opt-encrypt.zip
______________________________________________________
Q. How to solve bootloop created by Magisk modules?
Ans: Reinstall that module of from Twrp in order to uninstall that module.
__________________________________________________________________________
>>>>>>>>>>>> Extra Stuff which might come handy <<<<<<<<<<<<<<<<<<<<<
Reddit communities //for asking help
xda-developers //for basically everything
selinux & selinux app //for security
F-droid //for opensource apps
xda-lads //for cool app
Lucky Patcher //for bypassing Android payment system [Illegal]
magisk module //for modifying phone capabilities
Termux //for terminal
Lineage OS //for custom rom
Matlog //for logs
Custom rom Vs Stock rom
=====================================================
PS: Don't waste too much time on Phone customization.
=====================================================