Uploading and installing schema files on MySQL Cluster
posted this on February 27, 2012 16:39
You can use ClusterControl to upload and stage your MySQL Cluster with data.
We recommend that you have the following:
Ensure that all you CREATE TABLE ... use ENGINE=ndbcluster; (or that no engine is specified at all, since default-storage-engine=ndbcluster is set by default by the Severalnines Cluster Configurator).
Use one file for schema, one for data, and one a dedicated file for GRANT/SPROCs/TRIGGERs and VIEWs. MySQL Cluster does not automatically distribute these files so if you don't have them in a separate file you risk that only one of the MySQL servers will have the necessary GRANT/SPROCs/TRIGGERs and VIEWs.
When you install the file containing only GRANT/SPROCs/TRIGGERs and VIEWs make sure you tick the box as in the picture below:
Now the GRANTs/SPROCs etc will be applied on all MySQL Servers connected to the Cluster.
When later adding more MySQL Servers these GRANTS/SPROCs etc will be automatically installed on the new server.