updated on Sun Jan 15 00:02:00 UTC 2012
[aur-mirror.git] / grub2-efi-ubuntu / ubuntu_crashkernel.patch
blob0151617e65417cad04a8c3542b7545ca22dfea7f
1 Description: Add crashkernel option
2 Add crashkernel= option if kdump and makedumpfile are available. See
3 https://blueprints.launchpad.net/ubuntu/+spec/foundations-karmic-linux-kernel-crash-dump.
5 This requires several fairly distribution-specific pieces to work properly.
6 Author: Michael Vogt <michael.vogt@ubuntu.com>
7 Forwarded: not-needed
8 Last-Update: 2011-01-05
10 Index: b/util/grub.d/10_linux.in
11 ===================================================================
12 --- a/util/grub.d/10_linux.in
13 +++ b/util/grub.d/10_linux.in
14 @@ -65,6 +65,11 @@
18 +# add crashkernel option if we have the required tools
19 +if [ -x "/usr/bin/makedumpfile" ] && [ -x "/sbin/kexec" ]; then
20 + GRUB_CMDLINE_EXTRA="$GRUB_CMDLINE_EXTRA crashkernel=384M-2G:64M,2G-:128M"
21 +fi
23 linux_entry ()
25 os="$1"
26 @@ -185,7 +190,7 @@
29 linux_entry "${OS}" "${version}" false \
30 - "${GRUB_CMDLINE_LINUX} ${GRUB_CMDLINE_LINUX_DEFAULT}"
31 + "${GRUB_CMDLINE_LINUX} ${GRUB_CMDLINE_EXTRA} ${GRUB_CMDLINE_LINUX_DEFAULT}"
32 if [ "x${GRUB_DISABLE_RECOVERY}" != "xtrue" ]; then
33 linux_entry "${OS}" "${version}" true \
34 "single ${GRUB_CMDLINE_LINUX}"