How to disable transparent hugepages (THP) on Red Hat Enterprise Linux 7
How to disable transparent hugepages (THP) on Red Hat Enterprise Linux 7
$ Solution 已验证 - 已更新2017年六月2日23:54 - English
环境
Red Hat Enterprise Linux 7
transparent hugepages (THP)
tuned
问题
How to disable transparent hugepages (THP) on Red Hat Enterprise Linux 7
Disabling transparent hugepages (THP) on Red Hat Enterprise Linux 7 is not taking effect.
决议
Follow the steps below
1.Add the "transparent_hugepage=never" kernel parameter option to the grub2 configuration file.
Append or change the "transparent_hugepage=never" kernel parameter
on the GRUB_CMDLINE_LINUX option in /etc/default/grub file. Only include the parameter once.
vim /etc/default/grub
GRUB_CMDLINE_LINUX="rd.lvm.lv=rhel/root rd.lvm.lv=rhel/swap ... transparent_hugepage=never"
2.Rebuild the /boot/grub2/grub.cfg file by running the grub2-mkconfig -o command as follows:
Please ensure to take a backup of the existing /boot/grub2/grub.cfg before rebuilding.
On BIOS-based machines: ~]# grub2-mkconfig -o /boot/grub2/grub.cfg
On UEFI-based machines: ~]# grub2-mkconfig -o /boot/efi/EFI/redhat/grub.cfg
3.Reboot the system and verify option has been added
Reboot the system
# shutdown -r now
Verify the parameter is set correctly
# cat /proc/cmdline
正确的,应该含 transparent_hugepage=never
If Transparent Huge Pages (THP) is still not disabled, continue and use one of the options below.
Option 1: (Recommended) create a customized tuned profile with disabled THP
With this resolution we will create a customized version of the currently running profile. The customized version will disable THP.
Find out which profile is active, create a copy.
In the following example we currently use the throughput-performance profile:
# tuned-adm active
Current active profile: throughput-performance
To create customized profile, create a new directory in /etc/tuned directory with desired profile name.
# mkdir /etc/tuned/myprofile-nothp
Then create a new tuned.conf file for myprofile-nothp, and insert the new tuning info:
# cat /etc/tuned/myprofile-nothp/tuned.conf
[main]
include= throughput-performance
[vm]
transparent_hugepages=never
Make the script executable:
# chmod +x /etc/tuned/myprofile-nothp/tuned.conf
Enable myprofile like so:
# tuned-adm profile myprofile-nothp
This change will immediately take effect and persist reboots.
To verify if THP are disabled or not, run below command:
# cat /sys/kernel/mm/transparent_hugepage/enabled
Option 2: (Alternative) Disable tuned services
This resolution will disable the tuned services.
# systemctl stop tuned
# systemctl disable tuned
或者
# tuned-adm off
Now add "transparent_hugepage=never" kernel parameter in grub2 configuration file as explained in steps 1-3 above.
Reboot the server for changes to take effect.
How to disable transparent hugepages (THP) on Red Hat Enterprise Linux 7的更多相关文章
- How to use, monitor, and disable transparent hugepages in Red Hat Enterprise Linux 6
Resolution Note: Transparent Huge Pages are not available on the 32-bit version of RHEL 6. Transpare ...
- Disable or enable the IPv6 protocol in Red Hat Enterprise Linux
Resolution Red Hat Enterprise Linux 4, 5 and 6 enable Internet Protocol Version 6 (IPv6) by default. ...
- setting up a IPSEC/L2TP vpn on CentOS 6 or Red Hat Enterprise Linux 6 or Scientific Linux
This is a guide on setting up a IPSEC/L2TP vpn on CentOS 6 or Red Hat Enterprise Linux 6 or Scientif ...
- Configure Red Hat Enterprise Linux shared disk cluster for SQL Server——RHEL上的“类”SQL Server Cluster功能
下面一步一步介绍一下如何在Red Hat Enterprise Linux系统上为SQL Server配置共享磁盘集群(Shared Disk Cluster)及其相关使用(仅供测试学习之用,基础篇) ...
- [转] KVM storage performance and cache settings on Red Hat Enterprise Linux 6.2
Almost one year ago, I checked how different cache settings affected KVM storage subsystem performan ...
- Interpreting /proc/meminfo and free output for Red Hat Enterprise Linux 5, 6 and 7
Interpreting /proc/meminfo and free output for Red Hat Enterprise Linux 5, 6 and 7 Solution Verified ...
- Common administrative commands in Red Hat Enterprise Linux 5, 6, and 7
https://access.redhat.com/articles/1189123 Common administrative commands in Red Hat Enterprise Linu ...
- Configure Red Hat Enterprise Linux shared disk cluster for SQL Server
下面一步一步介绍一下如何在Red Hat Enterprise Linux系统上为SQL Server配置共享磁盘集群(Shared Disk Cluster)及其相关使用(仅供测试学习之用,基础篇) ...
- Red Hat Enterprise Linux 6安装好,开启网卡到搭建tftp服务器和安装dnw驱动,安装samba服务器
今天一顿误操作,只能把Red Hat Enterprise Linux 6重新安装,一些必备工作只能重做,重做之后立马把Linux的文件备份,以备不时只需! 开启Linux以太网卡:vim /etc/ ...
随机推荐
- 通过fiddler和逍遥模拟器模拟抓包android手机
环境说明 Fiddler/逍遥手机模拟器 安装在10.11.0.148的电脑中 逍遥模拟器会自动生成wifi连接到 10.11.0.148上网 开启https: 在模拟器中打开 http://代理:8 ...
- vue 动态变量值不变化
caseData = { lists:[] }; vm = new Vue({ el: '.hs-mt', data: caseData }); function getlist(pid,id){ $ ...
- LuoGu P1168 中位数
题目描述 给出一个长度为 $ N $ 的非负整数序列 $ A_i $ ,对于所有 $ 1 ≤ k ≤ (N + 1) / 2 $ ,输出 $ A_1, A_3, -, A_{2k - 1} $ 的中位 ...
- DOS批处理高级教程(还不错)(转)
前言 目录 第二节 常用特殊符号 1.@ 命令行回显屏蔽符 2.% 批处理变量引导符 3.> 输出重定向符 4.>> 输出重定向符 ...
- 常用的js正则验证整理
一.校验数字的js正则表达式 1 数字:^[0-9]*$ 2 n位的数字:^\d{n}$ 3 至少n位的数字:^\d{n,}$ 4 m-n位的数字:^\d{m,n}$ 5 零和非零开头的数字:^(0| ...
- UOJ#36. 【清华集训2014】玛里苟斯 线性基
原文链接https://www.cnblogs.com/zhouzhendong/p/UOJ36.html 题解 按照 $k$ 分类讨论: k=1 : 我们考虑每一位的贡献.若有至少一个数第 $i$ ...
- 20165220 mybash
使用fork,exec,wait实现mybash - 写出伪代码,产品代码和测试代码 - 发表知识理解,实现过程和问题解决的博客(包含代码托管链接) 1.fork 功能:创建一个新的进程 一个现存进程 ...
- MongDB 数据结构
Object ID :Documents 自生成的 _id String: 字符串,必须是utf-8 Boolean:布尔值,true 或者false (这里有坑哦~在我们大Python中 True ...
- 06-JDBC
JDBC > JAVA Database Connectivity java 数据库连接 * 为什么会出现JDBC > SUN公司提供的一种数据库访问规则.规范, 由于数据库种类较多,并且 ...
- 问题11:web前端开发规范手册(转)
一.规范目的 1.1 概述 ..................................................................................... ...