-
Notifications
You must be signed in to change notification settings - Fork 17
Description
Hi there,
Thanks again for the ROM, I am using the 17.1 now ("official" build, fresh install) and it works well, but I had an issue : I was not able to encrypt my phone: the phone reboots and does not compelte encryption.
I did the encryption process with logcat and could identify this error:
E Cryptfs : Bad magic for real block device /dev/block/bootdevice/by-name/userdata
E Cryptfs : Orig filesystem overlaps crypto footer region. Cannot encrypt in place.
After a quick search if found a similar issue on another device.
I understood that the issue was that the device /dev/block/bootdevice/by-name/userdata was using all the space available while encrypt requires 16 kB free (4 blocks), so I did the following :
- Reboot to recovery
- Launch adb shell
- Identify the device :
ls -l /dev/block/bootdevice/by-name/userdatawhich showed that it was a link to/dev/block/mmcblk0p48 - Get the size in block of the device
tune2fs -l /dev/block/mmcblk0p48, get the value of block count, in my case6372217 - Umount the device
umount /sdcard e2fsck -y -f /dev/block/mmcblk0p48resize2fs /dev/block/mmcblk0p48 6372213reboot
After that I was able to encrypt my phone
I discourage anyone who does not understand the above commands to use them at a bad command could result on data loss.
I guess this could be fixed in the ROM by changing the default size of the sdcard filesystem to keep these 16kB
Best regards,