MySQL on the Cloud: Running on AWS EC2 v/s AWS RDS For a long time, there was only one way to run MySQL on the cloud. Setup an instance, install MySQL and maintain it yourself – this meant patching it, managing backups, handling replication failures, etc. Then AWS RDS came along and can be thought of as a PaaS for MySQL – it hides all the complexities behind the scenes and you only concern yourself with the database and not the database software. Running on RDS means:
AWS will take care of provisioning the infrastructure capacity you request and installing the database software. AWS will perform automated backups as configured with point-in-time recovery options. You may also manually initiate a DB snapshot to backup your DB in a known state. AWS offers backup retention for up to the last 35 days. AWS will apply patches that are security and durability related. AWS will manage synchronous data replication across physically distinct locations (Multi-AZ deployments). With Multi-AZ deployments, AWS will perform automatic failovers in case of certain failures or planned maintenance such that your application can resume database operations without the need for manual administrative intervention. AWS will create „Read Replicas‟ (similar to MySQL Slaves) as requested for read intensive workloads. Monitoring the compute and storage resource utilization of your DB Instance, for no additional charge, via Amazon CloudWatch.
Most of these things can be managed with a few clicks from the AWS Management Console. Depending on the size of storage requested, Amazon RDS automatically stripes across multiple EBS volumes to enhance IOPS (input/output operations per second) performance. Similar performance may be realized on EC2 only by going with a RAID0 EBS but doing RAID0 EBS requires a significant amount of maintenance overhead. In addition, for I/O intensive transactional workloads that need consistent performance, RDS Provisioned IOPS lets one specify an IOPS rate when creating a DB Instance. Amazon RDS will then provision that IOPS rate for the lifetime of the DB instance. You can provision a MySQL instance with up to 30,000 IOPS! See here for more information on IOPS: http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Overview.ProvisionedIOPS.html Just as in the case of EC2, you can increase or decrease the CPU and memory available to a DB instance by changing its instance class. Amazon RDS will perform the upgrade during the next maintenance window and also provides options if you want the upgrade to be performed immediately. The Amazon RDS maintenance window provides an opportunity to control when DB Instance modifications (such as changing DB Instance class) and software patching occur.
Neev Information Technologies Pvt. Ltd.
www.neevtech.com
sales@neevtech.com
Easy replication and automatic failover with RDS Running your DB Instance as a Multi-AZ deployment can further reduce the impact of a maintenance event or a DB instance failure. In a Multi-AZ deployment, Amazon RDS automatically provisions and maintains a synchronous “standby” replica in a different Availability Zone. During certain types of planned maintenance, or in the event of DB Instance failure or Availability Zone failure, Amazon RDS will automatically failover to the standby and your application can resume database operations without the need for manual administrative intervention. Note that you cannot directly interact with the standby and cannot use it to serve read traffic. If you need to scale-out for read intensive workloads, you can create any number of „Read Replicas‟. Database updates on the source DB Instance will be replicated using MySQL‟s native, asynchronous replication. You may also want to run reporting queries against a Read Replica, rather than on your primary, production DB Instance. RDS provides excellent options to tune Read Replicas for such specific operations. See here for more info: http://aws.amazon.com/rds/faqs/#95 Automated backups with RDS Amazon RDS offers automated backups with point-in-time recovery and once configured, automatically performs a full daily snapshot of your data (during your preferred backup window) and captures transaction logs (as updates to your DB Instance are made). Amazon RDS retains backups of a DB Instance for upto the last 35 days (configurable). DB Snapshots can also be user-initiated and enables you to back up your DB Instance in a known state as frequently as you wish, and then restore to that specific state at any time. Database tuning with RDS In order to tune an RDS instance, you use a database parameter group which acts as a “container” for engine configuration values that can be applied to one or more DB Instances. This allows you to create a certain tuned parameter set that can be easily reused across DB instances. By default however, Amazon RDS chooses the optimal configuration parameters for your DB Instance taking into account the DB Instance‟s compute resource and storage capacity. For important technical information about running MySQL on Amazon RDS, see: http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/MySQL.Concepts.html For more information on how the charges work, see http://aws.amazon.com/rds/faqs/#15 Neev is an AWS Consulting Partner and has been working with the cloud since the last 5+ years. Neev offers cloud-based software services and infrastructure management services. For more information, check the cloud offerings page or contact us. Visit us at Neevtech.com to know more about our offerings.
Neev Information Technologies Pvt. Ltd.
www.neevtech.com
sales@neevtech.com