SMTP Fail using gmail service

john28uk

Member
Jul 4, 2009
10
0
51
Hi

I am trying to send email via a webform using smtp.gmail.com, the username and password are correct as on our internal server the mail is sent and recevied, but on our webserver the form shows the error SMTP Error: Could not connect to SMTP host.

Do I need to enable something in the WHM??

Thanks John
 

john28uk

Member
Jul 4, 2009
10
0
51
Hello,

There is an issues with the firewall. You will have to enable your port in firewall. For the testing you can disable firewall and check your mail.
Hi, thanks for the reply, was not aware we even have a firewall, how can I see if we have??

John
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,267
463
Hello :)

Do you have root access to this server? If so, you could install a third-party firewall management utility such as CSF to manage your firewall rules.

Thank you.
 

john28uk

Member
Jul 4, 2009
10
0
51
Hello :)

Do you have root access to this server? If so, you could install a third-party firewall management utility such as CSF to manage your firewall rules.

Thank you.
Thanks for the reply, yes I have root access, also been intouch with host, they inform m I have firewall and need to open ports

Thanks John
 
Last edited:

john28uk

Member
Jul 4, 2009
10
0
51
Hello, still having issues with this, I have checked my ports and this /http://www.yougetsignal.com/tools/open-ports/ says 465 is open, but I still get the smtp cannot connect error.

Is there anything else I can do to sort this?

Thanks John
 

john28uk

Member
Jul 4, 2009
10
0
51
Further info, I have run this from root to open up the ports

iptables -A INPUT -m state --state NEW -p tcp --dport 465 -j ACCEPT
iptables -A OUTPUT -m state --state NEW -p tcp --dport 465 -j ACCEPT

Is this the correct way to open the ports?

John
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,267
463
I suggest installing a third-party firewall management utility such as CSF to manage your firewall rules. Also, is this happening for all remote mail servers or is it isolated to Google?

Thank you.
 

john28uk

Member
Jul 4, 2009
10
0
51
I suggest installing a third-party firewall management utility such as CSF to manage your firewall rules. Also, is this happening for all remote mail servers or is it isolated to Google?

Thank you.
Will CSF be able to manage the firewall already installed on there?? Is this a plugin for WHM?

Not sure, only used the smtp.gmail.com
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,267
463
You can add your existing rules to CSF after installing it, and yes it's a plugin for WHM.

Thank you.