I have troubleshooting with sending emails at 1and1 hosting.
I use swift mailer lib message I receive is stream_socket_client(): unable to connect to mrvnet.kundenserver.de:0 http://mrvnet.kundenserver.de:0 (Connection timed out).
Does anyone have similar troubles? Any solution?
PS. At my localhost everything is OK.
I fix SMTP after contact with their support team.
SMTP parameters:
HOST: mrvnet.kundenserver.de
PORT: 25
AUTH: without auth
Contacted support, they asked me do not use encryption (neither ssl nor tls, both not acceptable), so my options are:
host: smtp.1and1.com
port: 25
login: somemail#somedomain.com
passwd: somestrongpassword=)
as you may mention i use 1and1's mail (same settings for gmail would not work)
Related
I try to get the Gmail inbox emails using Eden mail PHP from my localhost (XAMPP Apache server). But it throws a fatal error:
Fatal error: Uncaught Eden\Mail\Exception: Problem connecting to
ssl://imap.gmail.com:993. Check server, port or ssl settings for your
email server.
in C:\xampp\htdocs\edenMail\vendor\eden\mail\src\Imap.php:357
Stack trace:
0 C:\xampp\htdocs\edenMail\vendor\eden\mail\src\Imap.php(170): Eden\Core\Exception::i()
1 C:\xampp\htdocs\edenMail\vendor\eden\mail\src\Imap.php(357): Eden\Mail\Imap->connect()
2 C:\xampp\htdocs\edenMail\index.php(36): Eden\Mail\Imap->getMailboxes()
3 {main}
thrown in C:\xampp\htdocs\edenMail\vendor\eden\mail\src\Imap.php on line 357
I have used below code in Eden mail's index.php file with my own credentials.
$imap = eden('mail')->imap(
'imap.gmail.com',
'myEmailId',
'myPassword',
993,
true);
In addition to that, I have enabled IMAP/POP3 and turned on less secure apps as well in my Gmail settings.
I have encountered this error only when I try to connect from my localhost (Windows-Xampp-Apache server). But there is no error if test code in my web server working in Linux environment.
Could anyone please help me to connect the google imap.gmail.com to retrieve inbox emails?
I have followed the instructions given in the below link and got the issue resolved. I am sharing it as if may help anyone with the same issue.
https://www.hesk.com/knowledgebase/?article=72
Having problems getting Gmail to work with HESK? Try these settings.
» Email sending
To send emails using Gmail server enter these details:
SMTP Host: smtp.gmail.com
SMTP Port: 587
SSL Protocol: OFF
TLS Protocol: ON
SMTP Username: (your Gmail username)
SMTP Password: (your Gmail password)
Also make sure your "From email address" in HESK settings is set to your Gmail email address!
Still no luck? Check with your host if they have port 587 blocked in firewall.
» POP3 fetching
To fetch mail from Gmail server enter these details:
POP3 Host: pop.gmail.com
POP3 Port: 995
TLS Protocol: ON
POP3 Username: (your Gmail username)
POP3 Password: (your Gmail password)
Important: make 100% sure that "POP3 download" in your Gmail settings
is set to "Enable POP for mail that arrives from now on". If not,
Gmail will send all existing (even read) messages to HESK when it
first connects.
» IMAP fetching
To fetch mail using IMAP from Gmail server enter these details:
POP3 Host: imap.gmail.com
POP3 Port: 993
Encryption: SSL
POP3 Username: (your Gmail username)
POP3 Password: (your Gmail password)
» Error messages
Connection timed out
Required ports are probably blocked on your server's firewall. Ask your host to configure the firewall to allow TCP connections on ports 587, 995 and/or 993.
Some hosting companies will not do that due to their policies. In that case you will need to, in order to integrate Gmail with HESK, find another host or try the HESK cloud.
Permission denied
Try logging with your google account here to unlock it for application access.
Click the "Continue" button to Allow access to your Google account.
Password error: [AUTH] Username and password not accepted. Too many
login failures
Your username and/or password is not correct, double-check them ad remember passwords are CaSe SeNSiTiVe!
Password error: [AUTH] Web login required
See this article
Error: 0 could not connect to the host "pop.gmail.com"
This could mean that:
required ports are blocked on your server's firewall. Ask your host to unblock TCP connections on ports 587, 995 and/or 993
- OR -
SSL certificate verification fails on your server. Try this:
download this file
save it somewhere to your server, for example to C:\wamp\ssl\cacert.pem
open your php.ini file
find the line
;openssl.cafile=
and change it to the location of the cacert.pem file while also removing the starting ;
openssl.cafile=C:\wamp\ssl\cacert.pem
save and restart the server
test again
Trying to send email with Swiftmailer, I got this error. I've configured swiftmailer with:
transport: smtp
host: smtp.gmail.com
username: example#example.com
password: password
port: 587
encryption: ssl
I always get this error message:
Connection could not be established with host smtp.gmail.com
I've also tried with:
transport: gmail
host: smtp.gmail.com
username: example#example.com
password: password
port: 587
encryption: ssl
The complete error message is
[YYYY-mm-dd hh:ii:ss] app.ERROR: Exception occurred while flushing email queue: Connection could not be established with host smtp.gmail.com [ #0]
Other questions:
My case is different from this. In my case I've not Avast antivirus.
EDIT: changing port to 465, as Alex Howansky suggested, erro changes in
Exception occurred while flushing email queue: Failed to authenticate on SMTP server with username "my email address" using 1 possible authenticators
1: Either you must allow less secure apps or use app password by enabling 2 step verification on your gmail acc.
2: Disable any antivirus on your machine(this is something no one will tell u but is necessary in many cases).
3: Don't forget to clear your cache (sometimes it don't take updated content from .env file)
4: You don't need to change anything in Mailer inside config directory(not recommended), you should use env variables
it's looking for the server smtp.gmail.com but isn't able to resolve it. use this domain smtp.gmail.com and port 25 or 465.
I have problems sending emails from my production server with Symfony 2 , SwiftMailer and Gmail. When I send it from my localhost server no problem but when I test in the production server (Godaddy hosting) I get this error:
Connection could not be established with host smtp.gmail.com [Connection refused #111]
500 Internal Server Error - Swift_TransportException
I googled and tried many solutions without success. In localhost server it works with any simple configuration. This is my config.yml
Swiftmailer Configuration
swiftmailer:
transport: gmail
encryption: ssl
auth_mode: login
host: smtp.gmail.com
port: 587
username: myuser
password: mypassword
I put all the options for test but with email transport, username and password it works in localhost. I appreciated it any help in advance.
GoDaddy blocks all outgoing SMTP connections on their hosting. You will have to use their SMTP relay servers instead, or get a better host.
http://help.godaddy.com/article/955
http://www.satollo.net/godaddy-using-smtp-external-server-on-shared-hosting
my wordpress site email goes to Spam with php function,some site offer me using wp-mail-smtp plugin will repair my problem, but it doesn't help me!
when I use php mail() function my emails goes to spam
and when i use SMTP, i have an error like this: SMTP -> ERROR: Failed to connect to server: Connection timed out (110)
i use this settings for smtp (in wp-mail-smtp plugin):
From Email: noreply#mydoamin.com
SMTP host: smtp.gmail.com
SMTP port: 465
Encryption: Use SSL encryption
Authentication: Yes: Use SMTP authentication
Username: myEmail#gmail.com
Password: mypassword
this settings give me an error!
note: i use captcha code and my server tell me port 465 is Open!
how can I send email in my wordpress site ?
A connection timed out means that the connection isn't going through. This could be your host, since I just checked your settings - they look OK!
I would look into contacting your host with this. For all I know, that's all you can do, unless you are going to use a 3rd party mail API.
A connection timeout means your host is dropping your outbound request to Gmail. You'll need to send your Gmail out on the HTTPS port using a WordPress plugin called Postman SMTP.
I'm configuring RoundCube on my server and I'd like to use secured protocols for send/receiving mails.
When installing RoundCube, it asks me for ports for smtp and imap, I chose 465 and 993 but when I run the tests it freezes and I get a Gateway Time-out 504 error.
If I use port 25 and 143, it works!
Is there something to do with nginx/php-cgi to use those protocols?
Thank you.
I found what was wrong. If TLS or SSL is used you have to prefix the hostname with tls:// or ssl://, that was in the doc.