[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: scripts running all the time?



On Sat, Feb 23, 2008 at 10:59:53PM -0500, Douglas A. Tutty wrote:
> On Sun, Feb 24, 2008 at 01:49:18PM +1100, Daniel Dalton wrote:
> > On Sun, 24 Feb 2008, Raj Kiran Grandhi wrote:
> > >Daniel Dalton wrote:
> > >0 7 * * * /path/to/script.sh
> > When would that stop? How do you make it stop at 10? but ok I'll test it.
> Write a script that starts the download.  Have it record the pid in
> /var/run/ .  Have this script started by crontab at the appropriate
> time.
> Set up crontab to kill the process numbered by that pid file at the
> appropriate time.

or call /path/to/script.sh under the command provided by the package

timeout - Run a command with a time limit.

There is also

timeoutd - Flexible user timeout daemon with X11 support

however I never used it. apt-cache search might give more possibilities.

-- 
Chi usa software non libero avvelena anche te. Digli di smettere.
Informatica=arsenico: minime dosi in rari casi patologici, altrimenti letale.
Informatica=bomba: intelligente solo per gli stupidi che ci credono.


Reply to: