Add crashkernel support

Bug #1887901 reported by Kai-Heng Feng
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Bugit
New
Low
Pierre Equoy
Checkbox Provider - Base
Expired
Low
Unassigned

Bug Description

To collect kernel panic when userspace processes are frozen, we can use crashkernel to collect log:
$ sudo apt-get install linux-crashdump

And the panic log will be put in /var/crash, if a kernel panic ever happened.

Tags: intermediate
Revision history for this message
Sylvain Pineau (sylvain-pineau) wrote :

Is it just a matter of adding linux-crashdump as a dependency?

affects: checkbox → plainbox-provider-checkbox
Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :

Also needs to upload the panic log from /var/crash/

Maybe leverage apport? It already has a hook for linux-crashdump.

Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :

Manually trigger a panic to see how it works:
# echo c > /proc/sysrq-trigger

Pierre Equoy (pieq)
Changed in qabro:
assignee: nobody → Pierre Equoy (pieq)
importance: Undecided → Low
Revision history for this message
Rex Tsai (chihchun) wrote :

There are a few things that should be considered.

= Setup =
- the linux-crashdump need to be installed.
- kdump should be enabled by /etc/default/kdump-tools or dpkg-configurate.
- kexec-tools will be installed, but we don't want kexec-tools handle reboots, only use kexe for kdump.
- the system needs to have enough memory to load the kernel and save the crash file, the current default settings is 512M-:192M. It may not enough to dump the file. I think Ubuntu should change it using auto[1], and does not store any crash on a machine less than 4G memory.
- we may consider to use kernel panic to capture other sockup issues[2].

= Bug report =
- there are several tools can be used to submit the crash file to launchpad. But I think it would best to use a checkbox test job capture the crash file, and use apport via qabro to submit the bug to launchpad.

[1] [0/7] Implement crashkernel=auto - Patchwork - https://lore.kernel.org/patchwork/cover/166256/
[2] Kernel/CrashdumpRecipe - Ubuntu Wiki - https://wiki.ubuntu.com/Kernel/CrashdumpRecipe

Revision history for this message
Pierre Equoy (pieq) wrote :

If Checkbox has a dedicated job that captures the kernel crash log and put it in Checkbox's $PLAINBOX_SESSION_SHARE directory, then it will be captured by QABro when filing a bug, since QABro currently archives the most current Checkbox session on the device and sends it over to Launchpad.

Revision history for this message
Scott Hu (huntu207) wrote :

Hi Pierre,

Could you help to investigate that captures the kernel crash log from /var/crash/ directly when QABro file a bug? Due to it seems need more effort to determine when should the job puts the kernel panic log to Checkbox's $PLAINBOX_SESSION_SHARE

Pierre Equoy (pieq)
Changed in qabro:
milestone: none → 0.15
Changed in plainbox-provider-checkbox:
importance: Undecided → Low
Pierre Equoy (pieq)
Changed in qabro:
milestone: 0.15 → 0.16
Vic Liu (zongminl)
tags: added: easy
tags: added: hard
tags: removed: easy hard
Pierre Equoy (pieq)
tags: added: hard
tags: added: intermediate
removed: hard
Pierre Equoy (pieq)
Changed in qabro:
milestone: 0.16 → 0.17
Pierre Equoy (pieq)
Changed in qabro:
milestone: 0.17 → 0.18
Pierre Equoy (pieq)
Changed in bugit:
milestone: 1.0 → 1.1
Revision history for this message
Maksim Beliaev (beliaev-maksim) wrote :

Bug was migrated to GitHub: https://github.com/canonical/checkbox/issues/147.
Bug is no more monitored here.

Changed in plainbox-provider-checkbox:
status: New → Expired
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.