Recently some customers running on Amazon EC2 asked me how to configure a HA environment for their ScaleBase instance.
For instance, let’s look at the following architecture:
To ensure that Scalebase is not a single point of failure, several ScaleBase instances can be used – so if one crashes, other instances can handle its connections.
This is quite simple to do:
- Start the EC2 instance to be used for the ScaleBase configuration
- Install MySQL on the machine and follow the database preparation instructions defined in the ScaleBase installation guide.
- Install ScaleBase with the –mode=ALL parameter.
- Create an EC2 instance that will be used as an AMI for all ScaleBase installations.
- Download and install ScaleBase on the machine using the InstallMachine script. Make sure you use the –mode=LB parameter, to connect to an existing configuration.
- Create an AMI out of the instance (in the EC2 management console, right click on the instance and select the “Create Image” option).
- Start instances based on the created AMI.
- Create an EC2 Load Balancer (see EC2 documentationfor more information).
- Make sure all the instances you created are mapped to the Load Balancer.
- Make sure the Load Balancer is connected to TCP port 9000, and is using this port for Health Check.
- Direct all communication to the Load Balancer DNS.
That’s it. Easy – and works like a charm.
PlanetMySQL Voting: Vote UP / Vote DOWN