What is MySQL?
MySQL is an open-source relational database management system (RDBMS), property of Oracle Corporation. The project is open sourced under the GNU General Public License as well as under a variety of proprietary agreements, which offer extended functionality.
This box allows to manage a single MySQL instance, as well as a Master-Slave replication with either one or two masters. Master and slave nodes can be added to the system as long as the database is not populated (i.e. it's a new deployment).
||The name of the database to be created. This variable is required to deploy a single node or a master
||The port on which the MySQL daemon will run on.
||The unique identifier of the server. A random value will be calculated at runtime if no value is provided
||The name of the user that will perform the replication.
||The password of the replication user. A random password will be calculated if no value is provided
||MySQL's daemon configuration file (my.cnf)
||File containing the SQL commands to be run in a master node
||File containing the SQL commands to be run in a slave node
||Allows to select if a node will act as a Master or a Slave.
||Binary log file in which to start a replica. This value is calculated at runtime and any user provided value will be overriden
||Binary log position in which to start a replica. This value is calculated at runtime and any user provided value will be overriden
||Binding to a master node
There are three different configurations of this box, namely single instance, master-slaves replication and master-master replication. Each of them can be deployed as follows:
- Single instance: In order to deploy a single MySQL instance, the only necessary step is to chose a database name through the
- Master-Slave replication: Several slaves can be added for replication using a single master. In order to deploy an slave, select "Slave" in the
NODE_TYPE variable and add the necessary tags to match the master binding you want to connect to in
Master-Master replication: There are three necessary steps to make this deployment:
- Deploy a single instance following the steps in point 1.
- Deploy a second master pointing to the one previously deployed.
- Add a binding to the first instance in order to point to the second and reconfigure it.
Also, if you want to add slaves to this master-master configuration, follow the steps described in point 2.
This deployment supports these Linux distributions:
- Ubuntu 14.04
- Red Hat Enterprise Linux on Amazon EC2
Checkout MySQL's documentation.
Discuss at Mysql forums.