Email sending fails.
Email sending fails.
2023-06-24T11:48:35.798293Z WARN lemmy_server::root_span_builder: email_send_failed: Connection error: failed to lookup address information: Try again 0: lemmy_api::local_user::reset_password::perform at crates/api/src/local_user/reset_password.rs:15 1: lemmy_server::root_span_builder::HTTP request with http.method=POST http.scheme="http" http.host=iusearchlinux.fyi http.target=/api/v3/user/password_reset otel.kind="server" request_id=ba8117b9-9c0f-49e5-af0e-01e92a4917cf at src/root_span_builder.rs:16 LemmyError { message: Some("email_send_failed"), inner: Connection error: failed to lookup address information: Try again Caused by: failed to lookup address information: Try again, context: SpanTrace [{ target: "lemmy_api::local_user::reset_password", name: "perform", file: "crates/api/src/local_user/reset_password.rs", line: 15 }, { target: "lemmy_server::root_span_builder", name: "HTTP request", fields: "http.method=POST http.scheme=\"http\" http.host=iusearchlinux.fyi http.target=/api/v3/user/password_reset otel.kind=\"server\" request_id=ba8117b9-9c0f-49e5-af0e-01e92a4917cf", file: "src/root_span_builder.rs", line: 16 }] } 2023-06-24T11:48:46.118615Z WARN lemmy_server::root_span_builder: data did not match any variant of untagged enum AnnouncableActivities 0: lemmy_apub::activities::community::announce::receive at crates/apub/src/activities/community/announce.rs:46 1: lemmy_server::root_span_builder::HTTP request with http.method=POST http.scheme="http" http.host=iusearchlinux.fyi http.target=/inbox otel.kind="server" request_id=0d639361-7707-4f9b-b61f-fc133d3946e7 at src/root_span_builder.rs:16
I am using the lemmy-ansible setup on ubuntu 22.10
@soeren@iusearchlinux.fyi I got this figured out with the help of @tool@r.rosettast0ned.com from this thread: https://lemmy.pub/comment/112090
This almost fixed it. So no more error in Lemmy. Now I get this error in postfix:
2023-06-25T07:44:48.221806+00:00 f42cba971055 postfix/bounce[150]: B5C5E99B88: sender non-delivery notification: 34AF199B8A 2023-06-25T07:44:48.221897+00:00 f42cba971055 postfix/qmgr[134]: 34AF199B8A: from=<>, size=4451, nrcpt=1 (queue active) 2023-06-25T07:44:48.222390+00:00 f42cba971055 postfix/qmgr[134]: B5C5E99B88: removed 2023-06-25T07:44:48.226425+00:00 f42cba971055 postfix/smtp[149]: connect to iusearchlinux.fyi[2a03:b0c0:3:d0::1b5f:9001]:25: Cannot assign requested address 2023-06-25T07:44:48.226554+00:00 f42cba971055 postfix/smtp[149]: connect to iusearchlinux.fyi[46.101.183.128]:25: Connection refused 2023-06-25T07:44:48.240297+00:00 f42cba971055 postfix/smtp[149]: 34AF199B8A: to=<noreply@iusearchlinux.fyi>, relay=none, delay=0.01, delays=0.01/0/0/0, dsn=4.4.1, status=deferred (connect to iusearchlinux.fyi[46.101.183.128]:25: Connection refused) 2023-06-25T07:45:47.742485+00:00 f42cba971055 postfix/smtpd[146]: disconnect from iusearchlinuxfyi-lemmy-1.iusearchlinuxfyi_lemmyexternalproxy[172.22.0.3] ehlo=1 quit=1 commands=2 2023-06-25T07:45:47.742847+00:00 f42cba971055 postfix/smtpd[144]: disconnect from iusearchlinuxfyi-lemmy-1.iusearchlinuxfyi_lemmyexternalproxy[172.22.0.3] ehlo=1 mail=1 rcpt=1 data=1 quit=1 commands=5
Well that would make sense. That domain has no MX record. Nor SPF, DMARC or even PTR records set.
That looks like a misconfig somewhere.
the flow should be
Lemmy APP see's request to email something@gmail.com. --> Postfix looks up something@gmail.com --> gets MX record --> connects to gmail.com --> Does HELO/EHLO ahndshake --> Sends email.
Your server is stuck here
Lemmy APP see's request to email something@iusearchlinux.fyi. --> Postfix looks up something@iusearchlinux.fyi --> Error no mx record for this domain...close
You are either testing with a misconfigured domain/email address, or you have configured postfix to try and relay through iusearchlinux.fyi domain, which is misconfigured on the email side.
At the very least you should have an SPF record, a DMARC record and a PTR/A record for the domain. All I see is an A record there.
I would double/triple check your config.hjson and docker-compose.yml and make sure you didnt try and setup relay ala: https://github.com/wader/postfix-relay#relay-client-authentication