HTC One M8 is the current flagship from HTC, and in our opinion is the most dazzling smartphone in the market with a full metallic design and aesthetic design. The M8 was released in the first quarter of this year with top-notch specs and stunning looks. However the true power of an Android smartphone can only be revealed when the device is subjected to some development. HTC M8 has vast developers community which strives to develop new custom roms, custom kernels, rooting and recovery methods etc…
Any sort of advanced usage of Android smartphone needs permission to modify the files in the System partition (/System) of the device. When formatting the /data partition while you’re testing any mods or roms on your M8, you might have observed some random reboots of the device. These random reboots might be a problem caused by the wp_mod.ko module which is responsible to disable Read/Write protection on your device. When this module is loaded too late and if anything changes before the module is loaded, you might have a corrupted /data partition on your device.
So whenever you’ll try to make changes to the /system partition your device reboots randomly. This means your device reboots whenever you try to remove, copy, move, edit any file in the system partition which is a serious issue for those who do a lot of modding. This issue leaves the following trace in the kernel log (last_kmsg.txt):
So, here we are to guide you on how to prevent these random reboots on your precious M8.
How to Fix Random Reboots on HTC One M8
- Download the mini-sdk package and extract it to c:\mini-sdk
- Download the fsck.ext4 binary and put it into c:\mini-sdk
- Connect your device to the PC using an USB cable.
- Boot your device in recovery mode
- Power off your device.
- Press and hold Volume Down button, and press the Power button to switch on your phone and release it quickly, but continue to hold the Volume Down button. This will boot your HTC One M8 into bootloader mode.
- Press Volume down once to navigate to Recovery option, then press Power button to enter Recovery mode.
- Open a command prompt on the PC by typing cmd in the search and press enter.
- Type the following command in the command prompt to navigate to the extracted folder in step 1.
cd /d c:\mini-sdk
- Now enter the following command to push fsck.ext4 tool to your device.
adb push fsck.ext4 /tmp
- Start the adb shell by typing the following command.
- Give full permissions to the fsck.ext4 file by giving 777 as the permission set.
chmod 777 /tmp/fsck.ext4
- Now move the file with proper permissions to the data partition. Type the following command:
/tmp/fsck.ext4 -fn /dev/block/mmcblk0p47
This will fix your /data partition and you should see a similar output reflecting the success of the process.
e2fsck 1.42.9 (28-Dec-2013) Pass 1: Checking inodes, blocks, and sizes Pass 2: Checking directory structure Pass 3: Checking directory connectivity Pass 4: Checking reference counts Pass 5: Checking group summary information /dev/block/mmcblk0p47: 19050/712704 files (2.7% non-contiguous), 2320338/2850816 blocks
That’s it, your /data partition is now fixed and you should no longer experience random reboots problem on your device considering that it was solely the issue.
Leave your feedback in the comments section below.