Upon the introduction of Android 13, there was a change in how people used to root their smartphones. Until Android 13, you had to patch and flash the stock boot.img. However, starting Android 13, you have to patch and flash the stock init_boot.img.
This file is also present in the stock firmware, which can be downloaded from the OEM’s official website or a trusted third-party website. However, downloading the firmware (which could be anywhere between 3-5 GB) each time you have to use init_boot file calls for a lot of time, effort, and data.
With that said, there is a way you can extract the init_boot file from your smartphone without having to download the firmware. In this guide, you will get to know how to extract init_boot file from device without downloading firmware.
How to extract init_boot file from device without downloading firmware?
Here are the steps you need to follow to extract init_boot file from device without downloading firmware –
- On your PC, you should download and extract the Android SDK Platform Tools
- After that, enable USB Debugging and connect your device to the PC through USB
- Type in CMD in the platform-tools folder address bar before hitting Enter to launch Command Prompt
- Then, type the following command in the Command Prompt –
- After that, type the following command to get the partition table for your device –
ls – la /dev/block/bootdevice/by-name
- In the output, you need to refer to the lines having init_boot_a and init_boot_b and it’ll look something like –
lrwxrwxrwx 1 root root 16 1970-09-21 21:40 init_boot_a -> /dev/block/sde32 lrwxrwxrwx 1 root root 16 1970-09-21 21:40 init_boot_b -> /dev/block/sde63
- Then, note down the block address for the init_boot partitions and it’ll look something like this –
init_boot_a: /dev/block/sde32 init_boot_b: /dev/block/sde63
- Now, you need to transfer the stock init_boot.img files to the internal storage of your device
- You can now patch it using Magisk and flash it using Fastboot to obtain root
Related FAQs For Extract init_boot file from device without downloading firmware
Question: What’s an init_boot file and why should you back it up or take it out?
Answer: The init_boot file is important for starting your Android phone. It has the kernel and ramdisk, which are needed for the phone to work right. If you save or take out this file, you can fix your phone if it gets stuck while starting or has a soft brick.
Question: What do you need before you can take out the init_boot file from your phone without downloading the firmware?
Answer: Your phone must be rooted, Developer Options and OEM unlock turned on, and you need the ADB toolkit and ADB Platform Tools installed on your computer.
Question: How do you use ADB commands to get the init_boot file from your phone?
Answer: Connect your phone to your computer with a USB cable, turn on USB debugging, open a command prompt or terminal, and type these commands:
- adb shell
- ls -l /dev/block/bootdevice/by-name
- dd if=/dev/block/[block_address] of=/sdcard/init_boot.img
- adb pull /sdcard/init_boot.img
Question: How do you find the block address for the init_boot file?
Answer: Use the command ls -l /dev/block/bootdevice/by-name to see all the parts of your phone. Look for the part named init_boot_a or init_boot_b and write down its block address. Use this address in the dd command.
Question: What are the risks of taking out the init_boot file from your phone?
Answer: Usually, it’s safe to take out the init_boot file if you do it right and use the correct block address. But, there are risks like losing data, messing up the system, or making your phone unusable. So, save your data first and be careful.