Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Script priority

by b888 (Beadle)
on Oct 12, 2004 at 07:18 UTC ( [id://398392]=perlquestion: print w/replies, xml ) Need Help??

b888 has asked for the wisdom of the Perl Monks concerning the following question:

Grettings.

Is there any way to change perl script priority in run-time in the same way as linux system "nice" does?

Update

Many thanks for answering.

Janitored by Arunbear - restored original question. Please avoid deleting node content, especially questions!

Replies are listed 'Best First'.
Re: Script priority
by Prior Nacre V (Hermit) on Oct 12, 2004 at 08:44 UTC
      This may help me. I have a process that sometimes takes a while to run. If I setpriority on each iteration, can I reallocate the original resources?

      I'm not even sure that dwindling resources are the cause of my problem, but this is something to try out. Teach me to RTM.

        Please provide some sample code indicating what you are iterating over, where you were thinking of changing the priority and what sort of resources you wish to reallocate.

        Any additional information, such as where bottlenecks are (or appear to be) occurring would also be useful.

        Regards,

        PN5

Re: Script priority
by Hena (Friar) on Oct 12, 2004 at 07:48 UTC
    Um, perl script is a process just like any other. In linux use can use 'renice' command to change them while running. In windows check out the system monitor (or some name like that, can't remember), it might help.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://398392]
Approved by Corion
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others surveying the Monastery: (2)
As of 2024-04-25 23:02 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found