Swiftmailer successfully sends but no mail received - swiftmailer

I have made a simple contact form and use swiftmailer(with symfony2) to send and email.
Everything is fine when I'm using gmail account but on production it has to be a noreply address in website domain.
So I changed parameters to correspond this email account.
It looks like it is working a send method return true but no message is received, i checked a spam folder but it didn't get there either. Settings are 100% correct as they work in thunderbird.
Have no idea where to look for a problem. Any suggestions what should I check?
I have tried to send email with PHPMailer using same account and it worked so it seems problem is just with swiftmailer.
I'm sending emails in few more places in my project and would like to avoid changing it now but fix it instead.

After checking logs the problem was found.
Emails were rejected because I was setting From filed to email provided by user. Server was rejecting them because this address don't belong to account I was sending from.

By default the logging for swiftmailer is disabled in production. You can enable logging for swiftmailer in config.yml by adding a "logging: true" to the swiftmailer section as outlined here: http://symfony.com/doc/master/reference/configuration/swiftmailer.html#logging
Hopefully this will give you some more specific error messages to search on.

Related

Magento 2 Order Confirmation Emails Not Sending

Currently having an issue with order confirmation emails not sending.
I have looked at various forums / solutions and these haven't worked.
My existing setup is using the MagePlaza SMTP to send email using Mandrill, this is working through their test function and also the Forgotten Password and Create account emails are being sent but not the Order Confirmation emails.
I am using IWD One Step checkout but have also disabled this to try with Magento default checkout and it doesn't work using either.
Asyncronous sending is set to disabled but I have also tried with it enabled. Both times no order emails are sent.
As I'm using Mandrill I have checked their API logs and the API request isn't being sent.
Any help/suggestions appreciated.
It's possible that the "From" address is wrong.
Goto Stores -> Configuration -> General -> Store Email Addresses and check if "Sales Representative" Email address is correct.
There is known bug in Magento 2.2.4/2.2.5/2.2.6 and you might be afected by it:
https://github.com/magento/magento2/issues/14952.
TLDR: There is no from data set on email transaction and messeges aren't sending at all.
Try thisfix:
https://github.com/magento/magento2/issues/14952

Not delivering to previously bounced address - Mailgun

I'm setting up my Laravel website, and now comes the part where I configure Mailgun to send and receive emails.
I followed different guides to do that, yet I don't feel I'm doing it right. I'm now stuck with this error:
Failed: postmaster#syrianafood.dk → ibrahim_hasan_eng#hotmail.com 'New Order from Ibrahim Hasan' Not delivering to previously bounced address
i.e. Mailgun is not able to deliver my emails. Could you please guide me through this? Thank you!
If mail was sent and rejected by the provider (bad content, headers, etc), Mailgun will automatically blacklist that address from being sent to in the future.
This is to prevent blacklisting yourself from many of the different MX providers out there.
If you think you've solved that problem, you can perform a DELETE request through the Mailgun API in the format of DELETE /<domain>/bounces/<address> before sending the mail, and then you'll be able to send to that address again.
You can check if a bounce has happened previously by performing a POST request to POST /<domain>/bounces. Furthermore, you will receive a JSON object back with a REASON as to why the bounce occurred, giving you the ability to respond in kind to this.
If a domain is not working correctly and it's not in the blacklist, then it's possible that the MX Provider its self is not accepting the emails and is responding unfavorably in a way that Mailgun cannot handle.
You can also delete the mail directly from the Mailgun UI if you have the login credentials. Please see the comment below and give it an upvote.

After merging a Mandrill account into Mailchimp, how can I accept a verification email if my sending domain is not setup to receive emails?

We've been using Mandrill for years to deploy our app's signup confirmation and password reset emails. This has worked perfectly as we've had SPF and DKIM records added to the DNS configuration according to Mandrill's documentation for verifying sending domains.
However, after merging the Mandrill account with a new Mailchimp account--which is mandated by April 27th--it's requiring me to send a verification email to an address at that domain. The problem is that we don't have a mail server set up to receive emails. The domain is only used to send the "noreply#domain.com" emails.
Any ideas on how I might resolve this? Mailchimp is not giving an option to undo the merge, so effectively I have an app that users are not able to sign up for at the moment, which is problematic to say the least.
You'll want to configure at least one mailbox on that domain somehow to receive mail. That's the only way to confirm ownership of the domain.

Joomla : Could not instantiate mail function

I have developed a website in joomla, and I have a contact us page, in that the form works fine only when I use to send an email from the same domain
Eg :
From : rimaz#abcd.com
To : john#abcd.com
But when I send to a different domain the form gives an error as "Could not instantiate mail function."
Eg :
From : rimaz#abcd.com
To : john#gmail.com
Can anyone explain me about this problem ??
Instead of debugging your providers SMTP / email setup you can use the new mandrill service from the guys who do mailchimp - Mandrill ( http://blog.mailchimp.com/public-beta-of-mandrill-smtp-email-service/ ) with the plugin :
http://extensions.joomla.org/extensions/content-sharing/mailing-a-distribution-lists/20624
Mandrill is a plugin that allows your Joomla installation to send transactional emails. The only thing you need to do is to provide your Mandrill API key and enable the plugin. After that all emails (new user registration, password reset etc) will be send through the Mandrill service.
Mandrill Features:
Uses MailChimp's awesome email delivery engine instead of your server
Tracks opens and clicks so you know how effective these emails are to your users . Now you can > see what you need to change to make them
more effective.
Has pretty, visual reports of the email results
Allows you to tag the emails and see your stats filtered by tag
Why would understanding transactional emails be important for you. An example is when a user signs > up on your site an email is sent via Joomla. But, you get no reports to understand how effective that email did. These emails are sent as instructions to your users telling them a message you want them to understand. Where they designed good? Was the content well written? Was it structured properly? This is hard to say when it goes thru Joomla but now you will understand all this when the emails goes thru Mandrill.
This is a setting from your host. YOu can ask them for help in figuring out how to make it work, but they are trying to prevent you from using their hosting to spam people.
Sometimes it is possible to work around it but not always.
This usually happens due to restrictive mail server settings, which you most likely don't have influence on with shared hosting.
If you have more control over the server, you should fix the mail server settings.
If not, the easiest way is to use Joomla's ability to send mails using any SMTP mail account. Create a mail account for Joomla, and enter the credentials in Joomla's configuration. Joomla will then use that account to send mails. So will extensions, if they are properly written.

TFS 2010 Wont Send Email

I can't get TFS 2010 to send email alerts. I've tried setting up everything mentioned here:
http://social.technet.microsoft.com/wiki/contents/articles/how-to-configure-tfs-notifications-in-team-foundation-server-2010.aspx
It's configured to send to a local IIS SMTP instance. SharePoint 2010 is on the same box and is also configured to use the same local SMTP server and it works fine sending emails, no problem. It's also using the same "from" email address as TFS is configured to without issue.
TFS isn't even trying to send anything as far as I can tell - I don't see anything from it in the SMTP log (C:\Windows\System32\LogFiles\SMTPSVC1...).
I have the default "My Work Items changed" alert set up and enabled. I try logging in as another user, assigning a work item to me, then assigning it back...nothing happens...no email. I don't see any error in the event viewer from TFS.
What can I do to troubleshoot this?
I had added alerts in Alert Explorer without specifying any Team Project. Once I added the Team Project filter it started working.
Try other method,
I configure the Email using Gmail Account and it is working very well, try it! if you would like? see this link for steps how you can do it?
http://mohamedradwan.wordpress.com/2011/06/26/configure-tfs-2010-alert-using-local-smtp-that-use-gmail-account/
Thanks
M.Radwan
Try this out
http://ravendra.wordpress.com/configuring-email-alert-settings-in-tfs-2010/
Or else you can go with the option of relay mail. Create a local SMTP server and relay it with the main mail server.
Note : If you mail server requires advanced authentication then you need to follow the second option only.
I actually wanted to add this answer to give ppl an idea of what to look for when they come across 'why doesn't the email get sent out'. The reason i came across this thread was for the same reason, it seemed that tfs wasn't sending out the email. But it was! the problem turned out to be the 'group' that I was sending the email to wasn't permitted to receive email. here is the situation, TFS server located at a DATA CENTER. The email ALERTS that i configured were to a group in our local office DOMAIN.
Apparently,in Active Directory that group didn't have the "All users need to be authenticated" checked OFF. Meaning, the TFS server 'sender of the email' wasn't authenticated to send emails to that group. once i sat with my MIS guys, they finally noticed that was checked on, and once DISABLED. Problem fixed! Hope that helps someone.

Resources