首页 > 系统服务 > 详细

安装CPULimit到Linux(源码)

时间:2020-02-28 15:57:34      阅读:94      评论:0      收藏:0      [点我收藏+]

运行环境

适用系统:所有Linux系统
当前版本:无
硬件要求:无

安装过程

1、安装依赖

root@localhost:~# apt-get -y install git

2、从GitHUB中克隆源码到本地

root@localhost:~# git clone https://github.com/opsengine/cpulimit.git

3、编译并安装

root@localhost:~# cd cpulimit/src
root@localhost:~/cpulimit/src# make
root@localhost:~/cpulimit/src# cp cpulimit /usr/bin

4、限制指定进程的CPU百分比

下面演示的是将进程号为“11830”的进程的CPU限制在百分之200。

root@localhost:~# nohup cpulimit --pid 11830 --limit 200 &

安装CPULimit到Linux(源码)

原文:https://www.cnblogs.com/network-ren/p/12376998.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!