From ca84f73cee7d98d3a0074a5f8f9918bbbd0640ed Mon Sep 17 00:00:00 2001 From: Kairui Song Date: Wed, 21 Jul 2021 02:09:21 +0800 Subject: [PATCH] Update to latest git snapshot and apply RHEL only changes Update to support new `crashkernel.default` kernel file, add support for encrypted device detection. Also apply RHEL only patch which enable kdump by default. Resolves: bz1937035, bz1959203 Signed-off-by: Kairui Song --- .gitignore | 1 + 0001.patch | 26 ++++++++++++++++++++++++++ 0002.patch | 29 +++++++++++++++++++++++++++++ kdump-anaconda-addon.spec | 17 ++++++++++++----- sources | 2 +- 5 files changed, 69 insertions(+), 6 deletions(-) create mode 100644 0001.patch create mode 100644 0002.patch diff --git a/.gitignore b/.gitignore index 90e4700..c5e27b6 100644 --- a/.gitignore +++ b/.gitignore @@ -5,3 +5,4 @@ /kdump-anaconda-addon-122ccd9.tar.gz /kdump-anaconda-addon-80aab11.tar.gz /kdump-anaconda-addon-4ba507e.tar.gz +/kdump-anaconda-addon-d046d22.tar.gz diff --git a/0001.patch b/0001.patch new file mode 100644 index 0000000..aeb51d3 --- /dev/null +++ b/0001.patch @@ -0,0 +1,26 @@ +From 6bb1782569693efb637cb166e307e2e4cd5ee6fd Mon Sep 17 00:00:00 2001 +From: Kairui Song +Date: Wed, 21 Jul 2021 02:06:36 +0800 +Subject: [PATCH 1/2] Enable kdump by default + +Signed-off-by: Kairui Song +--- + com_redhat_kdump/service/kdump.py | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/com_redhat_kdump/service/kdump.py b/com_redhat_kdump/service/kdump.py +index 46e7242..4f4cdd1 100755 +--- a/com_redhat_kdump/service/kdump.py ++++ b/com_redhat_kdump/service/kdump.py +@@ -41,7 +41,7 @@ class KdumpService(KickstartService): + def __init__(self): + """Create a service.""" + super().__init__() +- self._kdump_enabled = False ++ self._kdump_enabled = True + self.kdump_enabled_changed = Signal() + + self._fadump_enabled = False +-- +2.31.1 + diff --git a/0002.patch b/0002.patch new file mode 100644 index 0000000..1b62a14 --- /dev/null +++ b/0002.patch @@ -0,0 +1,29 @@ +From 5dbcac32ba9c5d5c3cdfc8ea303f81e9af4f728a Mon Sep 17 00:00:00 2001 +From: Kairui Song +Date: Wed, 2 Jun 2021 16:44:08 +0800 +Subject: [PATCH 2/2] Make kdump options visible by default + +Currently this addon is completely hidden unless kdump_addon=on +is set, make it visible by default. Kdump is still disabled by default, +just show the kdump tab. + +Signed-off-by: Kairui Song +--- + com_redhat_kdump/service/initialization.py | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/com_redhat_kdump/service/initialization.py b/com_redhat_kdump/service/initialization.py +index 2bdbe6e..998fca6 100644 +--- a/com_redhat_kdump/service/initialization.py ++++ b/com_redhat_kdump/service/initialization.py +@@ -27,6 +27,6 @@ __all__ = ["check_initial_conditions"] + + def check_initial_conditions(): + """Can the Kdump service run?""" +- if not kernel_arguments.is_enabled("kdump_addon"): ++ if not kernel_arguments.get("kdump_addon", 1): + log.debug("The kdump add-on is disabled. Quit.") + sys.exit(1) +-- +2.31.1 + diff --git a/kdump-anaconda-addon.spec b/kdump-anaconda-addon.spec index 4a896b9..0ae9f67 100644 --- a/kdump-anaconda-addon.spec +++ b/kdump-anaconda-addon.spec @@ -1,16 +1,16 @@ -%global gitcommit 4ba507e27a209a36589191f2fa28fc9983cf57f8 +%global gitcommit d046d22af07c2613417ce31c27952f771c12922b %global gitshortcommit %(c=%{gitcommit}; echo ${c:0:7}) -%global snapshotdate 20201128 +%global snapshotdate 20210721 Name: kdump-anaconda-addon Version: 006 -Release: 3.%{snapshotdate}git%{gitshortcommit}%{?dist} +Release: 4.%{snapshotdate}git%{gitshortcommit}%{?dist} Url: https://github.com/daveyoung/kdump-anaconda-addon License: GPLv2 Summary: Kdump configuration anaconda addon BuildArch: noarch -Requires: anaconda >= 34.13 +Requires: anaconda >= 34.25 Requires: hicolor-icon-theme BuildRequires: intltool gettext BuildRequires: make @@ -19,11 +19,14 @@ Provides: kexec-tools-anaconda-addon = %{version}-%{release} Source0: https://github.com/daveyoung/kdump-anaconda-addon/archive/%{gitcommit}/kdump-anaconda-addon-%{gitshortcommit}.tar.gz +Patch1: 0001.patch +Patch2: 0002.patch + %description Kdump anaconda addon %prep -%autosetup -n %{name}-%{gitcommit} +%autosetup -n %{name}-%{gitcommit} -p1 %build @@ -41,6 +44,10 @@ Kdump anaconda addon %{_datadir}/icons/hicolor/scalable/apps/kdump.svg %changelog +* Wed Jul 21 2021 Kairui Song - 006-4.20210721gitd046d22 +- Update to latest git snapshot (20210721). Resolves: bz1937035, bz1959203 +- Apply RHEL only patch to enable kdump by default + * Fri Apr 16 2021 Mohan Boddu - 006-3.20201128git4ba507e - Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937 diff --git a/sources b/sources index 5fc4860..d4e9a3c 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (kdump-anaconda-addon-4ba507e.tar.gz) = 13833ef3188bd3d476871416ceeabd9dfa70dd83e7d4914e2b128639a72d663531b77b85aab85b7a5ac148758e910df57003598b683985f83139b62e8c964c08 +SHA512 (kdump-anaconda-addon-d046d22.tar.gz) = 636d758c8e9d5069b19c43480c638ec85d416b6b96329d79b290e7d5c41e91b3275baba38291854bae61d3eaca0f85a803d3d408b4f0de315aab4256392c99ba