Emails are not sent from vCenter Server Appliance 6.5 or 6.7 after an Alert/Event is triggered.
search cancel

Emails are not sent from vCenter Server Appliance 6.5 or 6.7 after an Alert/Event is triggered.


Article ID: 321441


Updated On:


VMware vCenter Server


  • Alert/Event is triggered but action mail is not being sent from vCenter Server Appliance 6.5.
  • In /var/log/vmware/messages, you see entries similar to
sendmail[24224]: w0VHA0uD024224: [email protected], size=548, class=0, nrcpts=1, msgid=<[email protected]>, relay=root@localhost
sendmail[24224]: w0VHA0uD024224: [email protected], delay=00:01:05, mailer=esmtp, pri=30548, dsn=4.4.3, stat=queued
sendmail[918]: w2M2CHDc000918:, size=516, class=0, nrcpts=1, msgid=<>, relay=root@localhost
sendmail[920]: w2M2CHqc000920: ruleset=check_mail, arg1=<[email protected]>, relay=photon-machine [], reject=451 4.1.8 Domain of sender address [email protected] does not resolve
sendmail[918]: w2M2CHDc000918: [email protected], [email protected] (0/0), delay=00:01:07, xdelay=00:01:07, mailer=relay, pri=30516, relay=[] [], dsn=4.0.0, stat=Deferred: 451 4.1.8 Domain of sender address [email protected] does not resolve


VMware vCenter Server 8.0.x
VMware vCenter Server 6.7.x
VMware vCenter Server 7.0.x
VMware vCenter Server Appliance 6.5.x


This issue occurs when sendmail is failing to resolve the configured recipients domain or if the relay host is rejecting the senders email address (root@localhost).


To resolve the issue follow the below steps:

Note1: Prior to applying resolution ensure you take a offline backup or snapshot of the vCenter Server Appliance. 
Note2: The applied configuration change may be lost after upgrade. In such case, Please apply the steps again.

1. Connect to vCenter Server Appliance via ssh.
2. Edit sendmail.service using the vi editor.

vi /etc/systemd/system/sendmail.service

In recent releases, the file may be at different directory.

Case you do not find the sendmail.service under /etc/systemd/system, check the path beneath: 


3. Alter the After entry under [Unit] section to be as follows:

    : systemd-resolved.service
4. Save the changes and close the editor.
5. Open using vi editor:


6. Add following entry after OSTYPE:

define(`SMART_HOST', `[Your_mail_host]')dnl

Note: change Your_mail_host to reflect the correct mail server hostname.

7. Save the change and close the editor.
8. Next, edit using the vi editor.

vi /etc/mail/

9. Add the following line at the end of the define entries:


10. Save the change and close the editor.
11. Verify that local hostname is present and is resolvable in hosts file.


12. Execute following command and generate new .cf file

cd /etc/mail
m4 m4/cf.m4 >
m4 m4/cf.m4 >

13. Reload system daemon and restart sendmail.

systemctl daemon-reload
systemctl restart sendmail


At this point, the vCenter should be able to send emails to the mail server; however, the emails will be sent as root@localhost. Validate it by sending a test alarm and checking the messages log under /var/log/vmware/.

Once validated: 

  1. Make a backup copy of the file
  2. is a read-only file. The permissions on this file must first be changed with this command: 
chmod 644 /etc/mail/
  1. ​​​​​ Edit with the vi editor
vi /etc/mail/
  1. After the "DS", enter the FQDN of the mail server
  2. Save the file
  3. Change the file's permission back to the original permissions:
chmod 444 /etc/mail/

For example, if the mail server FQDN is:
​# "Smart" relay host (may be null or contain IP address)
DS []
  1. Restart sendmail daemon using systemd.

systemctl restart sendmail