News:

SMF 2.1.6 has been released! Take it for a spin! Read more.

Main Menu

Unable to send mail via SMTP

Started by random539, June 12, 2023, 06:54:30 PM

Previous topic - Next topic

random539

Hi all,

I recently migrated my forum from a hosting provider to a server I set up at my house.  Here's my version info:

SMF 2.0.19 (yes, I'm planning on upgrading to 2.1 soon)
PHP 7.4.33
MySQL 10.9.4

Everything's running great except I cannot get the forum to send emails via SMTP (before I think I was sending via the builtin php function).  I've tried prefixing the server name with tls:// and ssl:// as well as trying ports 587 and 465.  I can connect to the smtp server via telnet on both of those ports.  The server in question does not listen on port 25 - might that be a problem?

I have access to the SMTP server in question and thus am able to watch the logs, but I don't see my forum even trying to connect.  Another concern is I do not see anything mail-related in my SMF log, which makes troubleshooting difficult.

Anyone have ideas on what to do next?  It would be great if I could see output from Subs-Post.php but I have no knowledge of php so I'm not sure how to go about that.

Thanks!

random539

I figured it out; part of the problem was that I was testing by mentioning myself (which doesn't trigger an email notification) and the other problem was I was grep'ing my mail log by username and not IP.  After figuring that out I was able to discover that I had to use port 465, and the host has to be prefixed with ssl:// or tls:// (for my SMTP server anyway).

Sorry to clutter up the board with my stupidity  ::)

Steve

Quote from: random539 on June 12, 2023, 08:38:14 PMSorry to clutter up the board with my stupidity
1. You're not cluttering up the board because someone else having the same problem could find the answer in your post.

2. As for stupidity, I wouldn't call it that since we all do it.  ;)
My pet rock is not feeling well. I think it's stoned.

Advertisement: