SMTP Emails Not Sending

Jeremy P

XenForo developer
Staff member
I am using Google Apps to power email for the domain, and to prevent being marked as spam, have configured XenForo to send mails through Google's SMTP servers. However, emails aren't being sent.

I am certain it is configured properly, and have tested it with equivalent settings using PHPMailer on the server, which was able to send them fine. When I test is with a contact email in XenForo, no errors are given, but yet the email is not received.

I'm not sure if this is a bug in the software, or what could be preventing them from being sent, but I would appreciate any help or information on the problem.

Thanks.
 
Hi,

I can confirm that Google Apps SMTP works with the current build of XenForo.

My specific settings that work:

SMTP: smtp.gmail.com Port: 587
Username: myaccount@mydomain.com (matching password set correctly)
Encryption: TLS

The sent email appears correctly in the "sent" items on the account used to send mails and the target email address receives the email correctly.
 
I am using Google Apps to power email for the domain, and to prevent being marked as spam, have configured XenForo to send mails through Google's SMTP servers. However, emails aren't being sent.

I am certain it is configured properly, and have tested it with equivalent settings using PHPMailer on the server, which was able to send them fine. When I test is with a contact email in XenForo, no errors are given, but yet the email is not received.

I'm not sure if this is a bug in the software, or what could be preventing them from being sent, but I would appreciate any help or information on the problem.

Thanks.
Are you using a shared hosting ?
 
Still no luck. I was using SSL on port 465, and as I said I have tested the configuration with PHPMailer, which was able to send them fine. Would there be something required on the server-side that is XenForo/Zend_Mail specific to send via SMTP?
 
The PHP mail settings should have no impact on SMTP usage.

If I'm not mistaken, using the SMTP option (vs. default) in XenForo skips the mail configuration in PHP and strictly uses SMTP.
 
The PHP mail settings should have no impact on SMTP usage.

If I'm not mistaken, using the SMTP option (vs. default) in XenForo skips the mail configuration in PHP and strictly uses SMTP.
Yes you are absolutely right ! and that's why phpmail works and not SMTP.
Check your IP tables man! your port is blocked (most likely)
 
The PHP mail settings should have no impact on SMTP usage.


If I'm not mistaken, using the SMTP option (vs. default) in XenForo skips the mail configuration in PHP and strictly uses SMTP.
That is what I was thinking.
Yes you are absolutely right ! and that's why phpmail works and not SMTP.
Check your IP tables man! your port is blocked (most likely)
I have tried disabling the firewall entirely with no luck. When I say PHPMailer, I mean this, which is a library for sending directly via SMTP as well. Using that, the email sends fine. I am very puzzled as to why it won't work with XenForo.
 
That is what I was thinking.

I have tried disabling the firewall entirely with no luck. When I say PHPMailer, I mean this, which is a library for sending directly via SMTP as well. Using that, the email sends fine. I am very puzzled as to why it won't work with XenForo.

Just purge sendmail and install postfix. The only option left is that sendmail is not configured properly and I am certain postfix will work out of the box (I tired it on several xenforo installations for members on here)
 
gmailsmtpconfig.webp
Just for posterity, I've attached my SMTP configuration screen capture from XenForo.

The only other things I can suggest is trying the different port. Google Apps specifies that TLS be used with port 587. SSL is 465. (http://mail.google.com/support/bin/answer.py?hl=en&answer=13287)

So, if you have not tried it, use port 587 in XenForo, using the TLS option.

Let us know how it turns out.

Edit: My point here, I've had problems in the past in using SSL with Google Apps. TLS has been more reliable and always works, whereas SSL just wouldn't work in some cases.
 
Just purge sendmail and install postfix. The only option left is that sendmail is not configured properly and I am certain postfix will work out of the box (I tired it on several xenforo installations for members on here)
I have dropped sendmail and installed postfix, not sure it would make much of a difference here, but just in case. Still no luck.

Edit: My point here, I've had problems in the past in using SSL with Google Apps. TLS has been more reliable and always works, whereas SSL just wouldn't work in some cases.
I appreciate the help, unfortunately neither option will work for me. The only thing I can think of is I am overlooking a very simple typo, however after checking over and over, I don't believe I am. Any other suggestions?
 

Attachments

  • Screen shot 2010-10-13 at 8.29.18 PM.webp
    Screen shot 2010-10-13 at 8.29.18 PM.webp
    11.9 KB · Views: 54
I have dropped sendmail and installed postfix, not sure it would make much of a difference here, but just in case. Still no luck.


I appreciate the help, unfortunately neither option will work for me. The only thing I can think of is I am overlooking a very simple typo, however after checking over and over, I don't believe I am. Any other suggestions?
Does the default work ?
 
I'm out of suggestions, it's probably time to poke Kier or Mike to see if there is anything else that could be missing.

XenForo needs a logging bin for mail server issues. Or, a test mail option that reports back the result.

In the current state, we can't even tell if XenForo is even attempting to authenticate to Google's SMTP service.

I've looked at this in every way possible and cannot pinpoint anything specifically. I'm still learning the XenForo structure; I don't know it nearly as well as VB (yet).
 
We could definitely use debugging for this. I did tests with my Gmail account and didn't have any issues sending, but I did routinely make a mistake entering the options. :)
 
Top Bottom