MariaDB ColumnStore is a columnar storage engine that utilizes a massively parallel distributed data architecture. It was built by porting InfiniDB to MariaDB and has been released under the GPL license.
MariaDB ColumnStore is designed for big data scaling to process petabytes of data, linear scalability and exceptional performance with real-time response to analytical queries. It leverages the I/O benefits of columnar storage, compression, just-in-time projection, and horizontal and vertical partitioning to deliver tremendous performance when analyzing large data sets.
Please install the following software packages before you begin.
Also make sure to grab your download credentials from our website:
This project will produce a 3 node MariaDB Columnstore cluster fronted by 2 MaxScale load balancers.
$ git clone https://github.com/mariadb-corporation/mariadb-enterprise-columnstore-docker.git
$ cd mariadb-enterprise-columnstore-docker
$ cp .env_example .env
$ docker-compose up -d && docker exec -it mcs1 provision
If you have configured your .env file properly, you should now see an output like this:
Waiting for PM1 to be initialized ................... done
Adding PM1 to CMAPI ... done
Adding PM2 to CMAPI ... done
Adding PM3 to CMAPI ... done
Adding PM1 to MaxScale 1 ... done
Adding PM2 to MaxScale 1 ... done
Adding PM3 to MaxScale 1 ... done
Adding PM1 to MaxScale 2 ... done
Adding PM2 to MaxScale 2 ... done
Adding PM3 to MaxScale 2 ... done
Adding SERVICE to MaxScale 1 ... done
Adding SERVICE to MaxScale 2 ... done
Adding LISTENER to MaxScale 1 ... done
Adding LISTENER to MaxScale 2 ... done
Adding MONITOR to MaxScale 1 ... done
Adding MONITOR to MaxScale 2 ... done
Sleeping 5 seconds ... done
Validating ColumnStore engine ... done
$ docker exec -it mcs1 bash
$ docker exec -it mcs2 bash
$ docker exec -it mcs3 bash
http://127.0.0.1:8989
admin
mariadb
http://127.0.0.1:8990
admin
mariadb
The following commands are a collection of aliases provided as shortcuts to common Columnstore management tools.
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 CMAPImcsReadOnly
Set Columnstore to read onlymcsReadWrite
Set Columnstore to read/writetcrit
Tail crit.logtdebug
Tail debug.logterror
Tail error.logtinfo
Tail info.logtwarning
Tail warning.loghttps://{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
https://127.0.0.1:8640/cmapi/0.4.0/cluster/remove-node
https://127.0.0.1:8640/cmapi/0.4.0/cluster/mode-set
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": "readonly"}' -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 .
$ git clone https://github.com/mariadb-corporation/mariadb-enterprise-columnstore-docker.git
$ cd mariadb-enterprise-columnstore-docker
$ docker run -d --shm-size=512m -p 3306:3306 --hostname mcs1 --env PM1=mcs1 --name mcs1 mariadb/enterprise-columnstore && docker exec -it mcs1 provision
You should now see an output like this:
Waiting for PM1 to be initialized ................... done
Adding PM1 to CMAPI ... done
Sleeping 5 seconds ... done
Validating ... done
Variable | Type | Default | Required |
---|---|---|---|
ADMIN_HOST | String | % | No |
ADMIN_PASS | String | C0lumnStore! | No |
ADMIN_USER | String | Admin | No |
CEJ_PASS | String | C0lumnStore! | No |
CEJ_USER | String | cej | No |
CMAPI_KEY | String | somekey123 | No |
PM1 | Hostname | mcs1 | Yes |
S3_ACCESS_KEY_ID | String | None | No |
S3_BUCKET | String | None | No |
S3_ENDPOINT | URL | None | No |
S3_REGION | String | None | No |
S3_SECRET_ACCESS_KEY | String | None | No |
USE_S3_STORAGE | Boolean | false | No |
docker run -d -p 3306:3306 \
--shm-size=512m \
--env USE_S3_STORAGE=true \
--env S3_BUCKET=my-bucket \
--env S3_ENDPOINT=s3.myendpoint.com \
--env S3_ACCESS_KEY_ID=myAccessKeyId \
--env S3_SECRET_ACCESS_KEY=mySuperSecr3tAcceS$key \
--name mcs1 mariadb/enterprise-columnstore \
&& docker exec -it mcs1 provision
$ docker build . --tag <your_image_name> --build-arg VERSION=10.6 --build-arg TOKEN=your_mariadb_enterprise_token
Variable | Type | Default | Required |
---|---|---|---|
TOKEN | String | None | Yes |
VERSION | String | None | Yes |
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。