Created
January 4, 2019 16:16
-
-
Save ableasdale/84c370bb3fb8a985a1660bbae868180a to your computer and use it in GitHub Desktop.
Linux: Disabling Transparent Huge Pages using grubby
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
if [[ $EUID -ne 0 ]]; then | |
echo "This script must be run as root" 1>&2 | |
exit 1 | |
fi | |
for KERNEL in /boot/vmlinuz-*; do | |
grubby --update-kernel="$KERNEL" --args='transparent_hugepage=never' | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You should also be able to update multiple kernels by running something like this:
grubby --update-kernel=ALL --args="transparent_hugepage=never"