Learn about Centmin Mod LEMP Stack today
Become a Member

Sysadmin Crontab jobs

Discussion in 'System Administration' started by abakisensoy, Aug 26, 2020.

Tags:
  1. abakisensoy

    abakisensoy Member

    49
    3
    8
    Dec 2, 2016
    Ratings:
    +3
    Local Time:
    2:01 AM
    latest
    5.5
    Hi,


    I installed WordPress with option 22. After that, I installed other web services which require cron jobs.

    I manually edit crontabs with crontab -e

    However, We realized that our cron jobs haven't worked almost for two weeks.

    Could centminmod overwrite our cron jobs?
     
  2. tininho

    tininho Active Member

    182
    44
    28
    May 22, 2019
    eu
    Ratings:
    +135
    Local Time:
    7:01 PM
    Just my 5cents:

    Anytime I have tried to move out from Wordpress default cron (aka pseudocron) by disabling WP cron and activating the cronjob on centminmod server, something goes awry. Things don't update correctly, as you stated, and pending scheduled actions get overloaded.

    If your site uses actionscheduler (Woocommerce, subscription plugins etc.) and you disable WP cron, you will be in world of pain.

    Some fixes I have come up with (I use WP cron and AS High Volume):

    For laggy updates to database:
    woocommerce/action-scheduler-high-volume

    For excessive deadlocks in error log:
    Fix: Add new index by glagonikas · Pull Request #535 · woocommerce/action-scheduler
    Issue: Diagnose intermittent deadlocks · Issue #530 · woocommerce/action-scheduler

    For disabling WP cron AND still successfully running actionscheduler jobs you'd have to trigger it manually from cron, or so I have understood. I will add the commands here, if needed (need to dig them).
     
  3. eva2000

    eva2000 Administrator Staff Member

    53,607
    12,139
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,683
    Local Time:
    2:01 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    @tininho wordpress is specific case, i deliberately disable centmin.sh menu option 22 wordpress created system cronjob so to leave wordpress native cron working as folks have reported system cron for wordpress specifically not working. However, non-wordpress system cronjobs should work.

    which cronjobs exactly are they ?
    if you're comfortable you can only list the ones or/masked ones from output for
    Code (Text):
    crontab -l
     
  4. abakisensoy

    abakisensoy Member

    49
    3
    8
    Dec 2, 2016
    Ratings:
    +3
    Local Time:
    2:01 AM
    latest
    5.5

    WHMCS cron jobs. It works every 5mins. I moved from directadmin to centmin so my cron jobs messed up. It is working now.
     
  5. eva2000

    eva2000 Administrator Staff Member

    53,607
    12,139
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,683
    Local Time:
    2:01 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    so cronjobs work now ? or you made some changes on server or web app side ?