This is a Terraform and Ansible project to provision a high availability MariaDB ColumnStore deployment on Amazon Web Services. This automation project will create the following system:
- 3 MariaDB Nodes For Durability & Performance
- 1 S3 Bucket For Object Storage (Data)
- 2 MaxScale Nodes For High Availability
† Requires Terraform v0.14.4 or above.
‡ Requires Full Ansible 2.10.5 or above. (Not Ansible-Core)
Open a terminal window and clone the repository:
git clone https://github.com/mariadb-corporation/columnstore-ansible.git
cd
into the newly cloned folder- Edit variables.tf and supply your own variables.
terraform init
terraform plan
(Optional)terraform apply --auto-approve
ansible-playbook provision.yml
Further information can be found on our official deployment guide.
AMI OS | AMI ID | Region | Zone |
---|---|---|---|
centos7 | ami-0a4497cbe959da512 | us-west-2 | us-west-2a |
core
Change directory to /var/log/mariadb/columnstore/corefilesdbrm
Change directory to /var/lib/columnstore/data1/systemFiles/dbrmextentSave
Backup extent mapmcsModule
View current module namemcsStart
Start cluster via CMAPImcsStatus
Get cluster status via CMAPImcsShutdown
Shutdown cluster via CMAPItcrit
Tail crit.logtdebug
Tail debug.logterror
Tail error.logtinfo
Tail info.logtwarning
Tail warning.log
https://{server}:{port}/cmapi/{version}/{route}/{command}
https://127.0.0.1:8640/cmapi/0.4.0/cluster/status
https://127.0.0.1:8640/cmapi/0.4.0/cluster/start
https://127.0.0.1:8640/cmapi/0.4.0/cluster/shutdown
https://127.0.0.1:8640/cmapi/0.4.0/cluster/node
- 'x-api-key': 'somekey123'
- 'Content-Type': 'application/json'
Note: x-api-key can be set to any value of your choice during the first call to the server. Subsequent connections will require this same key
curl -s https://127.0.0.1:8640/cmapi/0.4.0/cluster/status --header 'Content-Type:application/json' --header 'x-api-key:somekey123' -k | jq .
curl -s -X PUT https://127.0.0.1:8640/cmapi/0.4.0/cluster/start --header 'Content-Type:application/json' --header 'x-api-key:somekey123' --data '{"timeout":20}' -k | jq .
curl -s -X PUT https://127.0.0.1:8640/cmapi/0.4.0/cluster/shutdown --header 'Content-Type:application/json' --header 'x-api-key:somekey123' --data '{"timeout":20}' -k | jq .
curl -s -X PUT https://127.0.0.1:8640/cmapi/0.4.0/cluster/node --header 'Content-Type:application/json' --header 'x-api-key:somekey123' --data '{"timeout":20, "node": "<replace_with_desired_hostname>"}' -k | jq .
curl -s -X DELETE https://127.0.0.1:8640/cmapi/0.4.0/cluster/node --header 'Content-Type:application/json' --header 'x-api-key:somekey123' --data '{"timeout":20, "node": "<replace_with_desired_hostname>"}' -k | jq .
curl -s -X PUT https://127.0.0.1:8640/cmapi/0.4.0/cluster/mode-set --header 'Content-Type:application/json' --header 'x-api-key:somekey123' --data '{"timeout":20, "mode": "readwrite"}' -k | jq .
- url:
http://<MaxScale_Public_IPv4_DNS>:8989
- username:
admin
- password:
mariadb
terraform destroy --auto-approve