Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Kernel kdump support and management #510

Merged
merged 4 commits into from
Apr 30, 2020
Merged

Kernel kdump support and management #510

merged 4 commits into from
Apr 30, 2020

Conversation

olivier-singla
Copy link
Contributor

In the event of a kernel crash, we need to gather as much information
as possible to understand and identify the root cause of the crash.
Currently, the kernel does not provide much information, which make
kernel crash investigation difficult and time consuming.

Fortunately, there is a way in the kernel to provide more information
in the case of a kernel crash. kdump is a feature of the Linux kernel
that creates crash dumps in the event of a kernel crash. This proposal
will add kernel kdump support.

An extension to the CLI utilities config and show is provided to
configure and manage kdump:

  • enable / disable kdump functionality
  • configure kdump (how many kernel core files can be stored locally,
    how much memory is allocated for kdump)
  • view kernel crash logs

The variable *USE_KDUMP* in the file /etc/default/kdump-tools is set to 0 to disable kdump, and set to 1 to enable kdump.

Since this command might require changing the kernel parameters to specify the amount of memory reserved for the capture kernel (the kernel parameters which are exported through */proc/cmdline*), a reboot is necessary. By default, the command displays a message showing that kdump functionality will be either enabled or disabled following the next reboot, unless the optional parameter *-n* has been provided. The optional parameter *-y* allows to automatically perform the reboot without asking for a confirmation. In this case, the command "config save -y" will be automatically performed prior to the reboot.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

user can choose to do warm reboot or fast reboot, recommend to do not integrate reboot into this config tool.

Olivier and others added 4 commits December 17, 2019 10:50
In the event of a kernel crash, we need to gather as much information
as possible to understand and identify the root cause of the crash.
Currently, the kernel does not provide much information, which make
kernel crash investigation difficult and time consuming.

Fortunately, there is a way in the kernel to provide more information
in the case of a kernel crash. kdump is a feature of the Linux kernel
that creates crash dumps in the event of a kernel crash. This proposal
will add kernel kdump support.

An extension to the CLI utilities config and show is provided to
 configure and manage kdump:
 - enable / disable kdump functionality
 - configure kdump (how many kernel core files can be stored locally,
   how much memory is allocated for kdump)
 - view kernel crash logs
lguohan pushed a commit to sonic-net/sonic-utilities that referenced this pull request Jan 25, 2020
In the event of a kernel crash, we need to gather as much information as possible to understand and identify the root cause of the crash. Currently, the kernel does not provide much information, which make kernel crash investigation difficult and time consuming.

Fortunately, there is a way in the kernel to provide more information in the case of a kernel crash. kdump is a feature of the Linux kernel that creates crash dumps in the event of a kernel crash. This PR will add kernel kdump support. Please note that there is another PR in sonic-utilities which is also needed:
sonic-net/sonic-buildimage#3722

An extension to the CLI utilities config and show is provided to configure and manage kdump:

view kdump status (enabled/disabled, active, configuration, stored crash files)
enable / disable kdump functionality
configure kdump (how many kernel crash logs can be saved, memory
allocated for capture kernel)
view kernel crash logs
There is a design document which describes this kdump implementation:
sonic-net/SONiC#510
@lguohan lguohan merged commit 015bb07 into sonic-net:master Apr 30, 2020
malletvapid23 added a commit to malletvapid23/Sonic-Utility that referenced this pull request Aug 3, 2023
In the event of a kernel crash, we need to gather as much information as possible to understand and identify the root cause of the crash. Currently, the kernel does not provide much information, which make kernel crash investigation difficult and time consuming.

Fortunately, there is a way in the kernel to provide more information in the case of a kernel crash. kdump is a feature of the Linux kernel that creates crash dumps in the event of a kernel crash. This PR will add kernel kdump support. Please note that there is another PR in sonic-utilities which is also needed:
sonic-net/sonic-buildimage#3722

An extension to the CLI utilities config and show is provided to configure and manage kdump:

view kdump status (enabled/disabled, active, configuration, stored crash files)
enable / disable kdump functionality
configure kdump (how many kernel crash logs can be saved, memory
allocated for capture kernel)
view kernel crash logs
There is a design document which describes this kdump implementation:
sonic-net/SONiC#510
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants