Quick recap, at this point, you should have known and prepared:
- Whether your device has boot ramdisk
- Whether your device has a separate
vbmeta
partition - A
boot.img
,init_boot.img
orrecovery.img
based on (1)
Let’s continue to Patching Images.
Patching Images
- Copy the boot/init_boot/recovery image to your device
- Press the Install button in the Magisk card
- If you are patching a recovery image, check the “Recovery Mode” option
- If your device does NOT have a separate
vbmeta
partition, check the “Patch vbmeta in boot image” option - Choose “Select and Patch a File” in method, and select the boot/init_boot/recovery image
- Start the installation, and copy the patched image to your PC using ADB:
adb pull /sdcard/Download/magisk_patched_[random_strings].img
- Flash the patched boot/init_boot/recovery image to your device;
for most devices, reboot into fastboot mode and flash with command:
fastboot flash boot[_x] /path/to/magisk_patched_[random_strings].img
or
fastboot flash init_boot[_x] /path/to/magisk_patched.img_[random_strings]
or
fastboot flash recovery /path/to/magisk_patched.img_[random_strings]
,
where[_x]
should be_a
or_b
or empty depending on your device - (Optional) If your device has a separate
vbmeta
partition, you can patch thevbmeta
partition with command:
fastboot flash vbmeta --disable-verity --disable-verification vbmeta.img
(note that it may wipe your data) - Reboot and launch Magisk app (you will see a stub Magisk app if you have wipped your data; use it to bootstrap to a complete Magisk app), and you will see a prompt asking for environment fix; click and wait for the reboot
- Voila!
==========================
$ adb shell ls -l /dev/block/by-name
total 0
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 abl -> /dev/block/mmcblk0p25
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 ablbak -> /dev/block/mmcblk0p26
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 apdp -> /dev/block/mmcblk0p11
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 bk1 -> /dev/block/mmcblk0p49
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 bk2 -> /dev/block/mmcblk0p51
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 bluetooth -> /dev/block/mmcblk0p38
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 boot -> /dev/block/mmcblk0p58
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 cache -> /dev/block/mmcblk0p60
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 cmnlib -> /dev/block/mmcblk0p21
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 cmnlib64 -> /dev/block/mmcblk0p23
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 cmnlib64bak -> /dev/block/mmcblk0p24
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 cmnlibbak -> /dev/block/mmcblk0p22
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 cust -> /dev/block/mmcblk0p63
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 ddr -> /dev/block/mmcblk0p28
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 devcfg -> /dev/block/mmcblk0p31
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 devcfgbak -> /dev/block/mmcblk0p30
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 devinfo -> /dev/block/mmcblk0p43
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 dip -> /dev/block/mmcblk0p27
lrwxrwxrwx 1 root root 20 1970-01-01 07:08 dpo -> /dev/block/mmcblk0p2
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 dsp -> /dev/block/mmcblk0p48
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 frp -> /dev/block/mmcblk0p14
lrwxrwxrwx 1 root root 20 1970-01-01 07:08 fsc -> /dev/block/mmcblk0p3
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 fsg -> /dev/block/mmcblk0p45
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 hyp -> /dev/block/mmcblk0p17
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 hypbak -> /dev/block/mmcblk0p18
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 keymaster -> /dev/block/mmcblk0p36
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 keymasterbak -> /dev/block/mmcblk0p37
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 keystore -> /dev/block/mmcblk0p13
lrwxrwxrwx 1 root root 20 1970-01-01 07:08 limits -> /dev/block/mmcblk0p4
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 logdump -> /dev/block/mmcblk0p55
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 logfs -> /dev/block/mmcblk0p44
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 mdtp -> /dev/block/mmcblk0p50
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 mdtpsecapp -> /dev/block/mmcblk0p34
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 mdtpsecappbak -> /dev/block/mmcblk0p35
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 misc -> /dev/block/mmcblk0p42
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 modem -> /dev/block/mmcblk0p56
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 modemst1 -> /dev/block/mmcblk0p46
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 modemst2 -> /dev/block/mmcblk0p47
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 msadp -> /dev/block/mmcblk0p12
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 persist -> /dev/block/mmcblk0p53
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 persistbak -> /dev/block/mmcblk0p54
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 pmic -> /dev/block/mmcblk0p19
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 pmicbak -> /dev/block/mmcblk0p20
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 rawdump -> /dev/block/mmcblk0p57
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 recovery -> /dev/block/mmcblk0p59
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 rpm -> /dev/block/mmcblk0p15
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 rpmbak -> /dev/block/mmcblk0p16
lrwxrwxrwx 1 root root 20 1970-01-01 07:08 sec -> /dev/block/mmcblk0p6
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 splash -> /dev/block/mmcblk0p52
lrwxrwxrwx 1 root root 20 1970-01-01 07:08 ssd -> /dev/block/mmcblk0p5
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 sti -> /dev/block/mmcblk0p39
lrwxrwxrwx 1 root root 20 1970-01-01 07:08 storsec -> /dev/block/mmcblk0p9
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 storsecbak -> /dev/block/mmcblk0p10
lrwxrwxrwx 1 root root 20 1970-01-01 07:08 switch -> /dev/block/mmcblk0p1
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 system -> /dev/block/mmcblk0p61
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 toolsfv -> /dev/block/mmcblk0p29
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 tz -> /dev/block/mmcblk0p32
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 tzbak -> /dev/block/mmcblk0p33
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 userdata -> /dev/block/mmcblk0p64
lrwxrwxrwx 1 root root 20 1970-01-01 07:08 vbmeta -> /dev/block/mmcblk0p7
lrwxrwxrwx 1 root root 20 1970-01-01 07:08 vbmetabak -> /dev/block/mmcblk0p8
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 vendor -> /dev/block/mmcblk0p62
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 xbl -> /dev/block/mmcblk0p40
lrwxrwxrwx 1 root root 21 1970-01-01 07:08 xblbak -> /dev/block/mmcblk0p41
dhwan@dhwan-Aspire-A514:~$ adb pull /sdcard/Download/magisk_patched_25200_gzIBr.img
adb: error: failed to get feature set: no devices/emulators found
dhwan@dhwan-Aspire-A514:~$ adb pull /storage/emulated/0/Download/magisk_patched_25200_gzIBr.img
adb: error: failed to get feature set: no devices/emulators found
dhwan@dhwan-Aspire-A514:~$ adb devices
List of devices attached
dhwan@dhwan-Aspire-A514:~$ adb devices
List of devices attached
dhwan@dhwan-Aspire-A514:~$ adb devices
List of devices attached
dhwan@dhwan-Aspire-A514:~$ adb devices
List of devices attached
dhwan@dhwan-Aspire-A514:~$ adb devices
List of devices attached
dhwan@dhwan-Aspire-A514:~$ fastboot devices
4298e29b fastboot
dhwan@dhwan-Aspire-A514:~$ fastboot flash boot magisk_patched-25200_gzIBr.img
target reported max download size of 536870912 bytes
sending 'boot' (13356 KB)...
OKAY [ 0.436s]
writing 'boot'...
OKAY [ 0.120s]
finished. total time: 0.555s
dhwan@dhwan-Aspire-A514:~$ fastboot reboot
rebooting...
finished. total time: 0.050s
0 comments:
Post a Comment