Symptoms

Monthly invoice was not sent out from BSS.

Checking one of the email logs in Billing > Logs > Outgoing E-Mail Log the error in comment is as below:

Bad command sequence

To get more details on the issue, tail the bss-scheduler pod using command below:

kubectl logs -l "app=bss,stellart in (scheduler)" --tail=1 -f  --max-log-requests=50

And from the output we can see the following error:

[23-07-03 12:19:01.340 AMAIL2      RQ8241187 TH00061 TRC] AMAIL2: start mail sending
[23-07-03 12:19:01.356 AMAIL2      RQ8241187 TH00061 DBG] Start ESMTP greet
[23-07-03 12:19:01.357 AMAIL2      RQ8241187 TH00061 DBG] ESMTP greet succeeded
[23-07-03 12:19:01.357 AMAIL2      RQ8241187 TH00061 INF] TLS is supported by server
[23-07-03 12:19:01.361 AMAIL2      RQ8241187 TH00061 DBG] TLS init succeeded
[23-07-03 12:19:01.362 AMAIL2      RQ8241187 TH00061 DBG] EHLO greet over TLS completed
[23-07-03 12:19:01.363 AMAIL2      RQ8241187 TH00061 WRN] AMAIL2: mailsmtp_auth failed
[23-07-03 12:19:01.363 AMAIL2      RQ8241187 TH00061 WRN] AMAIL2: RESP=You have been denied authentication due to possible brute-force attempts;
please try again later.
[23-07-03 12:19:01.363 AMAIL2      RQ8241187 TH00061 WRN] AMAIL2 FAILED (2):Bad command sequence

To further confirm the issue, we can then try to send the email using telnet:

telnet <smtp-server> <smtp-port>
EHLO
AUTH LOGIN
334 VXNlcm5hbWU6 <username in base64> 334 UGFzc3dvcmQ6 <password in base64> 535 Incorrect authentication data

Cause

Incorrect password was supplied to a8n-config.


Resolution

Update SMTP password by modifying the value in a8n-config configmap.

1. Edit the configmap

kubectl edit configmap a8n-config

2. Update the value of ENV_SMTP_PASSWORD

3. Save and exit the editor.

4. Restart bss and oss pod

kubectl delete pod -l app=bss -n <namespace>
kubectl delete pod oss-node-0 -n <namespace>