Test mail not sending in drupal 7 SMTP configuration in windows 2012 server - smtp

I installed and configured SMTP module with proper details in Drupal 7. I tried to send test the mail in Windows 2012 server but am getting the below error.
SMTP -> ERROR: Failed to connect to server: php_network_getaddresses: getaddrinfo failed: This is usually a temporary error during hostname resolution and means that the local server did not receive a response from an authoritative server. (0)
SMTP Error: Could not connect to SMTP host.
Unable to send e-mail. Contact the site administrator if the problem persists.
The same build is working fine in Windows XP, 07, and Ubuntu environments. What is causing this problem?

Correct the TLS port for gmail SMTP configuration. It should be 587. You can refer to below link -
https://support.google.com/a/answer/176600?hl=en

Related

Powershell Remoting from windows to windows on different domain

I want to connect two windows server on different domains using powershell remoting.
I follows step that given in below blog
https://activedirectoryfaq.com/2018/09/import-powershell-sessions-from-computers-in-another-domain/
but it did not work for me. By following this blog, on connection it gives
**
Enter-PSSession : Connecting to remote server failed with the following error message : WinRM cannot
process the request. The following error occurred while using Kerberos authentication: Cannot find the computer
. Verify that the computer exists on the network and that the name provided is spelled correctly. For
more information, see the about_Remote_Troubleshooting Help topic
**
client server is windows server 2022 machine (powershell version 5.1.20348.1366)
remote server is windows server 2016 machine (powershell version 5.1.14393.1480)
Help me with it.

Sending test mail fails in confluence

I need to evaluate notification functionality in confluence.
I have installed confluence locally on my PC.
I have configured mail server in it by going to General Configuration->Mail Servers->Add a new SMTP mail server
I have provided smtp.office365.com as Server Host Name and 587 as Server port.
I have used my company user id as User name and corresponding password.
However when I try to send a test mail, it fails with below exception
"Caused by: javax.mail.MessagingException: Could not connect to SMTP host: smtp.office365.com, port: 587" and also we have tried to configure our smtp server and getting error as "Caused by: java.net.SocketException: Permission denied: connect"
I have seen accepted answers for this question at post https://answers.atlassian.com/questions/139025/error-while-configuring-mail-server
However that is related to a bug Java1.7 whereas I am using Java1.8.
Can someone please suggest any idea what thing can be wrong?
Looking at the hostname it seems that the mail server is in the internet. If you are behind a proxy you will need to configure this in the java options as described here
https://confluence.atlassian.com/doc/configuring-web-proxy-support-for-confluence-117068.html

SMTP Server Connection Refused

After it was working fine for couple of weeks I suddenly get this error:
No connection could be made because the target machine actively refused it 127.0.0.1:25 : at System.Net.Sockets.Socket.DoConnect(EndPoint endPointSnapshot, SocketAddress socketAddress)
Any ideas what could have changed?
Do you get SMTP greeting message? telnet localhost 25
NO => local SMTP server is not running OR it rejects new SMTP connections due to overload OR some static or overload protection rules of local firewall blocks your smtp connection

How to get smtp error code using phpmailer

I got mail error message for smtp using phpmailer. but I need error code that error message.
How I get it.
Thanks
It is probably a connection error with the mail server. You should try to make a telnet conecction or a ping from the apllication server where you are running PHP to the mail server like
telnet <mail_host> <port>
Also you should check Firewall settings on the server.

Exchange SQL Server 2008 Database Mail issue

In my web application I have created a mail sender class and set the configurations of web.config file like this:
<mailSettings>
<smtp deliveryMethod="PickupDirectoryFromIis">
<network host="smtp.domain.com"
port="587"
userName="mail#domain.com"
password="password"/>
</smtp>
</mailSettings>
This is sending email. But SQL Server database mail can not send mail with the same account info.
Only one difference is PickupDirectoryFromIis .
Is there any setting on exchange server?
In the SQL Server Logs the errors are following.
Message
The mail could not be sent to the recipients because of the mail
server failure. (Sending Mail using Account 2 (2012-09-30T16:55:04).
Exception Message: Cannot send mails to mail server. (The SMTP server
requires a secure connection or the client was not authenticated. The
server response was: 5.7.1 Client was not authenticated).
Looks like this is a Authentication issue or port no issue.
Authentication Issue:
—————————-
Please make sure you have put the information as explained below:
Server name: smtp.gmail.com ( this is really important)
port no: 587 ( on many website this is given as 465 which is wrong, use 587 )
Check : This server requires a secure connection
Check Basic Authentication
username: youremailid#gmail.com ( should have gmail.com)
password: XXXXXXXXXXXXX
confirm password: confirm your password
Port No Issue:
——————–
Make sure port 587 is opened in your machine if you are following above example. If you are using any other port number (usually its port 25) to set up database mail in your office, make sure you speak with your security team and ask them to unblock port 25. Once they unblock port 25, your databasemail will work.
Network Connectivity:
—————————–
Also check network connectivity from your machine, if you can connect to internet from your machine on which you are testing your database mail. To test, do the following
Start- Run- type cmd – Hit Enter
Type ping gmail.com -t and then hit enter.
If output displays as Request timed out, it actually means there is network connectivity problem. Otherwise, your network connectivity is good.