Curiously, Windows can write its BSOD diagnosis data to disk. I wonder if a kernel panic is equivalent to a BSOD?
Yes, kernel panic is equivalent to BSOD, mostly triggered on hardware or driver errors. Basically system writes logs to screen and freezes. Writes to disk after panic are refused, because filesystem may be corrupted when error in kernel occurred (there is no belief to kernel any more).
However there are some methods to write panic logs in Linux:
- Kdump. System is booted to crash kernel (another copy of kernel) automatically after panic. Most serious method, used not only to read logs, but to analyze binary data and debug the kernel. Analytic tools required even to get simple logs, cause its a binary dump. Also it needs to reserve some RAM for crashkernel, that's why I do not like it for just writing logs.
- ACPI ERST. As we already know, using special memory block from motherboard/bios
- persistent ram (ramoops) and pstore block device (pstore-blk) modules. The last one can use block devices/partitions for writing logs, but I'm not sure it will work after panic occurred and did not find info who successfully deployed it. don't know, maybe using separate drive is ok for it.
That is what I discovered during last few days.
I don't know how it us done on BSOD, maybe Windows boots its crash kernel, mount and writes to disk from it.
I have created request in the Bugtracker
https://www.virtualbox.org/ticket/21282