Disabling default cron and using wget to trigger cron

UpdraftPlus Home Forums Paid support forum – UpdraftPlus backup plugin Disabling default cron and using wget to trigger cron

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #511634
    Brett
    Participant

    Hi

    If i disable built in cron with define(‘DISABLE_WP_CRON’, true); in wp-config.php and call “https://mysite?wp_doing_cron” as is widely recommended, updraft plus wont trigger in a cron. This was reported already in February 10, 2020 at 7:41 pm in post #511129 “https://updraftplus.com/forums/search/cron/”

    I had this happen before, so i just stopped using system crontab (as per the recommended practice). It is not a new bug, it has existed for at least a year.

    As you can see below, there is a symbol error in /home/customer/www/wootest.spacenow.net/public_html/wp-content/plugins/updraftplus/class-updraftplus.php:2809

    I read as part of doumentation that ?doing_wp_dron loads classes differently, you may not have all the PHP symbols you expect (it is cut down).

    If updraftplus is being called as part of ?doing_wp_cron, you may have to define your own symbols or act differently if the expected ones or full wp environment are not available.

    Updraft plus does complain that events are not being run by cron, this is false, it is being run, just that the run fails within updraft classes with a stacktrace

    Occurred on
    February 11th 2020, 8:44:18 pm – 2 hours ago
    Error Id
    57718403191
    Version
    5.3.2
    Message
    Error: constant(): Couldn’t find constant DOING_CRON
    Message: Error: constant(): Couldn’t find constant DOING_CRON
    #0 constant(): Couldn’t find constant DOING_CRON:: called at [/home/customer/www/wootest.spacenow.net/public_html/wp-content/plugins/updraftplus/class-updraftplus.php:2809]
    #1 ::error_handler called at [:0]
    #2 ::constant called at [/home/customer/www/wootest.spacenow.net/public_html/wp-content/plugins/updraftplus/class-updraftplus.php:2809]
    #3 UpdraftPlus::get_semaphore_lock called at [/home/customer/www/wootest.spacenow.net/public_html/wp-content/plugins/updraftplus/class-updraftplus.php:3031]
    #4 UpdraftPlus::boot_backup called at [/home/customer/www/wootest.spacenow.net/public_html/wp-content/plugins/updraftplus/class-updraftplus.php:2764]
    #5 UpdraftPlus::backup_all called at [/home/customer/www/wootest.spacenow.net/public_html/wp-includes/class-wp-hook.php:288]
    #6 WP_Hook::apply_filters called at [/home/customer/www/wootest.spacenow.net/public_html/wp-includes/class-wp-hook.php:312]
    #7 WP_Hook::do_action called at [/home/customer/www/wootest.spacenow.net/public_html/wp-includes/plugin.php:478]
    #8 ::do_action called at [/home/customer/www/wootest.spacenow.net/public_html/wp-content/plugins/updraftplus/admin.php:2173]
    #9 UpdraftPlus_Admin::request_backupnow called at [/home/customer/www/wootest.spacenow.net/public_html/wp-content/plugins/updraftplus/includes/class-commands.php:124]
    #10 UpdraftPlus_Commands::backupnow called at [/home/customer/www/wootest.spacenow.net/public_html/wp-content/plugins/updraftplus/admin.php:1547]
    #11 UpdraftPlus_Admin::updraft_ajax_handler called at [/home/customer/www/wootest.spacenow.net/public_html/wp-includes/class-wp-hook.php:288]
    #12 WP_Hook::apply_filters called at [/home/customer/www/wootest.spacenow.net/public_html/wp-includes/class-wp-hook.php:312]
    #13 WP_Hook::do_action called at [/home/customer/www/wootest.spacenow.net/public_html/wp-includes/plugin.php:478]
    #14 ::do_action called at [/home/customer/www/wootest.spacenow.net/public_html/wp-admin/admin-ajax.php:175]

    #525212
    Dee Nutbourne
    Moderator

    Hi Brett,

    Please could I confirm, are you calling https://example.com/wp-cron.php?doing_wp_cron (note the /wp-cron.php)?
    How often is the cron job scheduled for?

    Best Wishes,
    Dee

Viewing 2 posts - 1 through 2 (of 2 total)
  • The topic ‘Disabling default cron and using wget to trigger cron’ is closed to new replies.