kdump/ppc64: migration action registration clean up

resolves: bz2027568
upstream: fedora
conflict: None-functional conflict in spec file.

commit 146f662622
Author: Hari Bathini <hbathini@linux.ibm.com>
Date:   Tue Jul 27 23:59:48 2021 +0530

    kdump/ppc64: migration action registration clean up

    While kdump migration action is registered for LPM event, ensure it is
    cleared as appropriate to avoid duplicate/stale notification entries.

    Signed-off-by: Hari Bathini <hbathini@linux.ibm.com>
    Acked-by: Kairui Song <kasong@redhat.com>

Signed-off-by: Tao Liu <ltao@redhat.com>
This commit is contained in:
Tao Liu 2021-12-03 18:14:03 +08:00
parent de65197ba0
commit ec53fb983d

View File

@ -271,11 +271,10 @@ mv $RPM_BUILD_ROOT/etc/kdump-adv-conf/kdump_dracut_modules/* $RPM_BUILD_ROOT/%{d
touch /etc/kdump.conf touch /etc/kdump.conf
ARCH=`uname -m` %ifarch ppc64 ppc64le
if [ "$ARCH" == "ppc64" ] || [ "$ARCH" == "ppc64le" ] servicelog_notify --remove --command=/usr/lib/kdump/kdump-migrate-action.sh
then
servicelog_notify --add --command=/usr/lib/kdump/kdump-migrate-action.sh --match='refcode="#MIGRATE" and serviceable=0' --type=EVENT --method=pairs_stdin servicelog_notify --add --command=/usr/lib/kdump/kdump-migrate-action.sh --match='refcode="#MIGRATE" and serviceable=0' --type=EVENT --method=pairs_stdin
fi %endif
# This portion of the script is temporary. Its only here # This portion of the script is temporary. Its only here
# to fix up broken boxes that require special settings # to fix up broken boxes that require special settings
@ -305,6 +304,9 @@ fi
%preun %preun
# Package removal, not upgrade # Package removal, not upgrade
%ifarch ppc64 ppc64le
servicelog_notify --remove --command=/usr/lib/kdump/kdump-migrate-action.sh
%endif
%systemd_preun kdump.service %systemd_preun kdump.service
%triggerun -- kexec-tools < 2.0.2-3 %triggerun -- kexec-tools < 2.0.2-3