Setting up web-server, mail server & DB in AWS


Recently an emerging SMB from cookware manufacturing sector approached me to consult about some of the IT challenges they were facing. They have a simple website designed in WordPress and hosted in BigRock & a new website is under development. A limited number of corporate email accounts are also created in the same domain. They also have an ERP software designed in-house & a MySQL database created along with the web hosting was used for it.
The website, as it was not targeted for a huge traffic currently, was running smooth. But not the ERP application. They do have offices in India and Middle-east and the ERP application connects to the MySQL database running in the BigRock server from both the locations. The first problem they faced was the poor performance of the ERP due to the latency in executing SQL queries. The second problem was frequent disconnections due to a low connection time-out setting at the MySQL server.
The database access that comes with the web hosting does not give admin access to the MySQL server, so there was no way to increase the MySQL timeout. One solution was to opt for a dedicated MySQL server in BigRock with extra charges, in which you will get the admin access and full control of the MySQL server. However the truly visionary & tech-savvy leader of the company expressed their aggressive expansion plans which made me to rule out that option. What he wanted was something really Elastic and solve their problems forever.
Their current IT set-up can be summarized into following four:
  • A domain name for the website.
  • A web server for hosting the dynamic website.
  • A mail server for the corporate email IDs
  • A MySQL server for the ERP software.
It was easy for me to convince him to go with the Public Cloud after a brief explanation of the advantages it bring in his case & then we selected AWS(Amazon Web Serivce). The domain name was registered for couple of years with BigRock, so I decided to keep it there itself & saved some dollars for him.
For web hosting the cheapest solution was to use Amazon S3 (Simple Storage Service) with Cloudfront. But since the customer has a dynamic website designed in WordPress & a new website with e-commerce support is under development, a web server like Apache was inevitable.
For email server I had to choose between iRedMail and Zimbra – two of the popular open-source email servers and selected Zimbra.
Amazon RDS (Relational Database Service) would have been the preferred that choice for the MySQL database. But since my client needed admin access to their MySQL server, the option of selecting a managed RDBMS like Amazon RDS was also ruled out.
After evaluating all these I concluded that a properly configured Amazon EC2(Elastic Compute Cloud) instance will serve the purpose for him. I have created aVPC (Virtual Private Cloud) first with a public subnet. Necessary ACL and security groups are configured to provide only restricted access. Then usedBitnami LAMP Stack AMI to launch an EC2 instance. This gave me Apache web server, PHP for the dynamic contents and MySQL server required for the ERP software. I have installed Zimbra email server on the same EC2 instance for setting up the corporate email accounts. Finally updated the DNS & configuredRoute 53 to map the domain name registered with BigRock to point to the web server. An ELB (Elastic Load Balancer) was not required here till the new website is ready.
Now my client is getting billed monthly at a very moderate rate for the EC2 instance & data transfer charges and is very happy with the quick and cost effective solution to all his problems. If we look at the cost saving part of the story, the new solution has reduced almost 50% of their IT (infrastructure) expenditure (though in this case it was a couple of hundreds of dollars only) & avoided any initial investment at all.
Key take away from this case study is that Public Cloud gives two important advantages to emerging businesses – zero upfront cost & ability to expand skyhigh.

So how did I solve his IT problems? Migrated to the Cloud.

PS: This was originally published in LinkedIn: https://www.linkedin.com/pulse/how-did-i-save-his-problems-anil-g-kurian

Current Deployment
 Future Deployment which scales

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s