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

kdump is currently not compatible with Systemd Boot #138

Merged
merged 14 commits into from
Jun 21, 2024
2 changes: 1 addition & 1 deletion .rubocop.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# use the shared Yast defaults
inherit_from:
/usr/share/YaST2/data/devtools/data/rubocop_yast_style.yml
/usr/share/YaST2/data/devtools/data/rubocop-1.24.1_yast_style.yml

Metrics/AbcSize:
Max: 129
Expand Down
2 changes: 2 additions & 0 deletions Rakefile
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# frozen_string_literal: true

require "yast/rake"

Yast::Tasks.configuration do |conf|
Expand Down
7 changes: 7 additions & 0 deletions package/yast2-kdump.changes
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
-------------------------------------------------------------------
Wed Jun 19 15:36:03 UTC 2024 - Stefan Schubert <[email protected]>

- Do not suggest Kdump if Systemd-Boot is used. Kdump is not stable
if Systemd-Bootloader is used.
- 5.0.1

-------------------------------------------------------------------
Wed Aug 30 20:16:10 UTC 2023 - Josef Reidinger <[email protected]>

Expand Down
2 changes: 1 addition & 1 deletion package/yast2-kdump.spec
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@


Name: yast2-kdump
Version: 5.0.0
Version: 5.0.1
Release: 0
Summary: Configuration of kdump
License: GPL-2.0-only
Expand Down
2 changes: 2 additions & 0 deletions src/clients/kdump.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# frozen_string_literal: true

# Copyright (c) [2006-2021] SUSE LLC
#
# All Rights Reserved.
Expand Down
2 changes: 2 additions & 0 deletions src/clients/kdump_auto.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# frozen_string_literal: true
schubi2 marked this conversation as resolved.
Show resolved Hide resolved

require "kdump/clients/auto"

Y2Kdump::Clients::Auto.run
2 changes: 2 additions & 0 deletions src/clients/kdump_finish.rb
Original file line number Diff line number Diff line change
@@ -1,2 +1,4 @@
# frozen_string_literal: true

require "kdump/clients/finish"
::Y2Kdump::Clients::Finish.run
11 changes: 6 additions & 5 deletions src/clients/kdump_proposal.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# encoding: utf-8
# frozen_string_literal: true

# ------------------------------------------------------------------------------
# Copyright (c) 2008 Novell, Inc. All Rights Reserved.
Expand Down Expand Up @@ -39,7 +39,8 @@ def main
@param = Convert.to_map(WFM.Args(1))
@ret = {}

if @func == "MakeProposal"
case @func
when "MakeProposal"
Kdump.Propose

@ret = {
Expand All @@ -57,7 +58,7 @@ def main
}

@ret.merge!(Kdump.proposal_warning)
elsif @func == "AskUser"
when "AskUser"
@has_next = Ops.get_boolean(@param, "has_next", false)
@settings = Kdump.Export
Kdump.modified = false
Expand All @@ -77,15 +78,15 @@ def main
# Kdump::CheckPackages();
# Fill return map
@ret = { "workflow_sequence" => @result }
elsif @func == "Description"
when "Description"
@ret = {
# proposal part - kdump label
"rich_text_title" => _("Kdump"),
# menubutton entry
"menu_title" => _("&Kdump"),
"id" => "kdump_stuff"
}
elsif @func == "Write"
when "Write"
# Write is called in finish script (kdump_finish.ycp)
# it is necessary do it after bootloader write his settings
# boolean succ = Kdump::Write ();
Expand Down
7 changes: 3 additions & 4 deletions src/include/kdump/complex.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# encoding: utf-8
# frozen_string_literal: true

# ------------------------------------------------------------------------------
# Copyright (c) 2006 Novell, Inc. All Rights Reserved.
Expand Down Expand Up @@ -83,9 +83,8 @@ def ReadDialog
Wizard.RestoreHelp(Ops.get_string(@HELPS, "read", ""))
# Kdump::AbortFunction = PollAbort;
return :abort if !Confirm.MustBeRoot
if !Kdump.system.supports_kdump? && !unsupported_kdump_confirmation
return :abort
end
return :abort if !Kdump.system.supports_kdump? && !unsupported_kdump_confirmation

InstallPackages() or return :abort

ret = Kdump.Read
Expand Down
2 changes: 1 addition & 1 deletion src/include/kdump/dialogs.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# encoding: utf-8
# frozen_string_literal: true

# ------------------------------------------------------------------------------
# Copyright (c) 2006 Novell, Inc. All Rights Reserved.
Expand Down
124 changes: 62 additions & 62 deletions src/include/kdump/helps.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# encoding: utf-8
# frozen_string_literal: true

# ------------------------------------------------------------------------------
# Copyright (c) 2006 Novell, Inc. All Rights Reserved.
Expand Down Expand Up @@ -35,8 +35,8 @@ def initialize_kdump_helps(_include_target)
# Enable/Disable Kdump - RadioButtons 1/1
"StartRadioBut" => _(
"<p><b>Enable/Disable Kdump</b><br>\n" \
" Enable or disable kdump. The \"crashkernel\" boot parameter is added/removed. \n" \
" To apply changes, a reboot is necessary.<br></p>\n"
" Enable or disable kdump. The \"crashkernel\" boot parameter is added/removed. \n" \
" To apply changes, a reboot is necessary.<br></p>\n"
),
# Kdump Memor&y [MB] - IntField 1/1
"KdumpMemory" => _(
Expand All @@ -55,29 +55,29 @@ def initialize_kdump_helps(_include_target)
# T: help text for a combo box
# description taken from http://lparbox.com/how-to/aix/19
"<p><b>Firmware-Assisted Dump</b><br>\n" \
" Dumps are not generated before the partition is reinitialized but take place " \
" when the partition is restarting. When performing a firmware-assisted dump, " \
" system memory is frozen and the partition rebooted, which allows a new instance " \
" of the operating system to dump data from the previous kernel crash." \
" This feature is suitable only when the system has more than 1.5 GB of memory.</p>"
" Dumps are not generated before the partition is reinitialized but take place " \
" when the partition is restarting. When performing a firmware-assisted dump, " \
" system memory is frozen and the partition rebooted, which allows a new instance " \
" of the operating system to dump data from the previous kernel crash." \
" This feature is suitable only when the system has more than 1.5 GB of memory.</p>"
),
# Kdump Memor&y [MB] - IntField 1/1
"DumpLevel" => _(
"<p><b>Dump Level</b><br>\n" \
" Specify the type of necessary page for analysis.\n" \
" Pages of the specified type are copied to the dumpfile. \n" \
" The page type marked in the following table is included. <br></p>"
" Specify the type of necessary page for analysis.\n" \
" Pages of the specified type are copied to the dumpfile. \n" \
" The page type marked in the following table is included. <br></p>"
),
# Dump Format - RadioButtons 1/1
"DumpFormat" => _(
"<p><b>Dump Format</b><br>\n" \
" <i>No Dump</i> - Only save the kernel log.<br>\n" \
" <i>ELF Format</i> - Create dump file in ELF format.<br>\n" \
" <i>Compressed Format</i> - Compress dump data by each page with gzip.<br>\n" \
" <i>LZO Compressed Format</i> - Slightly bigger files but much faster.<br>\n</p>" \
" <i>Snappy Compressed Format</i> - Considerably faster, 64-bit optimized.<br>\n</p>" \
" <i>Zstandard Compressed Format</i> - Smaller files, slower.<br>\n</p>" \
" <i>Raw copy of /proc/vmcore</i> - does not use makedumpfile.<br>\n</p>"
" <i>No Dump</i> - Only save the kernel log.<br>\n" \
" <i>ELF Format</i> - Create dump file in ELF format.<br>\n" \
" <i>Compressed Format</i> - Compress dump data by each page with gzip.<br>\n" \
" <i>LZO Compressed Format</i> - Slightly bigger files but much faster.<br>\n</p>" \
" <i>Snappy Compressed Format</i> - Considerably faster, 64-bit optimized.<br>\n</p>" \
" <i>Zstandard Compressed Format</i> - Smaller files, slower.<br>\n</p>" \
" <i>Raw copy of /proc/vmcore</i> - does not use makedumpfile.<br>\n</p>"
),
# Dump Format - RadioButtons 1/7
"TargetKdump" => _(
Expand All @@ -86,36 +86,36 @@ def initialize_kdump_helps(_include_target)
# Dump Format - RadioButtons 2/7
_(
"<p><b>Local Filesystem</b> - Save the kdump image in the local filesystem.\n" \
" <i>Directory for Saving Dumps</i> - The path for saving kdump images.\n" \
" Selecting directory for saving kdump images via dialog by pressing <i>Browse</i>\n" \
" <br></p>"
" <i>Directory for Saving Dumps</i> - The path for saving kdump images.\n" \
" Selecting directory for saving kdump images via dialog by pressing <i>Browse</i>\n" \
" <br></p>"
) +
# Dump Format - RadioButtons 3/7
_(
"<p><b>FTP</b> - Save kdump image via FTP.\n" \
" <i>Server Name</i> - The name of the ftp server.\n" \
" <i>Port</i> - The port number for the connection.\n" \
" <i>Directory on Server</i> - The path for saving kdump images.\n" \
" <i>Enable Anonymous FTP</i> enables anonymous connection to the server.\n" \
" <i>User Name</i> for ftp connection. <i>Password</i> for ftp connection.<br></p>"
" <i>Server Name</i> - The name of the ftp server.\n" \
" <i>Port</i> - The port number for the connection.\n" \
" <i>Directory on Server</i> - The path for saving kdump images.\n" \
" <i>Enable Anonymous FTP</i> enables anonymous connection to the server.\n" \
" <i>User Name</i> for ftp connection. <i>Password</i> for ftp connection.<br></p>"
) +
# Dump Format - RadioButtons 4/7
_(
"<p><b>SSH</b> - Save kdump image via SSH and 'dd' on target machine.\n" \
" <i>Server Name</i> - The name of the server.\n" \
" <i>Port</i> - The port number for the connection.\n" \
" <i>Directory on Server</i> - The path for saving kdump images.\n" \
" <i>User Name</i> for SSH connection. \n" \
" <i>Password</i> for SSH connection.<br></p>\n"
" <i>Server Name</i> - The name of the server.\n" \
" <i>Port</i> - The port number for the connection.\n" \
" <i>Directory on Server</i> - The path for saving kdump images.\n" \
" <i>User Name</i> for SSH connection. \n" \
" <i>Password</i> for SSH connection.<br></p>\n"
) +
# Dump Format - RadioButtons 5/7
_(
"<p><b>SFTP</b> - Save kdump image via SFTP.\n" \
" <i>Server Name</i> - The name of the server.\n" \
" <i>Port</i> - The port number for the connection.\n" \
" <i>Directory on Server</i> - The path for saving kdump images.\n" \
" <i>User Name</i> for SSH connection. \n" \
" <i>Password</i> for SSH connection.<br></p>\n"
" <i>Server Name</i> - The name of the server.\n" \
" <i>Port</i> - The port number for the connection.\n" \
" <i>Directory on Server</i> - The path for saving kdump images.\n" \
" <i>User Name</i> for SSH connection. \n" \
" <i>Password</i> for SSH connection.<br></p>\n"
) +
_(
"<p>The choice between SSH and SFTP depends\n" \
Expand All @@ -125,23 +125,23 @@ def initialize_kdump_helps(_include_target)
# Dump Format - RadioButtons 6/7
_(
"<p><b>NFS</b> - Save kdump image on NFS.\n" \
" <i>Server Name</i> - The name of the nfs server.\n" \
" <i>Directory on Server</i> - The path for saving kdump images.<br></p>"
" <i>Server Name</i> - The name of the nfs server.\n" \
" <i>Directory on Server</i> - The path for saving kdump images.<br></p>"
) +
# Dump Format - RadioButtons 7/7
_(
"<p><b>CIFS</b> - Save kdump image via CIFS.\n" \
" <i>Server Name</i> - The name of the server.\n" \
" <i>Exported Share</i> - The windows share name.\n" \
" <i>Directory on Server</i> - The path for saving kdump images.\n" \
" <i>Use Authentication</i> enables authenticated connection to the server.\n" \
" <i>User Name</i> for the connection. <i>Password</i> for the connection.<br></p>"
" <i>Server Name</i> - The name of the server.\n" \
" <i>Exported Share</i> - The windows share name.\n" \
" <i>Directory on Server</i> - The path for saving kdump images.\n" \
" <i>Use Authentication</i> enables authenticated connection to the server.\n" \
" <i>User Name</i> for the connection. <i>Password</i> for the connection.<br></p>"
),
# Custom Kdump Kernel - TextEntry 1/1
"InitrdKernel" => _(
"<p><b>Custom Kdump Kernel</b> The user can enter the custom kernel.\n" \
" The naming scheme is:<i>/boot/vmlinu[zx]-<kernel_string>[.gz]</i>\n" \
" Please enter only <i>kernel_string</i>.<br></p>"
" The naming scheme is:<i>/boot/vmlinu[zx]-<kernel_string>[.gz]</i>\n" \
" Please enter only <i>kernel_string</i>.<br></p>"
),
# Kdump Command Line - TextEntry 1/1
"KdumpCommandLine" => _(
Expand All @@ -150,9 +150,9 @@ def initialize_kdump_helps(_include_target)
# Kdump Command Line Append - TextEntry 1/1
"KdumpCommandLineAppend" => _(
"<p><b>Kdump Command Line Append</b>\n" \
" Set this option to _append_ values to the default command line string. \n" \
" The string will be appended if the <i>Kdump Command Line</i>\n" \
" is set. <br></p>\n"
" Set this option to _append_ values to the default command line string. \n" \
" The string will be appended if the <i>Kdump Command Line</i>\n" \
" is set. <br></p>\n"
),
# Enable Immediate Reboot After Saving the Core - CheckBox 1/1
"EnableReboot" => _(
Expand All @@ -161,8 +161,8 @@ def initialize_kdump_helps(_include_target)
# Enable Delete Old Dump Images - CheckBox 1/1
"EnableDeleteImages" => _(
"<p><b>Enable Delete Old Dump Images</b> - \n" \
" Enable Delete Old Dump Images. If the number of dump files in \n" \
" <i>Number of Old Dumps</i> exceeds this number, older dumps are removed.<br></p>"
" Enable Delete Old Dump Images. If the number of dump files in \n" \
" <i>Number of Old Dumps</i> exceeds this number, older dumps are removed.<br></p>"
),
# SMTP Server
"SMTPServer" => _(
Expand Down Expand Up @@ -203,9 +203,9 @@ def initialize_kdump_helps(_include_target)
# Write dialog help 2/2
_(
"<p><b><big>Aborting Saving:</big></b><br>\n" \
"Abort the save procedure by pressing <b>Abort</b>.\n" \
"An additional dialog informs whether it is safe to do so.\n" \
"</p>\n"
"Abort the save procedure by pressing <b>Abort</b>.\n" \
"An additional dialog informs whether it is safe to do so.\n" \
"</p>\n"
),
# Summary dialog help 1/3
"summary" => _(
Expand All @@ -214,21 +214,21 @@ def initialize_kdump_helps(_include_target)
# Summary dialog help 2/3
_(
"<p><b><big>Adding a Kdump:</big></b><br>\n" \
"Choose an kdump from the list of detected kdumps.\n" \
"If your kdump was not detected, select <b>Other (not detected)</b>.\n" \
"Then press <b>Configure</b>.</p>\n"
"Choose an kdump from the list of detected kdumps.\n" \
"If your kdump was not detected, select <b>Other (not detected)</b>.\n" \
"Then press <b>Configure</b>.</p>\n"
) +
# Summary dialog help 3/3
_(
"<p><b><big>Editing or Deleting:</big></b><br>\n" \
"If you press <b>Edit</b>, an additional dialog in which to change\n" \
"the configuration opens.</p>\n"
"If you press <b>Edit</b>, an additional dialog in which to change\n" \
"the configuration opens.</p>\n"
),
# Ovreview dialog help 1/3
"overview" => _(
"<p><b><big>Kdump Configuration Overview</big></b><br>\n" \
"Obtain an overview of installed kdumps. Additionally\n" \
"edit their configurations.<br></p>\n"
"Obtain an overview of installed kdumps. Additionally\n" \
"edit their configurations.<br></p>\n"
) +
# Ovreview dialog help 2/3
_(
Expand All @@ -237,8 +237,8 @@ def initialize_kdump_helps(_include_target)
# Ovreview dialog help 3/3
_(
"<p><b><big>Editing or Deleting:</big></b><br>\n" \
"Choose a kdump to change or remove.\n" \
"Then press <b>Edit</b> or <b>Delete</b> as desired.</p>\n"
"Choose a kdump to change or remove.\n" \
"Then press <b>Edit</b> or <b>Delete</b> as desired.</p>\n"
)
}
end
Expand Down
Loading
Loading