• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

XF 1.5 Sending emails through Google Apps for Work

#1
Last month, I switched my email hosting from my web hosting provider (which is where my forum is hosted) to Google Apps for Work. Since then, emails aren't being sent from the forum.

I've tried all the possible settings, and set up SMTP relaying on Google. Does anyone know the trick to get this to work?

Thanks.
 
#3
Yes, those threads are several years old. I've tried a variety of combinations - server, port, encryption type - and I can't seem to get it to work. I also can't find how to test it from the Xenforo admin section.
 

Fred.

Well-known member
#4
Please post a screenshot of your Xenforo e-mail settings or post them here. (smtp, port, authentication, encryption)

Your domain is properly connected to your Google apps account?
You can just use the contact form to test.
 

ENF

Well-known member
#5
Yes, those threads are several years old. I've tried a variety of combinations - server, port, encryption type - and I can't seem to get it to work. I also can't find how to test it from the Xenforo admin section.
Hi, we are using Google Apps for Work now and here's a screenshot of our configuration as of today:

mail_config_ga.JPG

Most important:
Username should be your full email address (user@mydomain.com) -- and that should be a valid account on your GA domain.
Example: We have a postmaster@ourdomain.com account in Google Apps that used for handing all mail services.
Make sure you can log into and use that account before setting XF to handle the settings.

Also, if you have error logs from XF, please share those with us to help you.

My only complaint about GA mail services is the fact that we bang the sending limit (~2,000 emails/day) which causes us to have to swap the email config when the load is high. We've been working with our users to reduce email notifications, which has been helping.

Let us know how it goes for you.
 
#6
My email account works fine with Google.

Attached is a screenshot of my settings.

And here is the log from one of the error messages:



#0 /home/mcelsijw/public_html/forum/library/Zend/Mail/Protocol/Smtp.php(167): Zend_Mail_Protocol_Abstract->_connect('tcp://smtp.gmai...')
#1 /home/mcelsijw/public_html/forum/library/Zend/Mail/Transport/Smtp.php(216): Zend_Mail_Protocol_Smtp->connect()
#2 /home/mcelsijw/public_html/forum/library/Zend/Mail/Transport/Abstract.php(348): Zend_Mail_Transport_Smtp->_sendMail()
#3 /home/mcelsijw/public_html/forum/library/Zend/Mail.php(1194): Zend_Mail_Transport_Abstract->send(Object(Zend_Mail))
#4 /home/mcelsijw/public_html/forum/library/XenForo/Mail.php(175): Zend_Mail->send(Object(Zend_Mail_Transport_Smtp))
#5 /home/mcelsijw/public_html/forum/library/XenForo/ControllerPublic/Misc.php(217): XenForo_Mail->sendMail(Object(Zend_Mail))
#6 /home/mcelsijw/public_html/forum/library/XenForo/FrontController.php(351): XenForo_ControllerPublic_Misc->actionContact()
#7 /home/mcelsijw/public_html/forum/library/XenForo/FrontController.php(134): XenForo_FrontController->dispatch(Object(XenForo_RouteMatch))
#8 /home/mcelsijw/public_html/forum/index.php(13): XenForo_FrontController->run()
#9 {main}
Request State
array(3) {
["url"] => string(39) "http://forum.mcelhearn.com/misc/contact"
["_GET"] => array(0) {
}
["_POST"] => array(7) {
["subject"] => string(4) "Test"
["message"] => string(4) "test"
["_xfToken"] => string(8) "********"
["redirect"] => string(27) "http://forum.mcelhearn.com/"
["_xfRequestUri"] => string(1) "/"
["_xfNoRedirect"] => string(1) "1"
["_xfResponseType"] => string(4) "json"
}
}
 

Attachments

#10
You mean on my web host's firewall? I don't even know if there is a firewall or any ports being blocked on my host. This all worked fine until I switched to Google...
 

Mike

XenForo developer
Staff member
#11
Yeah, this is a network/firewall issue. That's the error coming from the underlying OS network call when trying to connect to Google (or potentially any external site). You'll need to contact your host regarding this.
 
#12
Yes, that was it. Thanks for your help.

It would have been more useful if the error message was clearer. Also, this has been going on for a month, and I only found out because a few new users weren't getting their confirmation emails. Perhaps there could be a better way of indicating to admins when errors occur. I only log into the admin panel when I need to.