Go to file
Dusty Mabe f9c32372d2 kdump-lib: attempt to fix BOOT_IMAGE detection
Currently $boot_img can get bad data if running on a platform
that doesn't set BOOT_IMAGE in the kernel command line. For
example, currently:

- s390x Fedora CoreOS machine:

```
[root@cosa-devsh ~]# sed "s/^BOOT_IMAGE=\((\S*)\)\?\(\S*\) .*/\2/" /proc/cmdline
mitigations=auto,nosmt ignition.platform.id=qemu ostree=/ostree/boot.0/fedora-coreos/2a72567ac8f7ed678c3ac89408f795e6ccd4e97b41e14af5f471b6a807e858b9/0 root=UUID=2a88436a-3b6b-4706-b33a-b8270bd87cde rw rootflags=prjquota boot=UUID=f4b2eaa5-9317-4798-85cf-308c477fee4c crashkernel=600M
```

where on a platform that uses GRUB we get:

- x86_64 Fedora CoreOS machine:

```
[root@cosa-devsh ~]# sed "s/^BOOT_IMAGE=\((\S*)\)\?\(\S*\) .*/\2/" /proc/cmdline
/ostree/fedora-coreos-af4f6cc7b9ff486cfa647680b180e989c72c8eed03a34a42e7328e49332bd20e/vmlinuz-5.18.5-200.fc36.x86_64
```

We should change the setting of the boot_img variable such that it will
be empty if BOOT_IMAGE doesn't exist.

With this change on the s390x machine:

```
[root@cosa-devsh ~]# grep -P -o '^BOOT_IMAGE=(\S+)' /proc/cmdline | sed "s/^BOOT_IMAGE=\((\S*)\)\?\(\S*\)/\2/"
[root@cosa-devsh ~]#
```

This change mattered much more before the change in c5bdd2d which changed
the following line from [[ -n $boot_img ]] to [[ "$boot_img" == *"$kdump_kernelver" ]].
Still I think this change has merit.

Signed-off-by: Dusty Mabe <dusty@dustymabe.com>
Acked-by: Coiby Xu <coxu@redhat.com>
2022-06-30 16:00:06 +08:00
spec unit tests: add tests for get_system_size and get_recommend_size 2022-05-13 11:03:22 +08:00
tests selftest: Add early kdump test 2022-01-24 11:18:00 +08:00
.editorconfig kdump-lib-initramfs.sh: prepare to be a POSIX compatible lib 2021-09-14 03:25:46 +08:00
.gitignore unit tests: prepare for kdumpctl and kdump-lib.sh to be unit-tested 2022-04-14 11:44:12 +08:00
.shellspec unit tests: add tests for get_grub_kernel_boot_parameter 2022-04-14 11:44:27 +08:00
60-kdump.install Write to /var/lib/kdump if $KDUMP_BOOTDIR not writable 2021-04-19 16:11:17 +08:00
92-crashkernel.install reset kernel crashkernel for the special case where the kernel is updated right after kexec-tools 2022-01-05 09:40:24 +08:00
98-kexec.rules
98-kexec.rules.ppc64 Stop reloading kdump service on CPU hotplug event for FADump 2021-03-10 16:24:42 +08:00
crashkernel-howto.txt remove the upper bound of default crashkernel value example 2022-04-24 09:35:05 +08:00
dracut-early-kdump-module-setup.sh dracut-early-kdump-module-setup.sh: install xargs and kdump-lib-initramfs.sh 2021-12-27 09:16:19 +08:00
dracut-early-kdump.sh dracut-early-kdump.sh: make it POSIX compatible 2021-09-15 23:11:37 +08:00
dracut-fadump-init-fadump.sh fadump-init: clean up mount points properly 2021-06-30 17:28:45 +08:00
dracut-fadump-module-setup.sh fadump: isolate fadump initramfs image within the default one 2021-06-29 21:35:58 +08:00
dracut-kdump-capture.service kdump-capture.service: switch to journal for stdout 2022-04-02 16:24:32 +08:00
dracut-kdump-emergency.service Merge kdump-error-handler.sh into kdump.sh 2021-09-14 03:25:54 +08:00
dracut-kdump-emergency.target
dracut-kdump.sh logger: save log after all kdump progress finished 2022-04-29 16:22:41 +08:00
dracut-module-setup.sh ppc64/ppc64le: drop cpu online rule in 40-redhat.rules in kdump initramfs 2021-12-23 15:40:23 +08:00
dracut-monitor_dd_progress
early-kdump-howto.txt
fadump-howto.txt update fadump-howto 2022-04-24 09:35:05 +08:00
kdump-dep-generator.sh logger: source the logger file individually 2021-01-20 14:13:44 +08:00
kdump-in-cluster-environment.txt
kdump-lib-initramfs.sh kdump-lib-initramfs: merge definitions for default ssh key 2022-04-02 16:24:32 +08:00
kdump-lib.sh kdump-lib: attempt to fix BOOT_IMAGE detection 2022-06-30 16:00:06 +08:00
kdump-logger.sh Add header comment for POSIX compliant scripts 2021-09-15 23:11:37 +08:00
kdump-migrate-action.sh kdump/ppc64: rebuild initramfs image after migration 2021-07-21 10:53:59 +08:00
kdump-restart.sh kdump/ppc64: rebuild initramfs image after migration 2021-07-21 10:53:59 +08:00
kdump-udev-throttler
kdump.conf introduce the auto_reset_crashkernel option to kdump.conf 2022-01-05 09:40:24 +08:00
kdump.conf.5 introduce the auto_reset_crashkernel option to kdump.conf 2022-01-05 09:40:24 +08:00
kdump.service
kdump.sysconfig kdump.sysconfig*: add ignition.firstboot to KDUMP_COMMANDLINE_REMOVE 2022-05-16 14:04:12 -04:00
kdump.sysconfig.aarch64 kdump.sysconfig*: add ignition.firstboot to KDUMP_COMMANDLINE_REMOVE 2022-05-16 14:04:12 -04:00
kdump.sysconfig.i386 kdump.sysconfig*: add ignition.firstboot to KDUMP_COMMANDLINE_REMOVE 2022-05-16 14:04:12 -04:00
kdump.sysconfig.ppc64 kdump.sysconfig*: add ignition.firstboot to KDUMP_COMMANDLINE_REMOVE 2022-05-16 14:04:12 -04:00
kdump.sysconfig.ppc64le kdump.sysconfig*: add ignition.firstboot to KDUMP_COMMANDLINE_REMOVE 2022-05-16 14:04:12 -04:00
kdump.sysconfig.s390x kdump.sysconfig*: add ignition.firstboot to KDUMP_COMMANDLINE_REMOVE 2022-05-16 14:04:12 -04:00
kdump.sysconfig.x86_64 kdump.sysconfig*: add ignition.firstboot to KDUMP_COMMANDLINE_REMOVE 2022-05-16 14:04:12 -04:00
kdumpctl kdump-lib: clear up references to Atomic/CoreOS 2022-06-30 16:00:06 +08:00
kdumpctl.8 add man documentation for kdumpctl get-default-crashkernel 2022-04-24 09:35:05 +08:00
kexec-kdump-howto.txt update kexec-kdump-howto 2022-04-24 09:35:05 +08:00
kexec-tools-2.0.23-s390_handle_R_390_PLT32DBL_reloc_entries_in_machine_apply_elf_rel_.patch s390: handle R_390_PLT32DBL reloc entries in machine_apply_elf_rel() 2022-01-26 08:25:43 +08:00
kexec-tools.spec Release 2.0.24-3 2022-05-23 18:26:42 +08:00
live-image-kdump-howto.txt
mkdumprd kdump-lib-initramfs: merge definitions for default ssh key 2022-04-02 16:24:32 +08:00
mkdumprd.8 Doc: improve mkdumprd man page 2020-12-11 14:05:08 +08:00
mkfadumprd Set zstd as recommented for kexec-tools 2022-01-11 10:11:21 +08:00
README
sources Update makedumpfile to 1.7.1 2022-05-23 18:26:42 +08:00
zanata-notes.txt

Adding a patch to kexec-tools
=============================
There is a mailing list kexec@lists.fedoraproject.org where all the dicussion
related to fedora kexec-tools happen. All the patches are posted there for
inclusion and committed to kexec-tools after review.

So if you want your patches to be included in fedora kexec-tools package,
post these to kexec@lists.fedoraproject.org.

One can subscribe to list and browse through archives here.

https://admin.fedoraproject.org/mailman/listinfo/kexec