Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

limit use of resources

Status
Not open for further replies.

nego78

Programmer
Jun 13, 2004
129
PL
Is there any posibility to write perl script which itself doesn't request more resources thn 10% of system ?

gry online
 
depend on purpose of script, and size of resources available, and whether its cpu or ram or disk you refer to
--Paul

cigless ...
 
Purpose: inserting into database huge amount of data
Resources - i don't know machines, it's deend, but i don't like to reach over 5-10% of resources (processor)

Maybe you can give me some clue how achieve this?

gry online
 
you're basically talking about throttling resources being used by a script

How did you decide on 10%, what else is running on the machine? What OS is it running?

--Paul

cigless ...
 
if it's on a unix box, you can play with the "nice" and "renice" command, so the process won't get lot's of time on the cpu at once.

greetz,

R.
 
PaulTEG: unix/linux based, probably debian or gentoo maybe bsd family - i don't know
So you're right - it's hard to obey limit, i'll try to do it in other way

RMGBELGIUM
thank you for idea

gry online
 
The one place I've seen this work on Windows is with the Stanford folding project, where the processor is only given over to the folding project according to a sliding scale.

It has to be doable, how though, that's the question.

Is a seperate database box a feasible possibility, they're a lot cheaper than they used to be ;)
--Paul

cigless ...
 
What UNIX is it?

On some UNIX's you can do what you want to do; it's not a standard part of UNIX though. In HP-UX for instance you can buy an add-on product which lets you do it - Process Resource Manager which is a chargeable product, though it's included (I think) in some versions of the O/S. I'm sure that other H/W vendors have similar and fine products.

Mike

You cannot really appreciate Dilbert unless you've read it in the
original Klingon.

Want great answers to your Tek-Tips questions? Have a look at faq219-2884

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top