QuestionsMautic Cron Issues
John asked 8 months ago

Hi Adam,

I am creating an online course. I really appreciate your education. It is really top notch and goes through details most don't get into.

I ordered inmotion hosting, through your link. I am using Mautic for my contact manager and having a hard time getting my contacts to show up in my campaigns even though they are showing up in my selected segments. Do I have the Cron jobs set up right? I am thinking that must be the issue even though I followed your steps precisely and even updated them per the Mautic web page. This is the format they are all in. Is it correct?

/Usr/local/cpanel/3rdparty/bin/php /home/yourcr7/email/app/console mautic:webhooks:process > /dev/null 2>&1

Thanks again Adam!

2 Answers
Adam @ WPCrafter Staff answered 8 months ago

My old instructions for setting up the Mautic crons is completely out of date. You can visit the Mautic website to see the latest crons. They had changed them some when going from v1 to v2 of Mautic.

marianco answered 2 months ago

————————————————–
MAUTIC CRON JOBS FOR MAUTIC 2.0x:
 
Here is information for setting up Mautic Cron jobs based on:
https://www.mautic.org/resources/understanding-cron-jobs/:
and Mautic Documentation: https://www.mautic.org/docs/en/setup/cron_jobs.html
 
 
STRUCTURE OF A CRON JOB:
1. path/to/php = location of the PHP utility that will processes PHP commands
2. mautic command
3. > /dev/null 2>&1 = sends the results of the command to nowhere.
 
If > /dev/null 2>&1 is omitted, your host may allow you to email the mautic command's results to your selected email address.  Inmotion Hosting does this, for example.  I omit this for the once a day command so that I get notification that mautic is actually working and hasn't crashed.
 
————————-
REQUIRED CRON JOBS:
 
TO KEEP THE SEGMENTS CURRENT:
path/to/php path/to/mautic/app/console mautic:segments:update
 
TO KEEP CAMPAIGNS UPDATED WITH APPLICABLE CONTACTS:
path/to/php path/to/mautic/app/console mautic:campaigns:rebuild
 
TO EXECUTE CAMPAIGNS EVENTS:
path/to/php path/to/mautic/app/console mautic:campaigns:trigger
 
 
————————-
OPTIONAL CRON JOBS:
 
IF THE SYSTEM IS CONFIGURED TO QUEUE EMAILS TO THE FILESYSTEM, PROCESS EMAIL QUEUE:
path/to/php path/to/mautic/app/console mautic:emails:send
 
IF USING BOUNCE MANAGEMENT, FETCH AND PROCESS MONITORED EMAIL:
path/to/php /path/to/mautic/app/console mautic:email:fetch
 
IF USING SOCIAL MONITORING:
path/to/php path/to/mautic/app/console mautic:social:monitoring
 
IF MAUTIC IS CONFIGURED TO SEND WEBHOOKS IN BATCHES, USE THE FOLLOWING COMMAND TO SEND THE PAYLOADS:
path/to/php /path/to/mautic/app/console mautic:iplookup:download
 
 
————————-
BASED ON THE PREVIOUS INFORMATION, HERE IS WHAT I USE:
I use the generic PHP utility rather than PHP7 on InmotionHosting.
 
Minute _ _ _ _ _ Hour _ _ _ _ _ Day _ _ _ _ _ Month _ _ _ _ _ Weekday _ _ _ _ _ Command
 
*/15 _ _ _ _ _ * _ _ _ _ _ * _ _ _ _ _ * _ _ _ _ _ * _ _ _ _ _ 
/usr/local/cpanel/3rdparty/bin/php /home/YourHostAccount/public_html/mautic/app/console mautic:webhooks:process > /dev/null 2>&1
 
*/10 _ _ _ _ _ * _ _ _ _ _ * _ _ _ _ _ * _ _ _ _ _ * _ _ _ _ _ 
/usr/local/cpanel/3rdparty/bin/php /home/YourHostAccount/public_html/mautic/app/console mautic:segments:update > /dev/null 2>&1
 
*/10 _ _ _ _ _ * _ _ _ _ _ * _ _ _ _ _ * _ _ _ _ _ * _ _ _ _ _ 
/usr/local/cpanel/3rdparty/bin/php /home/YourHostAccount/public_html/mautic/app/console mautic:campaigns:rebuild > /dev/null 2>&1
 
*/10 _ _ _ _ _ * _ _ _ _ _ * _ _ _ _ _ * _ _ _ _ _ * _ _ _ _ _ 
/usr/local/cpanel/3rdparty/bin/php /home/YourHostAccount/public_html/mautic/app/console mautic:campaigns:trigger > /dev/null 2>&1
 
* _ _ _ _ _ * _ _ _ _ _ * _ _ _ _ _ * _ _ _ _ _ * _ _ _ _ _ 
/usr/local/cpanel/3rdparty/bin/php /home/YourHostAccount/public_html/mautic/app/console mautic:email:send > /dev/null 2>&1
 
0 _ _ _ _ _ 0 _ _ _ _ _ * _ _ _ _ _ * _ _ _ _ _ * _ _ _ _ _ 
/usr/local/cpanel/3rdparty/bin/php /home/YourHostAccount/public_html/mautic/app/console mautic:email:fetch > /dev/null 2>&1
 
0 _ _ _ _ _ 0 _ _ _ _ _ * _ _ _ _ _ * _ _ _ _ _ * _ _ _ _ _ 
/usr/local/cpanel/3rdparty/bin/php /home/YourHostAccount/public_html/mautic/app/console mautic:iplookup:download > /dev/null 2>&1

Your Answer
8 + 7 =

Accepted file types: png, jpg, pdf

Add another file