Start Sync Dashboard with Sites via a cron job

I just installed MainWP. It looks great and i think it is the perfect tool to manage my WP sites and for now mainly the updates.
I have some questions about how to trigger Sync Dashboard with Sites.
Manualy Sync Dashboard works fine but i would like to run it automagically.

What did i do so far?

  1. I disabled wp-con in wp-config.php
  2. I created a server cron job to trigger wp-cron.php every 10 minutes (curl > /dev/null 2>&1)
  3. In MainWP > Settings > General Settings i set a automatic daily sync time to test the cron.

One time there were 3 of 23 sites synced as far as i can see via the last sync time and then it looks like syncing stopped.

My questions:

  1. Is the above described way correct?
  2. If this is correct why does it stop after a few sites.
  3. Is there a php file that i can run from a cron job that does the sync without wp-cron? What php file and how do i have to configure this (disable wp-cron in Settings???).
  4. When i set the Automatic daily sync time to a certain time and it did a sync (or patialy sync), does this mean that i have to wait 24 hours for the following sync also when i set the time in the future for testing purposes.

Thanks in advance

@Benny54 Please follow these direction here to setup the correct cron jobs needed to run MainWP Syncs.

It looks like the line is correct - try using wget instead?
Let us know if you continue to have issues.

1 Like

Hi Keith, thanks for your prompt reply. I tried the wget before but to no avail.
In the link that you send i see a direct cron running updatescheck.php. Is this the php file that should directly trigger the Sync. And if it is, does it overrule the Automatic daily sync time?

@Benny54 Oh you’re very welcome.

Yes, you will want to use the lines provided for each function to fire off correctly. As for the “Automatic daily sync time” located on the General Settings page - correct; This is the time set for the WP Cron to fire the individual functions that are included within the “Sync”.

This document might be of use too if you choose to test the WP Cron system further before abandoning it.

1 Like

Hi Keith, would like to let you know that the synchronistations works like a charm now. I adjusted some timing prerequisites according to: System Requirements - MainWP Documentation
Furthermore there was an error in my curl commands in the cron jobs :frowning:
Thanks again for your support.


@Benny54 That’s great news! Please let us know if you run into any other issues or simply need guidance. :slight_smile:

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.