mirror of
https://github.com/ibm-s390-linux/s390-tools.git
synced 2026-08-05 02:14:52 +00:00
This prevents out-of-memory (OOM) situations in the kdump crashkernel environment. Please note that the new dracut module 95zdev-kdump and the new library zdev-lib.sh need to be packaged into the same (core) (sub)package as 95zdev. This patch introduces a new dracut module "zdev-kdump", which is used instead of module "zdev" when building a kdump initrd: 1. Ignore all persistently configured block devices and disable zfcp auto LUN scanning => minimize the number of SCSI devices enabled during kdump. 2. Do not rely on chzdev's persistent configuration => work with systems that do not use chzdev for persistent device configuration. The detection of kdump is based on strict hostonly mode and on $IN_KDUMP. See also https://src.fedoraproject.org/rpms/kexec-tools commit 4eedcae5e154 ("dracut-module-setup.sh: don't include multipath-hostonly") and https://github.com/dracutdevs/dracut commits 35e86ac117ac ("Merge 90-multipath-hostonly and 90-multipath") a695250ec7db ("Introduce tri-state hostonly mode") and https://src.fedoraproject.org/rpms/kexec-tools/blob/rawhide/f/mkdumprd#_17 https://src.fedoraproject.org/rpms/kexec-tools/blob/rawhide/f/dracut-module-setup.sh#_23. The detection of kdump is also based on kdump_needed() in https://github.com/openSUSE/kdump/blob/master/dracut/module-setup.sh. Reviewed-by: Peter Oberparleiter <oberpar@linux.ibm.com> Signed-off-by: Steffen Maier <maier@linux.ibm.com> Signed-off-by: Jan Höppner <hoeppner@linux.ibm.com>
29 lines
941 B
Makefile
29 lines
941 B
Makefile
# Common definitions
|
|
include ../../common.mak
|
|
|
|
ZDEVDIR := 95zdev
|
|
ZDEVKDUMPDIR := 95zdev-kdump
|
|
|
|
# HAVE_DRACUT
|
|
#
|
|
# This install time parameter determines whether the zdev dracut module is
|
|
# installed (HAVE_DRACUT=1) or not (default). When installed, the module
|
|
# performs the following functions when dracut is run:
|
|
#
|
|
# - copy the persistent root device configuration to the initial ram disk
|
|
# - install a boot-time hook to apply firmware-provided configuration data
|
|
# to the system
|
|
#
|
|
ifeq ($(HAVE_DRACUT),1)
|
|
install:
|
|
$(INSTALL) -m 755 -d $(DESTDIR)$(DRACUTMODDIR)/
|
|
$(INSTALL) -m 755 -d $(DESTDIR)$(DRACUTMODDIR)/$(ZDEVDIR)
|
|
$(INSTALL) -m 755 $(ZDEVDIR)/module-setup.sh \
|
|
$(ZDEVDIR)/parse-zdev.sh \
|
|
$(ZDEVDIR)/zdev-lib.sh \
|
|
$(DESTDIR)$(DRACUTMODDIR)/$(ZDEVDIR)/
|
|
$(INSTALL) -m 755 -d $(DESTDIR)$(DRACUTMODDIR)/$(ZDEVKDUMPDIR)
|
|
$(INSTALL) -m 755 $(ZDEVKDUMPDIR)/module-setup.sh \
|
|
$(DESTDIR)$(DRACUTMODDIR)/$(ZDEVKDUMPDIR)/
|
|
endif
|