Problems sending email through sendgrid

(Keith Newton) #1

I’m trying to set up discourse to send emails through sendgrid and have run into some problems. I configured postfix per the sendgrid documentation as well as production.rb however it doesn’t seem like the email is ever reaching sendgrid. It looks like postfix is trying to connect directly to the destination email address:

Sep 22 09:05:27 LinuxDev postfix/smtp[4061]: 3E37810502C: to=<>, relay=none, delay=810, delays=660/0.11/150/0, dsn=4.4.1, status=deferred (connect to[]:25: Connection timed out)
Sep 22 09:22:56 LinuxDev postfix/qmgr[3683]: 10FCB105025: from=<>, size=7580, nrcpt=1 (queue active)
Sep 22 09:22:56 LinuxDev postfix/qmgr[3683]: 3E37810502C: from=<>, size=5883, nrcpt=1 (queue active)
Sep 22 09:23:27 LinuxDev postfix/smtp[4595]: connect to[]:25: Connection timed out
Sep 22 09:23:27 LinuxDev postfix/smtp[4594]: connect to[]:25: Connection timed out
Sep 22 09:23:27 LinuxDev postfix/smtp[4594]: connect to[2607:f8b0:400e:c01::1b]:25: Network is unreachable
Sep 22 09:23:57 LinuxDev postfix/smtp[4595]: connect to[]:25: Connection timed out
Sep 22 09:23:57 LinuxDev postfix/smtp[4594]: connect to[]:25: Connection timed out

For some reason it’s also constantly trying to connect to google. Perhaps the last email I tried to send, which was to a gmail address, is stuck in a queue where Discourse is continually trying to send it?

(Jeff Atwood) #2

Did you ever get this working? I recommend trying our new Docker based configuration.

(Keith Newton) #3

Yes I did get it working though unfortunately I forget what the problem was. Thanks for following up!

(Arpit Jalan) #4

Glad you got it working! Are you running your Discourse instance on Docker based setup?

If not, I heavily recommend you to switch to Docker based configuration (which is the only one, officially supported by Discourse).

Here is the guide which makes switching to Docker based configuration a breeze:

(Keith Newton) #5

I am not running Discourse in a Docker setup as my last update was in November. After looking at all of the Docker guides/info I’m afraid that, while Docker looks great and I’ll be upgrading to the latest Discourse soon, switching to it at this point looks like the perfect way to break everything I already have working. I understand being an early adopter means working on the bleeding edge and that sometimes you get cut. However the fact that you guys have had to switch to this an entire year later perfectly sums up my only frustration with this project - your choice to go with Ruby on Rails and Linux. The decreased performance, increased memory usage, and most importantly the absolute maintenance nightmare that is working with both Ruby and Linux is a source of endless frustration that I only continue to deal with because you have built such a superior user experience.

Sorry, that’s been building for the last 8 months, I just had to get it off my chest. Since all of that is water under the bridge at this point keep up the great work and perhaps someday I’ll have the time to take the plunge with Docker.

(Jeff Atwood) #6

It’s easy on Docker though :wink:

(Paul Apostolos) #7

Just to chime in on the side of Docker here…Our initial install was using the old Ubuntu setup instructions. Updates and issue resolution were way more difficult than the process of migration to the Docker installation. Now updates are LITERALLY as easy as clicking a button. (And perhaps refereshing the screen a few times ;))

You should try an install of it locally (VirtualBox, VMWare or Hyper-V) and try a migration. It’s really worth it.