Magento – Magento2 customer emails for sales being received but not admin

emailmagento2order-email

Magento2 customer emails for sales being received but not the admin. Using Magento version 2.1.9

The customer receipt for order, shipping, credit emails are being received, but not admin.

I have already added in an email for each in the bcc area, but email not coming out. I have also changed the receiving email address to different mailboxes from different domains but makes no difference.

We have 2 other Magento2 installs on the same server with same settings that are working fine.
Cron is enabled on all 3 domains and working. Any ideas on how to debug and fix?

Best Answer

I would look if the emails are being sent. To do so, look on your email logs. If you use an SMTP server, it is likely that the provider also have a log over sent emails (charging is based upon sent quantity).

How to locate the log files? https://serverfault.com/questions/59602/where-to-check-log-of-sendmail

Please, below is a quote of above linke. I'm not sure what the best practices are here.

Where are the logs?

The default location depends on your linux/unix system, but the most common places are

  1. /var/log/maillog
  2. /var/log/mail.log
  3. /var/adm/maillog
  4. /var/adm/syslog/mail.log

If it's not there, look up /etc/syslog.conf. You should see something like this

mail.*         -/var/log/maillog

sendmail writes logs to the mail facility of syslog. Therefore, which file it gets written to depends on how syslog was configured.

If you system uses syslog-ng (instead of the more "traditional" syslog), then you'll have to look up your syslog-ng.conf file. You'll should something like this:

# This files are the log come from the mail subsystem.
#
destination mail     { file("/var/log/mail.log"); };
destination maillog  { file("/var/log/maillog"); };
destination mailinfo { file("/var/log/mail.info"); };
destination mailwarn { file("/var/log/mail.warn"); };
destination mailerr  { file("/var/log/mail.err"); };

End of quote.

If you could specify a bit more about your setup (how do you send your emails windows, linux?), and also what type of emails are being sent as admin (and that you miss), it would help.

The other area I would look in, is the email address itself. I have read the email server may refuse to send emails based on email addresses that aren't valid. If you could share it, would be appreciated as well as where in Magento Admin it is entered.

Then, I assume you have checked the spam folder. If you haven't specified your DNS records appropriately, your email is likely to be classified as spam. I've used this service to check before: http://www.mail-tester.com/ (don't know if it is good practice or not, but it gives some guidance).

Last point, check cron tab. I could imagine that the customer emails are one task, while admin is another task. Just a guess.

Related Topic