Last active
February 14, 2023 16:08
-
-
Save cherts/be1e7551cca7b873a73b697e3fa951e4 to your computer and use it in GitHub Desktop.
Disable transparent huge page via systemd in Ubuntu/Debian
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
| [Unit] | |
| Description=Disable Transparent Huge Pages | |
| Documentation=https://access.redhat.com/solutions/46111 | |
| [Service] | |
| Type=oneshot | |
| ExecStart=/bin/sh -c "/usr/bin/echo "never" | tee /sys/kernel/mm/transparent_hugepage/enabled" | |
| ExecStart=/bin/sh -c "/usr/bin/echo "never" | tee /sys/kernel/mm/transparent_hugepage/defrag" | |
| [Install] | |
| WantedBy=multi-user.target |
cherts
commented
Feb 14, 2023
Author
Author
Check THP usage:
grep AnonHugePages /proc/meminfo
egrep 'trans|thp' /proc/vmstat
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment