[转帖]Linux禁用CPU省电状态/Linux系统性能调优
https://www.jianshu.com/p/945168b47487
How to Disable CPU Power Saving States on a Redhat or Suse Linux System
For RedHat Linux (release 7 and later)
- Open the /etc/default/grub configuration file as root using a plain text editor such as vim or Gedit.
- In this file, locate the line beginning with GRUB_CMDLINE_LINUX similar to the following:
GRUB_CMDLINE_LINUX="rd.lvm.lv=rhel/swap crashkernel=auto rd.lvm.lv=rhel/root rhgb quiet"
- Change the value of the required kernel command-line parameter. Then, save the file and exit the editor.
intel_idle.max_cstate=0
processor.max_cstate=1 - Regenerate the GRUB2 configuration using the edited default file. If your system uses BIOS firmware, execute the following command:
# grub2-mkconfig -o /boot/grub2/grub.cfg
On a system with UEFI firmware, execute the following instead:
# grub2-mkconfig -o /boot/efi/EFI/redhat/grub.cfg
After finishing the procedure above, the boot loader is reconfigured, and the kernel command-line parameter that you have specified in its configuration file is applied after the next reboot.
For RedHat Linux (releases prior to 7) or SuSE Linux
- Add the following text to the kernel line in /boot/grub/menu.lst:
intel_idle.max_cstate=0
processor.max_cstate=1 - Reboot the system for the change to take effect.
How to Disable CPU Power Saving States on a Debian Linux System
To disable CPU power saving states on a Debian Linux system, perform the following procedure:
- Modify the GRUB_CMDLINE_LINUX string in /etc/default/grub so that it contains:
intel_idle.max_cstate=0
processor.max_cstate=1 - Run "update-grub".
- Reboot the system for the change to take effect.
Note: Disabling CPU power saving states in the system BIOS has no effect on Linux.
In some cases, performance can also be improved by adjusting the idle kernel parameter. However, care should be taken when using certain values. For example, idle=poll maximizes performance but is incompatible with hyperthreading (HT) and will lead to very high power consumption. For additional information, refer to the documentation for your version of Linux.
On Windows, disable CPU power saving states by adjusting BIOS settings. Refer to system vendor documentation for additional information.
[转帖]Linux禁用CPU省电状态/Linux系统性能调优的更多相关文章
- linux系统性能调优第一步——性能分析(vmstat)
linux系统性能调优第一步--性能分析(vmstat) 分类: LINUX 性能调优的第一步是性能分析,下面从性能分析着手进行一些介绍,尤其对linux性能分析工具vmstat的用法和实践进行详细介 ...
- Linux操作系统性能调优的方法
http://www.cnblogs.com/L-H-R-X-hehe/p/3963442.html Linux是一套免费使用和自由传播的类Unix操作系统,Linux不同的发行版本和不同的内核对各项 ...
- Perf Event :Linux下的系统性能调优工具
Perf Event :Linux下的系统性能调优工具 2011-05-27 10:35 刘 明 IBMDW 字号:T | T Perf Event 是一款随 Linux 内核代码一同发布和维护的性能 ...
- Perf -- Linux下的系统性能调优工具,第 1 部分 应用程序调优的使用和示例 Tracepoint 是散落在内核源代码中的一些 hook,一旦使能,它们便可以在特定的代码被运行到时被触发,这一特性可以被各种 trace/debug 工具所使用。Perf 就是该特性的用户之一。
Perf -- Linux下的系统性能调优工具,第 1 部分 应用程序调优的使用和示例 https://www.ibm.com/developerworks/cn/linux/l-cn-perf1/i ...
- Linux内核、 TCP/IP、Socket参数调优
/proc/sys/net目录 所有的TCP/IP参数都位于/proc/sys/net目录下(请注意,对/proc/sys/net目录下内容的修改都是临时的,任何修改在系统重启后都会丢失),例如下面这 ...
- linux下TCP/IP及内核参数优化调优(转)
Linux下TCP/IP及内核参数优化有多种方式,参数配置得当可以大大提高系统的性能,也可以根据特定场景进行专门的优化,如TIME_WAIT过高,DDOS攻击等等. 如下配置是写在sysctl.con ...
- Perf -- Linux下的系统性能调优工具,第 1 部分【转】
转自:https://www.ibm.com/developerworks/cn/linux/l-cn-perf1/ Perf 简介 Perf 是用来进行软件性能分析的工具. 通过它,应用程序可以利用 ...
- Linux系统性能调优之性能分析
1.Linux性能分析的目的1)找出系统性能瓶颈(包括硬件瓶颈和软件瓶颈):2)提供性能优化的方案(升级硬件?改进系统系统结构?):3)达到合理的硬件和软件配置:4)使系统资源使用达到最大的平衡.(一 ...
- Perf -- Linux下的系统性能调优工具,第 2 部分 特殊用法以及内核调优示例
https://www.ibm.com/developerworks/cn/linux/l-cn-perf2/ 本文内容简介 之前介绍了 perf 最常见的一些用法,关注于 Linux 系统上应用程序 ...
- 系统性能调优CPU与内存
CPU相关术语 处理器:插到系统插槽或者处理器版上的物理芯片,以核或者硬件线程的方式包含了一块或者多块CPU. 核:一颗多核处理器上的一个独立CPU实例.核的使用时处理器扩展的一种方式,有称为芯片级多 ...
随机推荐
- 2021-01-04:mysql里的innodb引擎的数据结构,你有看过吗?
福哥答案2021-01-04: 面试官刚开始问我看过mysql源码没,然后问了这个问题.回答B+树,过不了面试官那关. 答案来自<MySQL技术内幕 InnoDB存储引擎 第2版>第四章, ...
- 开源的代名词「GitHub 热点速览」
当开发者谈论开源时,通常会想到 GitHub,它不仅仅是一个代码托管平台,更是一个汇聚了全球开发者的社交中心.过去,开发者发布一款软件后,都是在自己的小圈子里默默努力和交流,现在通过 GitHub 平 ...
- SARIF在应用过程中对深层次需求的实现
摘要:为了降低各种分析工具的结果汇总到通用工作流程中的成本和复杂性, 业界开始采用静态分析结果交换格式(Static Analysis Results Interchange Format (SARI ...
- vue2升级vue3:vue3真的需要vuex或者Pinia吗?hooks全有了
在写 <vue2升级vue3:TypeScript下vuex-module-decorators/vuex-class to vuex4.x>,建议新项目使用 Pinia,但是我的项目部分 ...
- 互联网公司Python高性能编程
虽然Python一直被吐槽执行速度慢,但是架不住简洁的语法和丰富的第三方库使其能够节省开发时间.众所周知在互联网公司中要求频繁的迭代.快速的上线,而Python的优点就特别适合这种需求,所以Pytho ...
- 正确理解c# default关键字
背景 最近QA测试一个我开发的一个Web API时,我意识到之前对C#的default的理解一直是想当然的.具体情况是这样,这个API在某些条件下要返回模型的默认值,写法类似于下面这样 [HttpGe ...
- 2021 年如何学习 Android,一位 5 年中大厂老哥跟你聊聊
本文首发我的微信公众号:程序员徐公 大家好,我是程序员徐公,加上实习,有五年中大厂经验.今天,我们一起来聊一聊如何自学 Android. 光阴似箭,日月如梭,时间真的过得飞快. 加上实习,从事 And ...
- C++ Lambda 快速上手
Lambda 听起来非常的牛逼,很容易就会联想到函数式编程或者 Lambda 演算这样的东西.但是在 C++里,没那么复杂,就把它当匿名函数用就好了 HelloWorld 对于降序排序,我们可以这样写 ...
- 区间DP练习题题解
算法讲解:Here AcWing 282. 石子合并 (模板) 题目链接:Here const int N = 310; int a[N], s[N]; int dp[N][N]; void solv ...
- 区间dp专题小结
区间DP是一类在区间上进行动态规划的最优问题,一般是根据问题设出一个表示状态的 dp,可以是二维的也可以是三维的,一般情况下为二维.然后将问题划分成两个子问题,也就是一段区间分成左右两个区间,然后将左 ...