找回密码
 新注册用户
搜索
查看: 31684|回复: 12

介绍一个限制进程最大CPU占用的软件: ThreadMaster

[复制链接]
发表于 2005-3-30 10:21:15 | 显示全部楼层 |阅读模式
软件的主页http://threadmaster.tripod.com/好像上不去,这个链接是可以的:
http://bednorz.uni2.net/anyland/threadmaster/threadmaster.htm

简介:
ThreadMaster Monitors Threads and handle high CPU utilization on a per application basis.

ThreadMaster is a background service implementing a CPU Quota mechanism on top of the standard thread scheduling algorithms of the Microsoft Windows 2000 Operating Systems.

ThreadMaster monitors all running applications, and detects when a application  starts to  use excessive processor resources. It dynamically hunt down the offending thread, and clamp the CPU for this thread. This feature ensures that other users can remain working without noticing anything. The clamped process will eventually finish, and the clamp will be removed automatically.

下载地址:
http://bednorz.uni2.net/anyland/threadmaster/tminst112.zip

目前的版本是Ver. 1.12 Build 182

安装非常简单,将压缩包解开,运行其中的Install.cmd就可以了。

在主页上有卸载的方法,或者更简单,下载一个脚本执行一下也可以:
http://bednorz.uni2.net/anyland/threadmaster/uninst.cmd
回复

使用道具 举报

 楼主| 发表于 2005-3-30 10:23:22 | 显示全部楼层
软件没有GUI,所有设置直接修改注册表:

Configuration

ThreadMaster has no GUI interface, all configuration is done by using a well known tool "Regedit".  Changing  registry keys not described in this section, may cause serious problems. Use Registry Editor at your own risk. After any changes in the configuration please restart the ThreadMaster service for the changes to take effect.

All the default values in ThreadMaster is based on 2 CPU Compaq server, but can be used on any configuration.

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\ThreadMaster\Parameters]

CPUThresholdPct

CPU load threshold per application. This is a global setting and affect all applications, unless  other settings are defined in the "Application" or "Exceptions" sections.
Default: 15%,   Valid range 3 - 100.

MainSampleTime

Time in seconds for application load above "CPUThresholdPct"
This value define the measurement time ThreadMaster using for calculating the average CPU utilization for applications.
Default: 30 sec.   Values  above 10 sec.  accepted.

ThreadOverloadActionStart

Command to execute at action start.
Default :none

ThreadOverloadActionStop

Command to execute at action stopping. See the sample files "Threadloginstall.reg" and "ThreadLog.cmd" These files may be edited for your own usage.
Default: none

A list of special applications and the allowed CPU load.  Only  applications different from the general rule defined by "CPUThresholdPct" . Applications running as a single published application, in many instances, can profit by setting the applicationkey as low as 5%.
The list is  read dynamically.

IMPORTANT: In multithreaded applications with multiple CPU incentive threads, don't set this value below the current number of CPU incentive threads, this may cause the application to "hang" , or run extremely slow.

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\ThreadMaster\Parameters\Applications]
  appimagenameA      n         Application image name and  max. load threshold pct. (n)
  appimagenameB      m        Valid Range 3 - 100
  ...
  appimagenameX      x

A list of applications not handled. Make sure all vital and basis system processes are listed here, otherwise the system may not work properly.   Do not take it for granted that  antivirus programs etc. are vital, in this sense.
The list is only enumerated when Threadmaster starts.

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\ThreadMaster\Parameters\Exceptions]
  imagenameA
  imagenameB
  ...
  imagenameX

Statistics is updated by ThreadMaster, this section documents  the work of ThreadMaster.

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\ThreadMaster\Statistics]

[ Last edited by Youth on 2005-3-30 at 10:38 ]
回复

使用道具 举报

 楼主| 发表于 2005-3-30 10:26:17 | 显示全部楼层
其实需要关心的主要就是几个地方:

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\ThreadMaster\Parameters]
CPUThresholdPct
这个是设置一般进程最大CPU占用率的地方,有效值 3-100

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\ThreadMaster\Parameters\Applications]
这里可以针对具体进程限制其CPU占用

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\ThreadMaster\Parameters\Exceptions]
这里可以设置不受上面占用率限制影响的进程列表,缺省已经有一些系统进程在里面了,也可以自己进行修改

[ Last edited by Youth on 2005-3-30 at 10:39 ]
回复

使用道具 举报

 楼主| 发表于 2005-3-30 10:33:43 | 显示全部楼层
软件只支持Win2000以上系统。

贴一下手工卸载的方法吧:

运行一个命令行cmd.exe
切换到%windir%\system32\ThreadMaster目录
运行net stop threadmaster
运行ThreadMast -remove
删除%windir%\system32\ThreadMaster目录
回复

使用道具 举报

发表于 2005-3-30 12:13:12 | 显示全部楼层
试过吗?
回复

使用道具 举报

 楼主| 发表于 2005-3-30 13:09:40 | 显示全部楼层
用过的,缺省是限制进程最大CPU占用为15%,我没修改

在我的p4-2.8e(带HT)上,同时运行两个einstein@home的客户端,分别占用15%,然后剩下的60%多就给System Idle Process了,CPU Usage那个图显示的是30%

不过这东西对我没什么用处,所以试过后就卸载了:)
回复

使用道具 举报

发表于 2005-3-30 17:54:52 | 显示全部楼层
对我来说没什么太大用处。。一般P4以上的机器运行一个BOINC的客户端顶多占用50%左右的资源。。不过对于老机器还是蛮有用的。。谢谢楼主啊!
回复

使用道具 举报

发表于 2005-4-18 23:11:12 | 显示全部楼层
我觉得还是挺好用的,我的3000+没用之前CPU100%,弄得机器反应太慢了
现在设成30%就好多了
回复

使用道具 举报

发表于 2005-4-19 13:27:07 | 显示全部楼层
Youth  在 2005-3-30 10:21 AM 发表:

软件的主页http://threadmaster.tripod.com/好像上不去,这个链接是可以的:
http://bednorz.uni2.net/anyland/threadmaster/threadmaster.htm

简介:
ThreadMaster Monitors Threads an ...


Linux 下面有没有相应的工具,找了半天只看到schedutils,但是做不到限制上下限百分比。
回复

使用道具 举报

发表于 2006-5-14 08:55:42 | 显示全部楼层
好像没用啊,一打开CPU使用降到30%(没改任何默认设置),然后按你的方法试了一下,还是30%。重启后,恢复。
我是 INTER  奔腾D 双核 P775 X64 2.8G
是不是程序不支持双核CPU啊?
回复

使用道具 举报

 楼主| 发表于 2006-5-14 10:37:01 | 显示全部楼层
没看明白
你不用这个软件就能控制在30%?
回复

使用道具 举报

发表于 2006-12-19 22:02:12 | 显示全部楼层
谢谢我找到BES,可以用的了,还是中文界面的
下载地址:
http://mion.faireal.net/bes_1.2.2.zip
有需要的可以下载,挺好用的
回复

使用道具 举报

发表于 2006-12-22 20:59:39 | 显示全部楼层
貌似没用嘛~~
vmware-vmx.exe就是会超过限制的值
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 新注册用户

本版积分规则

论坛官方淘宝店开业啦~
欢迎大家多多支持基金会~

Archiver|手机版|小黑屋|中国分布式计算总站 ( 沪ICP备05042587号 )

GMT+8, 2024-5-6 02:13

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表