# Discourse Email does not work after fresh installation (Zoho SMTP server)

**URL:** https://meta.discourse.org/t/discourse-email-does-not-work-after-fresh-installation-zoho-smtp-server/95068
**Category:** Self-hosting
**Tags:** email
**Created:** [8월 18, 2018, 8:40오후 UTC](https://meta.discourse.org/t/discourse-email-does-not-work-after-fresh-installation-zoho-smtp-server/95068 "2018-08-18T20:40:47Z")
**Posts on this page:** 12
**Page:** 1

<div class="post-metadata">

### Author: ![permacultureProgram](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/permacultureprogram/32/108924_2.png) [@permacultureProgram](https://meta.discourse.org/u/permacultureProgram)
#### Post date: [8월 18, 2018, 8:40오후 UTC](https://meta.discourse.org/t/discourse-email-does-not-work-after-fresh-installation-zoho-smtp-server/95068/1 "2018-08-18T20:40:48Z")

</div>

After a fresh install of Discourse on a new Ramnode server following [these instructions](https://github.com/discourse/discourse/blob/master/docs/INSTALL-cloud.md), I am trying to configure the email to interact properly with a Zoho email client. So far, I have not been able to send any emails using Discourse. I’ve already checked out this page: [https://meta.discourse.org/t/cannot-get-email-to-send-using-zoho-mail/45554/4](https://meta.discourse.org/t/cannot-get-email-to-send-using-zoho-mail/45554/4).

When I test my smtp server using swaks, an email is sent properly:

`swaks --to me@example.com --from do-not-reply@sfhepbfree-bayarea.org --server smtp.zoho.com --auth LOGIN --auth-user do-not-reply@sfhepbfree-bayarea.org -tls -p 587`.

This leads me to believe there is an issue with Discourse. Using the following settings:

` DISCOURSE_SMTP_ADDRESS: smtp.zoho.com DISCOURSE_SMTP_PORT: 587 DISCOURSE_SMTP_AUTHENTICATION: "login" DISCOURSE_SMTP_USER_NAME: do-not-reply@sfhepbfree-bayarea.org DISCOURSE_SMTP_PASSWORD: "..." DISCOURSE_SMTP_ENABLE_START_TLS: true # (optional, default true)`

I have received the following error:

`530 Must issue a STARTTLS command first.`

What settings are possible for the `DISCOURSE_SMTP_` variables? Why would email work with swaks but not through Discourse?

---

<div class="post-metadata">

### Author: ![pfaffman](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pfaffman/32/120154_2.png) [@pfaffman](https://meta.discourse.org/u/pfaffman)
#### Post date: [8월 18, 2018, 11:35오후 UTC](https://meta.discourse.org/t/discourse-email-does-not-work-after-fresh-installation-zoho-smtp-server/95068/2 "2018-08-18T23:35:09Z")

</div>

I don’t have any ideas. You might run `./discourse-doctor` and see if its mail debug tester sheds any light.

---

<div class="post-metadata">

### Author: ![itsbhanusharma](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/itsbhanusharma/32/180717_2.png) [@itsbhanusharma](https://meta.discourse.org/u/itsbhanusharma)
#### Post date: [8월 19, 2018, 4:23오전 UTC](https://meta.discourse.org/t/discourse-email-does-not-work-after-fresh-installation-zoho-smtp-server/95068/3 "2018-08-19T04:23:30Z")

</div>

Zoho won’t work for bulk emails. It’s against their policies.

Use mailgun or something similar instead.

---

<div class="post-metadata">

### Author: ![permacultureProgram](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/permacultureprogram/32/108924_2.png) [@permacultureProgram](https://meta.discourse.org/u/permacultureProgram)
#### Post date: [8월 19, 2018, 5:47오후 UTC](https://meta.discourse.org/t/discourse-email-does-not-work-after-fresh-installation-zoho-smtp-server/95068/4 "2018-08-19T17:47:07Z")

</div>

That error is from the `./discourse-doctor`

---

<div class="post-metadata">

### Author: ![permacultureProgram](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/permacultureprogram/32/108924_2.png) [@permacultureProgram](https://meta.discourse.org/u/permacultureProgram)
#### Post date: [8월 19, 2018, 5:47오후 UTC](https://meta.discourse.org/t/discourse-email-does-not-work-after-fresh-installation-zoho-smtp-server/95068/5 "2018-08-19T17:47:33Z")

</div>

Can you point to where in their policies they forbid bulk emails? They just seem to have a strict anti-spam policy…

Anyway, I don’t believe that to be the cause of the technical problem…

---

<div class="post-metadata">

### Author: ![itsbhanusharma](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/itsbhanusharma/32/180717_2.png) [@itsbhanusharma](https://meta.discourse.org/u/itsbhanusharma)
#### Post date: [8월 19, 2018, 7:29오후 UTC](https://meta.discourse.org/t/discourse-email-does-not-work-after-fresh-installation-zoho-smtp-server/95068/6 "2018-08-19T19:29:42Z")

</div>

I just recommended a less painful option for You. If you absolutely gotta have zoho to send emails, try contacting their support as they are the ones who can help with the error code. The recommended email providers do work well for discourse and I don’t see anywhere in the documentation where discourse recommends zoho or google apps for business to send emails.

---

<div class="post-metadata">

### Author: ![pfaffman](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pfaffman/32/120154_2.png) [@pfaffman](https://meta.discourse.org/u/pfaffman)
#### Post date: [8월 20, 2018, 1:37오후 UTC](https://meta.discourse.org/t/discourse-email-does-not-work-after-fresh-installation-zoho-smtp-server/95068/7 "2018-08-20T13:37:20Z")

</div>

And did you rebuild after you made those settings?

Does the host name of your forum match what the mail server is configured for?

---

<div class="post-metadata">

### Author: ![permacultureProgram](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/permacultureprogram/32/108924_2.png) [@permacultureProgram](https://meta.discourse.org/u/permacultureProgram)
#### Post date: [8월 20, 2018, 11:04오후 UTC](https://meta.discourse.org/t/discourse-email-does-not-work-after-fresh-installation-zoho-smtp-server/95068/8 "2018-08-20T23:04:03Z")

</div>

I did rebuild. And I decided to give elasticemail a try. Now, with elasticemail, I have the rather intriguing problem that email works when test emails are sent with `./discourse-doctor` (they arrive in my inbox, receive a 10/10 score at mailtester, etc), but I am not receiving the activation emails when trying to register for the admin account. The logs only say:

` Started POST "/finish-installation/register" for 136.152.143.124 at 2018-08-20 22:58:06 +0000 Processing by FinishInstallationController#register as HTML Parameters: {"utf8"=>"✓", "authenticity_token"=>"S9k3wSRqJ2/M+JNLbWNMu8S8YJ/+0KyaRI+CGbxRxWrzNkfhhT/Fz8+G+hn/DnKl3jSxIYd+mkZf2MqdIW1Z0Q==", "email"=>"pinkardmichael@gmail.com", "username"=>"mpinkard", "password"=>"[FILTERED]", "commit"=>"Register"} Redirected to https://forum.sfhepbfree.org/finish-installation/confirm-email Completed 302 Found in 11ms (ActiveRecord: 1.0ms) Started GET "/finish-installation/confirm-email" for 136.152.143.124 at 2018-08-20 22:58:06 +0000 Processing by FinishInstallationController#confirm_email as HTML Rendering finish_installation/confirm_email.html.erb within layouts/finish_installation Rendered finish_installation/confirm_email.html.erb within layouts/finish_installation (2.0ms) Rendered common/_special_font_face.html.erb (0.5ms) Rendered layouts/_head.html.erb (0.3ms) Completed 200 OK in 7ms (Views: 4.8ms | ActiveRecord: 0.0ms)`

However, the email is not being logged in elasticemail at all. Any ideas?

---

<div class="post-metadata">

### Author: ![pfaffman](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pfaffman/32/120154_2.png) [@pfaffman](https://meta.discourse.org/u/pfaffman)
#### Post date: [8월 20, 2018, 11:06오후 UTC](https://meta.discourse.org/t/discourse-email-does-not-work-after-fresh-installation-zoho-smtp-server/95068/9 "2018-08-20T23:06:03Z")

</div>

I think I’ve seen a problem before where if the first attempt at sending the registration email fails it’s hard to get Discourse to try again.

Try going to `/login` and doing forgot password.

---

<div class="post-metadata">

### Author: ![permacultureProgram](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/permacultureprogram/32/108924_2.png) [@permacultureProgram](https://meta.discourse.org/u/permacultureProgram)
#### Post date: [8월 20, 2018, 11:09오후 UTC](https://meta.discourse.org/t/discourse-email-does-not-work-after-fresh-installation-zoho-smtp-server/95068/10 "2018-08-20T23:09:09Z")

</div>

Nice! That worked! Thanks so much!

That information should perhaps be added to the email troubleshooting page?

---

<div class="post-metadata">

### Author: ![pfaffman](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pfaffman/32/120154_2.png) [@pfaffman](https://meta.discourse.org/u/pfaffman)
#### Post date: [8월 20, 2018, 11:14오후 UTC](https://meta.discourse.org/t/discourse-email-does-not-work-after-fresh-installation-zoho-smtp-server/95068/11 "2018-08-20T23:14:27Z")

</div>

Well, I think it’s more of a bug/UX issue that I’ve reported here: [Wizard will not send validation email more than once - #5 by codinghorror](https://meta.discourse.org/t/wizard-will-not-send-validation-email-more-than-once/77175/5).

@gerhard, did you have a chance to take a look?

---

<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: [9월 19, 2018, 11:21오후 UTC](https://meta.discourse.org/t/discourse-email-does-not-work-after-fresh-installation-zoho-smtp-server/95068/12 "2018-09-19T23:21:34Z")

</div>

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