# Mautic Not sending emails

**URL:** <https://forum.mautic.org/t/mautic-not-sending-emails/10471>\
**Category:** Product Support\
**Created:** [May 3, 2018, 11:53am UTC](https://forum.mautic.org/t/mautic-not-sending-emails/10471 "2018-05-03T11:53:26Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![mediamix](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/mediamix/32/679_2.png) [@mediamix](https://forum.mautic.org/u/mediamix)\
**Post date:** [May 3, 2018, 11:53am UTC](https://forum.mautic.org/t/mautic-not-sending-emails/10471/1 "2018-05-03T11:53:26Z")

</div>

I noticed that mautic stopped sending emails when someone filled out a form on our website.

After doing some research, I found that the entries I made to the cron job were not in the daemon user but the root user. I moved them to daemon

Still no emails.

If I run “service cron status”, The following displays

May 03 12:47:01 ubuntu-1 CRON[18355]: pam\_unix(cron:session): session opened for user daemon by (uid=0)  
May 03 12:47:01 ubuntu-1 CRON[18356]: pam\_unix(cron:session): session opened for user daemon by (uid=0)  
May 03 12:47:01 ubuntu-1 CRON[18357]: (daemon) CMD (/usr/local/ispconfig/server/cron.sh 2\>&1 | while read line; do echo `/bin/date` “$line” \>\> /va$)  
May 03 12:47:01 ubuntu-1 CRON[18358]: (daemon) CMD (/usr/local/ispconfig/server/server.sh 2\>&1 | while read line; do echo `/bin/date` “$line” \>\> /$)  
May 03 12:47:01 ubuntu-1 CRON[18355]: pam\_unix(cron:session): session closed for user daemon  
May 03 12:48:01 ubuntu-1 CRON[18382]: pam\_unix(cron:session): session opened for user daemon by (uid=0)  
May 03 12:48:01 ubuntu-1 CRON[18383]: pam\_unix(cron:session): session opened for user daemon by (uid=0)  
May 03 12:48:01 ubuntu-1 CRON[18384]: (daemon) CMD (/usr/local/ispconfig/server/cron.sh 2\>&1 | while read line; do echo `/bin/date` “$line” \>\> /va$)  
May 03 12:48:01 ubuntu-1 CRON[18385]: (daemon) CMD (/usr/local/ispconfig/server/server.sh 2\>&1 | while read line; do echo `/bin/date` “$line” \>\> /$)  
May 03 12:48:01 ubuntu-1 CRON[18382]: pam\_unix(cron:session): session closed for user daemon

Just ran it again and got this:

mediamix@ubuntu-1:~$ service cron status  
● cron.service - Regular background program processing daemon  
Loaded: loaded (/lib/systemd/system/cron.service; enabled; vendor preset: ena  
Active: active (running) since Wed 2018-05-02 11:55:33 EDT; 24h ago  
Docs: man:cron(8)  
Main PID: 1518 (cron)  
Tasks: 1  
Memory: 11.4G  
CPU: 19min 11.231s  
CGroup: /system.slice/cron.service  
└─1518 /usr/sbin/cron -f

May 03 12:50:03 ubuntu-1 getmail[18433]: getmailOperationError error (POP error  
May 03 12:50:05 ubuntu-1 getmail[18433]: getmailOperationError error (POP error  
May 03 12:50:07 ubuntu-1 getmail[18433]: getmailOperationError error (POP error  
May 03 12:50:09 ubuntu-1 getmail[18433]: getmailOperationError error (POP error  
May 03 12:50:11 ubuntu-1 getmail[18433]: getmailOperationError error (POP error  
May 03 12:50:13 ubuntu-1 getmail[18433]: getmailOperationError error (POP error  
May 03 12:50:15 ubuntu-1 getmail[18433]: getmailOperationError error (POP error  
May 03 12:50:21 ubuntu-1 getmail[18433]: getmailOperationError error (POP error  
May 03 12:50:23 ubuntu-1 getmail[18433]: getmailOperationError error (POP error  
May 03 12:50:25 ubuntu-1 getmail[18433]: getmailOperationError error (POP error  
lines 1-21/21 (END)…skipping…  
● cron.service - Regular background program processing daemon  
Loaded: loaded (/lib/systemd/system/cron.service; enabled; vendor preset: enabled)  
Active: active (running) since Wed 2018-05-02 11:55:33 EDT; 24h ago  
Docs: man:cron(8)  
Main PID: 1518 (cron)  
Tasks: 1  
Memory: 11.4G  
CPU: 19min 11.231s  
CGroup: /system.slice/cron.service  
└─1518 /usr/sbin/cron -f

May 03 12:50:03 ubuntu-1 getmail[18433]: getmailOperationError error (POP error (-ERR [AUTH] Authentication failed.))  
May 03 12:50:05 ubuntu-1 getmail[18433]: getmailOperationError error (POP error (-ERR [AUTH] Authentication failed.))  
May 03 12:50:07 ubuntu-1 getmail[18433]: getmailOperationError error (POP error (-ERR [AUTH] Authentication failed.))  
May 03 12:50:09 ubuntu-1 getmail[18433]: getmailOperationError error (POP error (-ERR [AUTH] Authentication failed.))  
May 03 12:50:11 ubuntu-1 getmail[18433]: getmailOperationError error (POP error (-ERR [AUTH] Authentication failed.))  
May 03 12:50:13 ubuntu-1 getmail[18433]: getmailOperationError error (POP error (-ERR [AUTH] Authentication failed.))  
May 03 12:50:15 ubuntu-1 getmail[18433]: getmailOperationError error (POP error (-ERR [AUTH] Authentication failed.))  
May 03 12:50:21 ubuntu-1 getmail[18433]: getmailOperationError error (POP error (-ERR [AUTH] Authentication failed.))  
May 03 12:50:23 ubuntu-1 getmail[18433]: getmailOperationError error (POP error (-ERR [AUTH] Authentication failed.))  
May 03 12:50:25 ubuntu-1 getmail[18433]: getmailOperationError error (POP error (-ERR [AUTH] Authentication failed.))

---

<div class="post-metadata">

**Author:** ![bruno-sassi](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/bruno-sassi/32/318_2.png) [@bruno-sassi](https://forum.mautic.org/u/bruno-sassi)\
**Post date:** [May 7, 2018, 3:19pm UTC](https://forum.mautic.org/t/mautic-not-sending-emails/10471/2 "2018-05-07T15:19:25Z")

</div>

I am having the same problem. Did you find out how to solve it?

---

<div class="post-metadata">

**Author:** ![mediamix](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/mediamix/32/679_2.png) [@mediamix](https://forum.mautic.org/u/mediamix)\
**Post date:** [May 7, 2018, 3:25pm UTC](https://forum.mautic.org/t/mautic-not-sending-emails/10471/3 "2018-05-07T15:25:35Z")

</div>

Yes I did. The problem was in the cron job. What worked for me was adding “sudo php” before each line. Not sure if sudu is needed given that the cron job belongs to the root user

10 \* \* \* \* sudo php /var/www/clients/client1/web1/web/mautic/app/console mautic:segments:update  
10 \* \* \* \* sudo php /var/www/clients/client1/web1/web/mautic/app/console mautic:campaigns:rebuild  
10 \* \* \* \* sudo php /var/www/clients/client1/web1/web/mautic/app/console mautic:campaign:trigger  
01 \* \* \* \* sudo php /var/www/clients/client1/web1/web/mautic/app/console mautic:emails:send  
10 \* \* \* \* sudo php /var/www/clients/client1/web1/web/mautic/app/console mautic:email:fetch  
10 \* \* \* \* sudo php /var/www/clients/client1/web1/web/mautic/app/console mautic:social:monitoring  
10 \* \* \* \* sudo php /var/www/clients/client1/web1/web/mautic/app/console mautic:webhooks:process  
30 2 \* \* \* sudo php /var/www/clients/client1/web1/web/mautic/app/console mautic:iplookup:download  
30 2 \* \* \* sudo php /var/www/clients/client1/web1/web/mautic/app/console mautic:maintenaance:cleanup --days-old=$  
10 \* \* \* \* sudo php /var/www/clients/client1/web1/web/mautic/app/console mautic:broadcasts:send

---

<div class="post-metadata">

**Author:** ![bruno-sassi](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/bruno-sassi/32/318_2.png) [@bruno-sassi](https://forum.mautic.org/u/bruno-sassi)\
**Post date:** [May 7, 2018, 4:04pm UTC](https://forum.mautic.org/t/mautic-not-sending-emails/10471/4 "2018-05-07T16:04:54Z")

</div>

It didn’t work for me, I’m not sure if I did it right, but it looks like a pretty simple solution…  
But thank you for the answer!
