lemoncyb的个人博客分享 http://blog.sciencenet.cn/u/lemoncyb

博文

Redhat 关闭 CPU throttling

已有 6396 次阅读 2015-5-21 23:08 |个人分类:linux|系统分类:科研笔记| CPU, throttling


最近安装测试 HPL 需要安装 ATLAS,而安装 ATLAS 需要关闭 CPU throttling(即CPU变频)。

在 Redhat 下关闭方法之一如下:


1. 在 /etc/init.d/ 目录下创建文件 ondemand,内容如下:

--------

#! /bin/bash

#

# ondemand sets cpu govermor

#

# chkconfig: 2345 10 90

#

# description: Set the CPU Frequency Scaling governor to "performance"

#

### BEGIN INIT INFO

# Provides: $ondemand

### END INIT INFO


PATH=/sbin:/usr/sbin:/bin:/usr/bin

case "$1" in

   start)

       for CPUFREQ in /sys/devices/system/cpu/cpu*/cpufreq/scaling_governor

       do

               [ -f $CPUFREQ ] || continue

               echo -n performance > $CPUFREQ

       done

       ;;

   restart|reload|force-reload)

       echo "Error: argument '$1' not supported" >&2

       exit 3

       ;;

   stop)

       ;;

   *)

       echo "Usage: $0 start|stop" >&2

       exit 3

       ;;

esac

-------------

2. 开启 ondemand服务

#chmod +x /etc/init.d/ondemand

#chkconfig ondemand on

#service ondemand start




https://blog.sciencenet.cn/blog-935970-892170.html

上一篇:Mac下使用.ppk密钥ssh远程登录
下一篇:cannot connect to local mpd错误解决
收藏 IP: 222.240.177.*| 热度|

0

该博文允许注册用户评论 请点击登录 评论 (0 个评论)

数据加载中...

Archiver|手机版|科学网 ( 京ICP备07017567号-12 )

GMT+8, 2024-4-20 08:15

Powered by ScienceNet.cn

Copyright © 2007- 中国科学报社

返回顶部