in reply to Re: Exec'd perl running wild on cpu-time
in thread Exec'd perl running wild on cpu-time

Actually, I run the script continously. But, before finding the "open terminal" solution, I was thinking about making a cron job to periodically kill and restart the script. This way, I could get rid of the open terminal day and night and weekends...

Indeed, I consider the CPU-black-holish thing puzzling. Maybe there is (and I hope so) a obvious/ stupid flaw in my way of handling the script.

  • Comment on RE: Re: Exec'd perl running wild on cpu-time

Replies are listed 'Best First'.
RE: RE: Re: Exec'd perl running wild on cpu-time
by Corion (Patriarch) on Nov 13, 2000 at 18:27 UTC

    Of course, this is drifting away from Perl, but in the spirit of the Right Tool for The Right Job, cron knows all about weekdays and time slots. I would use cron (or at, which can do that stuff under NT) with the following crontab entry to ensure that it checks every 5 minutes during the week, from 7:00h to 20:00h, monday through friday :

    0,5,10,15,20,25,30,35,40,45,50,55 7-20 * * 1-5
    Note: I didn't check that line and also I only worked from the crontab (5) manpage. Usually this means that some tweaking is required afterwards.

      Instead of 0,5,10,15,20,25,30,35,40,45,50,55 you can also write */5 for every 5 minutes:
      */5 7-20 * * 1-5

      [ar0n]