# mautic:campaigns:trigger isn't sending emails

**URL:** <https://forum.mautic.org/t/mautictrigger-isnt-sending-emails/3965>\
**Category:** Product Support\
**Created:** [May 24, 2016, 3:49pm UTC](https://forum.mautic.org/t/mautictrigger-isnt-sending-emails/3965 "2016-05-24T15:49:41Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![Slbailey](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/slbailey/32/78_2.png) [@Slbailey](https://forum.mautic.org/u/Slbailey)\
**Post date:** [May 24, 2016, 3:49pm UTC](https://forum.mautic.org/t/mautictrigger-isnt-sending-emails/3965/1 "2016-05-24T15:49:41Z")

</div>

OK, I’m going to try to be as thorough as I can here. I have two installations of mautic on a single host:  
  
  
  
1 - /public\_html/mautic  
  
2 - /public\_html/mautica  
  
  
  
Both pointing to two separate databases. Both with functional cron jobs. I create the same campaign on both installations:  
  
  
  
Test  
  
Contact Sources: Test Segment  
  
– Add 10 points  
  
– Send test email  
  
– Add tags  
  
  
  
I create a contact in both systems. I add the contact to the test segment. Until today, on instance 1, all three events fire and I receive the email. On instance 2, all three events fire but I do NOT receive the email. Today, no emails are being sent. Both are using php mail as the delivery mechanism.  
  
  
  
My cron jobs are configured as follows:  
  
  
  
\*/15 \* \* \* \* /usr/bin/php /home4/rbjewell/public\_html/mautica/app/console mautic:leadlists:update -f  
  
\*/15 \* \* \* \* /usr/bin/php -f /home4/rbjewell/public\_html/mautica/app/console mautic:campaigns:update  
  
\*/15 \* \* \* \* /usr/bin/php -f /home4/rbjewell/public\_html/mautica/app/console mautic:campaigns:trigger  
  
\*/15 \* \* \* \* /usr/bin/php -f /home4/rbjewell/public\_html/mautica/app/console mautic:webhooks:process  
  
0 1 \* \* \* /usr/bin/php -f /home4/rbjewell/public\_html/mautica/app/console mautic:fetch:email  
  
0 2 \* \* \* /usr/bin/php -f /home4/rbjewell/public\_html/mautica/app/console mautic:iplookup:download  
  
\*/15 \* \* \* \* /usr/bin/php -f /home4/rbjewell/public\_html/mautica/app/console mautic:email:process  
  
  
  
\*/15 \* \* \* \* /usr/bin/php /home4/rbjewell/public\_html/mautic/app/console mautic:leadlists:update -f \> /dev/null 2\>&1  
  
\*/15 \* \* \* \* /usr/bin/php /home4/rbjewell/public\_html/mautic/app/console mautic:campaigns:update -f \> /dev/null 2\>&1  
  
\*/15 \* \* \* \* /usr/bin/php /home4/rbjewell/public\_html/mautic/app/console mautic:campaigns:trigger -f \> /dev/null 2\>&1  
  
\*/15 \* \* \* \* /usr/bin/php /home4/rbjewell/public\_html/mautic/app/console mautic:webhooks:process -f \> /dev/null 2\>&1  
  
0 1 \* \* \* /usr/bin/php /home4/rbjewell/public\_html/mautic/app/console mautic:fetch:email -f \> /dev/null 2\>&1  
  
0 2 \* \* \* /usr/bin/php /home4/rbjewell/public\_html/mautic/app/console mautic:iplookup:download -f \> /dev/null 2\>&1  
  
\*/15 \* \* \* \* /usr/bin/php /home4/rbjewell/public\_html/mautic/app/console mautic:email:process -f \> /dev/null 2\>&1  
  
  
  
  
  
The output from my mautic:campaigns:trigger looks like this:  
  
  
  
/usr/bin/php -f /home4/rbjewell/public\_html/mautica/app/console mautic:campaigns:trigger  
  
  
  
Triggering events for campaign 2  
  
Triggering first level events  
  
3 total events(s) to be processed in batches of 100  
  
0/3 [\>---------------------------] 0%  
  
1/3 [=========\>------------------] 33%  
  
2/3 [==================\>---------] 66%  
  
3/3 [============================] 100%  
  
3 event(s) executed  
  
  
  
Triggering scheduled events  
  
0 total events(s) to be processed in batches of 100  
  
0 event(s) executed  
  
  
  
Triggering ‘non-action’ events  
  
0 event(s) executed  
  
  
  
If I go to the shell and execute the following php code, the mail is sent fine.

\<?php  
$message = "This is the body of the email.nn";  
$message .= "More body: probably a variable.n";  
$headers="From: slbailey617@comcast.netrn";  
$subject = "This goes in the subject line of the email!";  
$to\_address = "slbailey617@comcast.net";  
$mailsend=mail("$to\_address","$subject","$message" ,"$headers");  
?\>  
  
I can't think of any other information to share to help troubleshoot this. I just can't get either system to actually SEND a message anymore and it was working fine.  
  
Steve

---

<div class="post-metadata">

**Author:** ![Slbailey](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/slbailey/32/78_2.png) [@Slbailey](https://forum.mautic.org/u/Slbailey)\
**Post date:** [May 24, 2016, 3:49pm UTC](https://forum.mautic.org/t/mautictrigger-isnt-sending-emails/3965/2 "2016-05-24T15:49:41Z")

</div>

OK, I’m going to try to be as thorough as I can here. I have two installations of mautic on a single host:

1 - /public\_html/mautic  
2 - /public\_html/mautica

Both pointing to two separate databases. Both with functional cron jobs. I create the same campaign on both installations:

Test  
Contact Sources: Test Segment  
– Add 10 points  
– Send test email  
– Add tags

I create a contact in both systems. I add the contact to the test segment. Until today, on instance 1, all three events fire and I receive the email. On instance 2, all three events fire but I do NOT receive the email. Today, no emails are being sent. Both are using php mail as the delivery mechanism.

My cron jobs are configured as follows:

\*/15 \* \* \* \* /usr/bin/php /home4/rbjewell/public\_html/mautica/app/console mautic:leadlists:update -f  
\*/15 \* \* \* \* /usr/bin/php -f /home4/rbjewell/public\_html/mautica/app/console mautic:campaigns:update  
\*/15 \* \* \* \* /usr/bin/php -f /home4/rbjewell/public\_html/mautica/app/console mautic:campaigns:trigger  
\*/15 \* \* \* \* /usr/bin/php -f /home4/rbjewell/public\_html/mautica/app/console mautic:webhooks:process  
0 1 \* \* \* /usr/bin/php -f /home4/rbjewell/public\_html/mautica/app/console mautic:fetch:email  
0 2 \* \* \* /usr/bin/php -f /home4/rbjewell/public\_html/mautica/app/console mautic:iplookup:download  
\*/15 \* \* \* \* /usr/bin/php -f /home4/rbjewell/public\_html/mautica/app/console mautic:email:process

\*/15 \* \* \* \* /usr/bin/php /home4/rbjewell/public\_html/mautic/app/console mautic:leadlists:update -f \> /dev/null 2\>&1  
\*/15 \* \* \* \* /usr/bin/php /home4/rbjewell/public\_html/mautic/app/console mautic:campaigns:update -f \> /dev/null 2\>&1  
\*/15 \* \* \* \* /usr/bin/php /home4/rbjewell/public\_html/mautic/app/console mautic:campaigns:trigger -f \> /dev/null 2\>&1  
\*/15 \* \* \* \* /usr/bin/php /home4/rbjewell/public\_html/mautic/app/console mautic:webhooks:process -f \> /dev/null 2\>&1  
0 1 \* \* \* /usr/bin/php /home4/rbjewell/public\_html/mautic/app/console mautic:fetch:email -f \> /dev/null 2\>&1  
0 2 \* \* \* /usr/bin/php /home4/rbjewell/public\_html/mautic/app/console mautic:iplookup:download -f \> /dev/null 2\>&1  
\*/15 \* \* \* \* /usr/bin/php /home4/rbjewell/public\_html/mautic/app/console mautic:email:process -f \> /dev/null 2\>&1

The output from my mautic:campaigns:trigger looks like this:

/usr/bin/php -f /home4/rbjewell/public\_html/mautica/app/console mautic:campaigns:trigger

Triggering events for campaign 2  
Triggering first level events  
3 total events(s) to be processed in batches of 100  
0/3 [\>---------------------------] 0%  
1/3 [=========\>------------------] 33%  
2/3 [==================\>---------] 66%  
3/3 [============================] 100%  
3 event(s) executed

Triggering scheduled events  
0 total events(s) to be processed in batches of 100  
0 event(s) executed

Triggering ‘non-action’ events  
0 event(s) executed

If I go to the shell and execute the following php code, the mail is sent fine.

\<?php $message = "This is the body of the email.nn"; $message .= "More body: probably a variable.n"; $headers="From: slbailey617@comcast.netrn"; $subject = "This goes in the subject line of the email!"; $to\_address = "slbailey617@comcast.net"; $mailsend=mail("$to\_address","$subject","$message" ,"$headers"); ?\>

I can’t think of any other information to share to help troubleshoot this. I just can’t get either system to actually SEND a message anymore and it was working fine.

Steve

---

<div class="post-metadata">

**Author:** ![Slbailey](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/slbailey/32/78_2.png) [@Slbailey](https://forum.mautic.org/u/Slbailey)\
**Post date:** [May 25, 2016, 8:40pm UTC](https://forum.mautic.org/t/mautictrigger-isnt-sending-emails/3965/3 "2016-05-25T20:40:26Z")

</div>

Resolved the problem myself.

---

<div class="post-metadata">

**Author:** ![Gustavo](https://avatars.discourse-cdn.com/v4/letter/g/a9adbd/32.png) [@Gustavo](https://forum.mautic.org/u/Gustavo)\
**Post date:** [June 7, 2016, 2:59am UTC](https://forum.mautic.org/t/mautictrigger-isnt-sending-emails/3965/4 "2016-06-07T02:59:00Z")

</div>

Please advise how you did solve it, thank you in advance!

---

<div class="post-metadata">

**Author:** ![Gustavo](https://avatars.discourse-cdn.com/v4/letter/g/a9adbd/32.png) [@Gustavo](https://forum.mautic.org/u/Gustavo)\
**Post date:** [August 14, 2016, 1:22am UTC](https://forum.mautic.org/t/mautictrigger-isnt-sending-emails/3965/5 "2016-08-14T01:22:02Z")

</div>

@Slbailey Hi, would you mind to share how you solve it… Thanks 🙂

---

<div class="post-metadata">

**Author:** ![kinnaert](https://avatars.discourse-cdn.com/v4/letter/k/edb3f5/32.png) [@kinnaert](https://forum.mautic.org/u/kinnaert)\
**Post date:** [August 15, 2016, 4:08pm UTC](https://forum.mautic.org/t/mautictrigger-isnt-sending-emails/3965/6 "2016-08-15T16:08:37Z")

</div>

Yes what was problem??? As I can’t get campaign emails to send, only test emails, and direct to segment list emails work, but not campaign emails.

---

<div class="post-metadata">

**Author:** ![ninjoan](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/ninjoan/32/1005_2.png) [@ninjoan](https://forum.mautic.org/u/ninjoan)\
**Post date:** [August 15, 2016, 8:25pm UTC](https://forum.mautic.org/t/mautictrigger-isnt-sending-emails/3965/7 "2016-08-15T20:25:23Z")

</div>

@kinnaert you have cron job problems.

---

<div class="post-metadata">

**Author:** ![BobbyP](https://avatars.discourse-cdn.com/v4/letter/b/73ab20/32.png) [@BobbyP](https://forum.mautic.org/u/BobbyP)\
**Post date:** [August 16, 2016, 10:57am UTC](https://forum.mautic.org/t/mautictrigger-isnt-sending-emails/3965/8 "2016-08-16T10:57:41Z")

</div>

i solved this issue trough replacing the mautic:email:proccess with  
those two crons  
swiftmailer:email:send  
mautic:emails:send

---

<div class="post-metadata">

**Author:** ![kinnaert](https://avatars.discourse-cdn.com/v4/letter/k/edb3f5/32.png) [@kinnaert](https://forum.mautic.org/u/kinnaert)\
**Post date:** [August 25, 2016, 3:04pm UTC](https://forum.mautic.org/t/mautictrigger-isnt-sending-emails/3965/9 "2016-08-25T15:04:28Z")

</div>

yes I solved by changing cron command to use specfic php verison and path on the server, using only php command without path to correct version made things crash when cron would run
