AMC does not send email alerts until logged in to console
When AMC is being used to monitor an Aerospike cluster there is a facility to configure email alerts by editing the
mailer stanza of
/etc/amc/amc.conf. When this has been done and AMC has been started there are no email alerts sent, regardless of cluster state, until the AMC console has been accessed via web browser.
This issue will manifest when there has been no cluster configured for monitoring in
/etc/amc/amc.conf. Until this is done, AMC is not aware of any clusters to be monitored. Logging in to AMC via the web browser requires a cluster to be selected for monitoring. At this point AMC has something to monitor and so will send alert emails as appropriate. This is expected behaviour.
To ensure that email alerts are sent all the time an entry should be made in
/etc/amc/amc.conf in the
amc.clusters stanza. This means that as soon as AMC starts it will monitor the chosen cluster and send email alerts. An example is shown below:
[amc.clusters.db1] host = "172.17.0.3" port = 3000 show_in_ui = true
AMC EMAIL ALERT NOT SENT
27 June 2019