Friday, June 2, 2017

Magento Amazon SES - Transactional Emails Not Working with SMTP Pro

Recently in one of our project, we were using Amazon SES service with SMTP pro extension in Magento 1.9. After verification of domain and sender email address, when we to test in SMTP pro, it was working fine. But when we try to send transactional emails such as new order, invoice etc. It was not working. So on debugging we found following exception.

Email address is not verified. The following identities failed the check in region US-EAST-1: hdave10@gmail.com

Now that was bit strange as that raised a question that do we have to verify all the receiver email as well and that was practically not possible as in Magento we can have any number of customers. 

So I checked docs of Amazon SES and after reading for a while I got the issue. 

The issue was we have configured three regions in Amazon SES. But we were still in sandbox mode for two regions and mail was sending from the region where we were still running in sandbox mode. 

To solve this issue log in to your Amazon SES console and select region from top left corner.


Once you select region, Go to SES Sending Limits Increase case.

and submit for limit increase. It will take a while to process your request. Once your limit is increased, you will come out of sandbox mode. You have to do this process for all the regions.

Hope this helps you.

Wednesday, May 31, 2017

Amazon EC2 Create Swap Space

Hello,

Recently in one of my project we have laravel application deployed on amazon ec2 instance. When running composer update command, we were facing issue of swap space as it was not defined. So in this blog I will explain how you can create swap space in your amazon ec2 instance. Please note these steps are specifically for ubuntu instance. If you are running other version of liunx, please check commands first and then use it.

1) Create swap file

sudo fallocate -l 1G /swapfile

2) Verify it

ls -lh /swapfile

It should show following output.

-rw-r--r-- 1 root root 1.0G Apr 25 11:14 /swapfile

3) Enable it and make it accessible by only root user.

sudo chmod 600 /swapfile

sudo mkswap /swapfile

sudo swapon /swapfile

That's it now you have swap space configured in your instance. 

Monday, May 29, 2017

Force Quit an App in Mac OSX from Terminal

Hello,

Recently I faced an issue with OpenOffice app on MAC. For some reason following open office window is displayed every time I open a document.


And then no matter what I do it does not go away. I tried force quit. Tried to close it from Activity monitor but it does not work. So then only option I had is to kill it with terminal. You can use this procedure to kill any unresponsive app in your OSX. 

First of all we have to find out process id of the unresponsive app. Since the app is unresponsive, it must be consuming lots of CPU resources. To find out this, open terminal and type following command.

top -o cpu

It will show following window. 


As you can see in first column we have PID and in second column we have app name. Find out PID from the name of unresponsive application and then type following command in terminal.

kill PID

 And it will kill unresponsive app. Hope this helps you.