[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: limiting the CPU time allowed
"A. Roubicek" wrote:
>
> Hi JD, thank you for your reply,
> I am sorry, I was not clear. I mean that "if the job takes more than
> certain amount of CPU time, it should be killed". Is there any way to do
> it from within IDL? Some applications have an option in the calling
> command to set this kind of limit.
>
> On Mon, 26 Feb 2001, JD Smith wrote:
>
> > "A. Roubicek" wrote:
> > >
> > > Hi all,
> > >
> > > I'm trying to find a way to limit the CPU time an IDL process can
> > > take (on unix, running from cron), to prevent clugging the system
> > > with runaway processes. Any leads would be greatly appreciated!
> > >
> > > Thank you,
> > > A.R.
> >
> > nice 15 idl "domyjob.pro"
> >
> > jd
If runaway IDL processes are begin created by cron, then killing them
after the fact would seem to be treating the symptom and not the
disease. Do the IDL scripts created by your cron job have adequate error
handling? Does each IDL script invoked by cron have an EXIT statement at
the end?
To kill runaway jobs, you might be able to parse the output of 'ps',
e.g.,
IDL> spawn, 'ps -ef | fgrep idl | sort', result
Don't kill the IDL license manager though...
Cheers,
Liam.
http://cimss.ssec.wisc.edu/~gumley