I'm using Symfony 2.1 and SwiftMailer to send out registration e-mails.
The process handling for this takes abouts 20 seconds if there's an email to be send. Meanwhile the website is loading. This might give users the impression that something went wrong.
I'm connecting using SMTP.
I have a similar Symfony2 Installation which connects to the same mail server, also using SMTP and there an email is send immediately.
Is there a way using XDEBUG or something else to see what is causing the delay?
I think this was a slow DNS lookup problem.
In parameters.yml I've changed the SMTP host from the domain name to 127.0.0.1 and it works perfectly now.
Related
When I go to https://mxtoolbox.com/diagnostic.aspx, enter my domain (pairofdocs.net), and click ‘Test email server’, I get the error message:
Connecting to 23.23.216.253
2/19/2021 9:23:30 AM Connection attempt #1 - Unable to connect after 15 seconds.
I have no idea why this is happening – any suggestions?
I have used the test previously and it worked. My domain is configured as follows:
DNS – on NameCheap.com
Web site (a simple one) – on Amazon Web Services
Email – handled by Zoho
I rebuilt my domain about six months ago, on a new AWS instance - whose IP address is 23.23.216.253, and do not recall the problem’s having happened prior to the rebuild.
Since your Email hosting is outsource to Zoho, there is a pretty good chance the email server has been setup correctly and has a pretty decent uptime.
It is likely the problem you are having is with how you are connecting to the email server although the error you've provided shows what seems to be an offline email server.
My play framework web application sends automatically emails to user using Apache commons email library, everything works fine on my machine, but when I deploy it on an Ubuntu server it is unable to send email.
It throws exceptions like org.apache.commons.mail.EmailException: Sending the email to the following server failed : smtp.googlemail.com:465 (I also tried different configuration with smtp.google.mail port 465,25 and 587 with or without ssl and tls)
and connection timed out.
I starting to believe that is a problem of some configuration of my ubuntu server.
Any suggestion?
If i type ufw status command I receive status disabled.
Thanks
I am going to close this question, because I found the solution. Basically my Server provider (Scaleway) has a security configuration where SMTP is blocked. I asked them to unlock It.
We have a VPS with CentOS combined with DirectAdmin which we use for a Magento shop. This runs fine, except for sending email.
Problem:
It appears that some specific domains won't receive our emails and we get a bounce. If we use any other email sending systems, the mails arrive without problems.
The bounce mail contains the following error:
SMTP error from remote mail server after HELO Company-Shops:
host mx-cluster-b2.one.com [IP ADRESS]: 504 5.5.2 :
Helo command rejected: need fully-qualified hostname
After googling and trying things for a week now, I am a bit lost. I tried checking postfix in CentOS, but this is not installed and I'm not quite sure if this is needed.
Possible issue?
I believe the hostfile in CentOS is setup incorrectly:
127.0.0.1 localhost localhost.localdomain localhost4 ... etc
OUR IP Company-Shops
'Company-Shops' should probably be a domain name, am I right? The same as the rDNS. But I'm afraid if I change this it will kill my site and whatnot. I'm not sure if this entry correlates with the 'company-Shops' helo label in the bounce error.
Some extra info:
- We use the webmail Roundcube from DirectAdmin
- At the moment we run one shop, but this might grow a bit (multiple sites on 1 IP)
- We don't use subdomains
- We've set up a reverse DNS, with the domain
Is there anyone with similiar experiences or with a bit more knowledge about this subject? I appreciate any advice we can get, as we are stuck..
Many thanks.
Yes, that's right: your mail server should identify itself using a fully-qualified domain name when it connects to send mail via SMTP. You don't say what mail server you're running, but since you're using DA, it's probably Exim. If so, you want to edit /etc/exim.conf and set primary_hostname to the FQDN of your server.
This would also be a good time to double-check that reverse DNS is set up properly for your IP address. Many hosts will also reject email from servers on IPs without a valid rDNS record.
I'm not familiar with Magento, but I can't see any way that changing the Exim configuration in this way could impact that program.
I am using a PHP script for sending emails by IIS 5.1 SMTP.
The emails, go to outbound folder. really path is C:\Inetpub\mailroot\Queue.
after a seconds, it start to send emails properly, but after sending 5 or 6 emails, it stops to send the other ones. SMTP service is still start and it seems there is no problem to SMTP service.
but,If i restart the service, it sends 1 or 2 other emails and then, it stops again.
I mean sending emails stop but service is start.
by the way, emails are stucked in Queue folder.
Also i checked Badmail folder. it is empty
Thanks
are all the emails to the same network? I have seen behaviour like this when the recipient server bans you, yahoo's (xtra) used to do it sometimes to our server in particular. You can check the logs in event viewer for something from the smtp server, you'll find a message from the other server saying something to the effect that you have been temporarily banned, possibly with more detail about why. Trying to connect via telnet also gives you the same message.
When this happens windows will try and send them again later. Restarting the server starts to try sending again and if the ban condition has been lifted messages will flow for a while again until you are rebanned.
I got this project "skpsmtpmessage" and I tried to send mail first. So I changed all the mail id to gmail id. But replay host is problem. I tried smtp.gmail.com, smtp.google.com, smtp.googletalk.com. But when I run my program, I get error that "Unable to connect server"
Which relay host should I use for gmail.
The correct SMTP server for Gmail is smtp.gmail.com, but I don't know how to help you further, the question is pretty vague.
You can also take a look at the configuration instructions for using Gmail on the iPhone to see if you're making a mistake with another parameter.