Skip to content
Init is here / May 19 - 23
Back

Emails sometimes not sending

  • 0
  • Self Hosted
WhiteWalker72
10 Jan, 2024, 16:42

Hi, i'm using Appwrite self hosted (v 1.4.13) and I have SMTP configured. When we try to login we don't always receive the login email. Sometimes it works, sometimes it doesn't. We are using AWS SES (sandbox mode) to send the emails.

Sometimes it works so I don't think its the configuration itself. It looks like a connection issue between the Appwrite container and SES but I can't pinpoint what it is. Could it be that Appwrite creates a connection, tries to do some logic which takes time and then tries to send the email? Because it looks like the connection is open for too long, no data is received so the connection is closed again.

The errors in the "worker-mails" container are:

TypeScript
[Job] Received Job (659ebbe9e5bce9.98065278).
[Job] (659ebbe9e5bce9.98065278) failed to run.
[Job] (659ebbe9e5bce9.98065278) Error sending mail: SMTP Error: data not accepted.
[Error] Type: Exception
[Error] Message: Error sending mail: SMTP Error: data not accepted.
[Error] File: /usr/src/code/src/Appwrite/Platform/Workers/Mails.php
[Error] Line: 96
TypeScript
[Job] Received Job (659ebbffdde282.22334188).
[Job] (659ebbffdde282.22334188) failed to run.
[Job] (659ebbffdde282.22334188) Error sending mail: The following From address failed: noreply@project.preprod.aws.coffeeit.nl : MAIL FROM command failed,Timeout waiting for data from client.
,451,4.4.2SMTP server error: MAIL FROM command failed Detail: Timeout waiting for data from client.
 SMTP code: 451 Additional SMTP info: 4.4.2
[Error] Type: Exception
[Error] Message: Error sending mail: The following From address failed: noreply@project.preprod.aws.coffeeit.nl : MAIL FROM command failed,Timeout waiting for data from client.
,451,4.4.2SMTP server error: MAIL FROM command failed Detail: Timeout waiting for data from client.
 SMTP code: 451 Additional SMTP info: 4.4.2
[Error] File: /usr/src/code/src/Appwrite/Platform/Workers/Mails.php
[Error] Line: 96
TL;DR
The user is having issues with emails sometimes not sending in Appwrite self-hosted version 1.4.13. They have SMTP configured with AWS SES in sandbox mode. They suspect a connection issue between the Appwrite container and SES. The error messages in the "worker-mails" container indicate SMTP errors: "SMTP Error: data not accepted" and "MAIL FROM command failed, Timeout waiting for data from client". Solution: It's possible that Appwrite creates a connection, performs some logic, and then tries to send the email, which may take too long and result in a closed connection. To resolve the issue, the user
Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more