# Não recebo e-mail de registro, mas o servidor SMTP funciona bem

**URL:** https://meta.discourse.org/t/dont-get-registration-mail-but-smtp-server-works-fine/113272
**Category:** Self-hosting
**Created:** [2 Abril , 2019 21:44 UTC](https://meta.discourse.org/t/dont-get-registration-mail-but-smtp-server-works-fine/113272 "2019-04-02T21:44:23Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![IMSth](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/imsth/32/135435_2.png) [@IMSth](https://meta.discourse.org/u/IMSth)
#### Post date: [2 Abril , 2019 21:44 UTC](https://meta.discourse.org/t/dont-get-registration-mail-but-smtp-server-works-fine/113272/1 "2019-04-02T21:44:24Z")

</div>

Hi

I would like to install Discource but I have one BIG problem. I didn’t receive a registration email.  
I use Elastic Email as an SMTP provider. I check connection (use node application) - credentials are ok and I can send an email.

I’ve checked on two different servers (one on OVH, on my machine - Debians) - both don’t work.  
No logs with email.

`discource-doctor` said that `SMTP server connection successful.`  
In `cat shared/standalone/log/rails/production.log` I can see `Sent mail to MY_EMAIL_ACCOUNT@gmail.com (439.1ms)`

`telnet smtp.elasticemail.com 2525` says `Connected to smtp.elasticemail.com.`

**Any ideas ?**

---

<div class="post-metadata">

### Author: ![Corsterix](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/corsterix/32/135849_2.png) [@Corsterix](https://meta.discourse.org/u/Corsterix)
#### Post date: [2 Abril , 2019 22:04 UTC](https://meta.discourse.org/t/dont-get-registration-mail-but-smtp-server-works-fine/113272/2 "2019-04-02T22:04:55Z")

</div>

Did you check your spam folder?

When I first set up Discourse on one of my sites it went to spam because the email was coming from [forum.domain.com](http://forum.domain.com) instead of [domain.com](http://domain.com), once I fixed that the emails came through fine.

---

<div class="post-metadata">

### Author: ![IMSth](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/imsth/32/135435_2.png) [@IMSth](https://meta.discourse.org/u/IMSth)
#### Post date: [3 Abril , 2019 16:14 UTC](https://meta.discourse.org/t/dont-get-registration-mail-but-smtp-server-works-fine/113272/3 "2019-04-03T16:14:34Z")

</div>

Yes, I’ve checked spam folder.  
The most weird thing is that in Elastic Mail I can’t see, that EM sent message. Sent messages counter is 0 . So Discource didn’t connect to SMTP server, so it could not send a message.

---

<div class="post-metadata">

### Author: ![Corsterix](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/corsterix/32/135849_2.png) [@Corsterix](https://meta.discourse.org/u/Corsterix)
#### Post date: [3 Abril , 2019 18:13 UTC](https://meta.discourse.org/t/dont-get-registration-mail-but-smtp-server-works-fine/113272/4 "2019-04-03T18:13:48Z")

</div>

I just noticed your telnet to 2525, did you configure app.yml correctly?

`DISCOURSE_SMTP_PORT: `

Also, what’s your protocol set to in Elastic Mail?

---

<div class="post-metadata">

### Author: ![IMSth](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/imsth/32/135435_2.png) [@IMSth](https://meta.discourse.org/u/IMSth)
#### Post date: [3 Abril , 2019 21:34 UTC](https://meta.discourse.org/t/dont-get-registration-mail-but-smtp-server-works-fine/113272/5 "2019-04-03T21:34:55Z")

</div>

What does it mean `protocol set to in Elastic Mail`?

I’ve checked Mailjet - I’ve got message 😲

---

<div class="post-metadata">

### Author: ![IMSth](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/imsth/32/135435_2.png) [@IMSth](https://meta.discourse.org/u/IMSth)
#### Post date: [3 Abril , 2019 21:35 UTC](https://meta.discourse.org/t/dont-get-registration-mail-but-smtp-server-works-fine/113272/6 "2019-04-03T21:35:47Z")

</div>

> [@Corsterix](#):
>
> When I first set up Discourse on one of my sites it went to spam because the email was coming from [forum.domain.com](http://forum.domain.com) instead of [domain.com](http://domain.com), once I fixed that the emails came through fine.

@Corsterix How do you resolve wrong domain ? Uncomment `- exec: rails r "SiteSetting.notification_email='noreply@DOMAINl'"` ?

---

<div class="post-metadata">

### Author: ![IMSth](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/imsth/32/135435_2.png) [@IMSth](https://meta.discourse.org/u/IMSth)
#### Post date: [3 Abril , 2019 21:37 UTC](https://meta.discourse.org/t/dont-get-registration-mail-but-smtp-server-works-fine/113272/7 "2019-04-03T21:37:19Z")

</div>

**I found a solution !**

I have server on OVH, which probably block 25 and 2525 port. And another related with SMTP.

When I choose port on 587 everything works !

---

<div class="post-metadata">

### Author: ![system](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/system/32/443519_2.png) [@system](https://meta.discourse.org/u/system)
#### Post date: [3 Maio , 2019 21:37 UTC](https://meta.discourse.org/t/dont-get-registration-mail-but-smtp-server-works-fine/113272/8 "2019-05-03T21:37:20Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
