Hello,
We have a device with an iMX6 processor running Android 7.1.2 (Nougat) and Linux kernel 4.9.17. We would like to use the ramoops/pstore feature to obtain useful logs related to kernel panics, but it is not working.
We have the following kernel config flags enabled:
CONFIG_PSTORE=y
CONFIG_PSTORE_CONSOLE=y
CONFIG_PSTORE_PMSG=y
CONFIG_PSTORE_RAM=y
We can then induce a kernel panic with the following instructions entered from an adb shell:
echo 1 > /proc/sys/kernel/sysrq
echo c > /proc/sysrq-trigger
But after the device reboots, the folder /sys/fs/pstore is empty
Is there something else we need to do to enable the feature, or some other reason why it doesn't work?
Gary
Hello Gary,
The ramoops Write the kernel panic to RAM, once you reset or poweroff the device is gone. You probably need modify the device tree as mention here:
Ramoops oops/panic logger — The Linux Kernel documentation
Regards