Learn about Centmin Mod LEMP Stack today
Become a Member

Sysadmin Cronjobs Not Working

Discussion in 'System Administration' started by skringjer, May 6, 2019.

  1. skringjer

    skringjer Member

    144
    17
    18
    Apr 21, 2019
    Ratings:
    +31
    Local Time:
    10:37 AM
    Hey everyone, i added some crons with the following command sudo crontab -e

    Code:
    0 0 * * * php /home/nginx/domains/domain.com/public/admin/tasks/auto_prune.cron.php >> /dev/null 2>&1
    0 0 * * * php /home/nginx/domains/domain.com/public/admin/tasks/create_internal_notifications.cron.php >> /dev/null 2>&1
    0 * * * * php /home/nginx/domains/domain.com/public/admin/tasks/delete_redundant_files.cron.php >> /dev/null 2>&1
    0 0 * * * php /home/nginx/domains/domain.com/public/admin/tasks/downgrade_accounts.cron.php >> /dev/null 2>&1
    */5 * * * * php /home/nginx/domains/domain.com/public/admin/tasks/process_file_queue.cron.php >> /dev/null 2>&1
    0 1 * * * php /home/nginx/domains/domain.com/public/admin/tasks/create_email_notifications.cron.php >> /dev/null 2>&1
    30 4 * * * /home/script.sh
    * * * * * php /home/nginx/domains/domain.com/public/plugins/imageviewer/site/background_thumbs.cron.php >> /dev/null 2>&1
    But none of these crons are running, there are some centmin crons too in the crontab
    Code:
    #13 23 * * * /usr/local/src/centminmod/tools/autoprotect.sh >/dev/null 2>&1
    0 */4 * * * /usr/bin/cminfo_updater 2>/dev/null
    0 */6 * * * /usr/bin/cmupdate 2>/dev/null
    43 0 * * * "/root/.acme.sh"/acme.sh --cron --home "/root/.acme.sh" > /dev/null
    19 02 * * * /root/tools/phpmyadmin_update.sh >/dev/null 2>&1
    23 */36 * * * /usr/local/src/centminmod/tools/csfcf.sh auto >/dev/null 2>&1
    Could someone help as to why my crons arent working, the crond is running. Centmin also updates automatically.
     
  2. eva2000

    eva2000 Administrator Staff Member

    44,742
    10,200
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +15,809
    Local Time:
    3:37 PM
    Nginx 1.17.x
    MariaDB 5.5/10.x
    use full path to php instead so instead of php use /usr/local/bin/php and instead of >> use single >
    Code (Text):
    0 0 * * * /usr/local/bin/php /home/nginx/domains/domain.com/public/admin/tasks/auto_prune.cron.php >/dev/null 2>&1
    
     
  3. skringjer

    skringjer Member

    144
    17
    18
    Apr 21, 2019
    Ratings:
    +31
    Local Time:
    10:37 AM
    Working, thanks :)