Operating System - Linux
1752509 Members
4778 Online
108788 Solutions
New Discussion юеВ

LIMITING CPU UTILIZATION OF A PROCESS

 
dhanasekaran
New Member

LIMITING CPU UTILIZATION OF A PROCESS

i am in need of allowing the the running processs in linux to use the required percentage of cpu only (for e.g.20%) .The process should not exceed that limit when using the CPU...i have to do this CPU utilization limit in linux environment...tell me the best way of doing this...is there any command for it..atleast tell me the steps to achieve the above goal...
thank you....
2 REPLIES 2
saravanan08
Valued Contributor

Re: LIMITING CPU UTILIZATION OF A PROCESS

u can limit the CPU utilizatation of a process by settin nice value

for example

nice -15 command

by default it is 20

if u want to make ur process less prior means

reduce the nice value

nice -10 command
it wil run the process at nice value 10(20-10)

if u want to make the process more prior means u have to increase the nice value
but only root user can increase nice value

# nice --15 command

this will run the process at nice value 35(20+15)

refer man page for nice command.

clear???/
john123
Trusted Contributor

Re: LIMITING CPU UTILIZATION OF A PROCESS

If it was HP-UX I would have suggested to use PRM .

But Don know how to do that in Linux