Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Leap:42.2:Ports
kdump
kdump-remove-vm-sysctl.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File kdump-remove-vm-sysctl.patch of Package kdump
From: Petr Tesarik <ptesarik@suse.com> Subject: Remove vm. sysctls from kdump initrd References: bsc#927451, bsc#987862 Patch-mainline: v0.8.16 Git-commit: 52fcf6338bfb4e029d96303d4840e995e9da2cc9 Custom sysctl VM settings in the primary system may cause unreasonable run-time memory requirements in the kdump environment. Remove such custom sysctl settings from kdump initrd. Signed-off-by: Petr Tesarik <ptesarik@suse.com> --- init/setup-kdump.functions | 33 ++++++++++++++++++++++++++++++++- 1 file changed, 32 insertions(+), 1 deletion(-) --- a/init/setup-kdump.functions +++ b/init/setup-kdump.functions @@ -706,7 +706,33 @@ function kdump_init_dirs() # {{{ done test -e "${root}/kdump/boot" || ln -snf "root/boot" "${root}/kdump/boot" -} +} # }}} + +# +# Filter out problematic sysctl settings +# Parameters: +# 1) root: initrd temporary root +function kdump_filter_sysctl() # {{{ +{ + local root="$1" + + local restoreopt=$( shopt -p nullglob ) + shopt -s nullglob + + for f in \ + "$root"/boot/sysctl.conf-* \ + "$root"/run/sysctl.d/*.conf \ + "$root"/etc/sysctl.d/*.conf \ + "$root"/usr/local/lib/sysctl.d/*.conf \ + "$root"/usr/lib/sysctl.d/*.conf \ + "$root"/lib/sysctl.d/*.conf \ + "$root"/etc/sysctl.conf + do + sed -i -e '/^[ \t]*vm\./d' "$f" + done + + eval "$restoreopt" +} # }}} # # Set up or create all necessary files @@ -753,5 +779,10 @@ function kdump_setup_files() # { # kdump_modify_multipath "$mpathdevs" > "${outdir}/etc/multipath.conf" + # + # filter out problematic sysctl settings + # + kdump_filter_sysctl "$outdir" + return 0 } # }}}
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor