Is there a delay before a cronjob starts after activating? [Solved]

Discussion in 'General' started by jjsjjs, Jun 30, 2021.

  1. jjsjjs

    jjsjjs Member

    Hi,

    after some tests on how to get it working it seems to be working.
    I want 7 scripts to follow each other.
    But for the test I have putted 1 script into the private folder of client1. This script just copies some files from web/folder to web/anotherfolder.
    Set client on Full Cron. Limit on 0, which I believe means unlimited.
    Command to run is: /usr/bin/php /var/www/clients/client1/web1/private/blablabla.php
    For the test I've set the minute on 1 and the rest *. So it should run every minute, I guess. (normally the 7 scripts should run once every day)
    In the cron.log I only see that it run 2 times, in fact it should already be like 30 times.
    I also see that it does not immediately start when activating a cronjob. It takes like an half hour before it starts.
    - Why is it starting after an half hour and not after 1 or a few minutes?
    -Why does it only copy 2 times?
    -If I set the time to 23 hours and 30 minutes, does this mean it starts after every 23hours and 30 minutes after start or at the actual time 23:30?
    - a * means, every hour, or every day?
    Thanks for any help.

    Kind regards.
     
  2. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    jjsjjs likes this.
  3. Taleman

    Taleman Well-Known Member HowtoForge Supporter

    Guessing is not a good way to make working programs or scripts.
    If the minute column is 1, it means run one minute past full hour. So once per hour.
    Read the docs, dude. Like, man 5 crontab. Peace, brother (or sister).
     
    jjsjjs likes this.
  4. jjsjjs

    jjsjjs Member

    Thank you , that's what i needed, but could not find.
     
  5. jjsjjs

    jjsjjs Member

    You're right!
    The script itself runs fine. Just seeing it, it gives me the wrong expectation, namely that it would mean every 1 minute or whatever is filled in by the user. On the other hand it gave me the expectation that I could fill in the exact time as I wrote in the post. BUt thanks yes I'm going to read it and fiddle diddle with it. Peace!
     

Share This Page