My VCSA 6.5 does not send emails

Sometimes a VCSA is not able to send emails, as it is not able to validate the sender domain. For example.

The vCenter is configured to send an email as server+bfr-vcsa-01@int.bens.systems over the mail server 10.7.42.23.

Screenshot from 2017-12-13 13-40-56

As sendmail cannot get the correct MX Record for the domain int.bens.systems the from-field in the email header will stay empty and the /var/log/messages.log will show something like this.

2017-10-23T10:48:59.567720+02:00 vcenter sendmail[55361]: v9N8mxa7055361: v9N8mxa8055361: DSN: Data format error
2017-10-23T10:48:59.592809+02:00 vcenter sendmail[55362]: v9N8mxkl055362: from=<server+bfr-vcsa-01@bens.systems>, size=429, class=0, nrcpts=0, proto=ESMTP, daemon=MTA, relay=photon-machine [127.0.0.1]
2017-10-23T10:48:59.607661+02:00 vcenter sendmail[55362]: v9N8mxkm055362: from=<>, size=2421, class=0, nrcpts=1, msgid=<201711020900.v9N8mxa8055361@vcenter.example.com>, proto=ESMTP, daemon=MTA, relay=photon-machine [127.0.0.1]
2017-10-23T10:48:59.644144+02:00 vcenter sendmail[55361]: v9N8mxa8055361: to=admin@bens.systems, delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=31453, relay=[127.0.0.1], dsn=2.0.0, stat=Sent (v9N8mxkm055362 Message accepted for delivery)
2017-10-23T10:49:03.964029+02:00 vcenter sendmail[55364]: v9N8mxkm055362: to=<admin@bens.systems>, delay=00:00:04, xdelay=00:00:04, mailer=relay, pri=122421, relay=mail-int.bens.systems [10.7.42.23], dsn=2.0.0, stat=Sent (Ok: queued as A5EA0B40C3)

To solve the issue we can help the sendmail daemon to find the right mail server for domain int.bens.systems.

For this we need to edit the /etc/hosts file and add something like this.

# email workaround;
# vCenter Email Address: server+bfr-vcsa-01@int.bens.systems
# Smarthost IP: 10.7.42.23

10.7.42.23      int.bens.systems

After this, we have to remove the Mail Settings in the vSphere Web Client, and after saving the changes, add them again.

Now the vCenter should be able to send emails again.

Advertisements

7 thoughts on “My VCSA 6.5 does not send emails

  1. Hey,

    I just had a customer who had the same issue before – fixed by this – then installed a patch for 6.5 that stopped the emails from being sent again.

    /etc/hosts remained configured correctly, but clearing the settings and adding the info again solved the issue.

    Liked by 1 person

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s