Skip to content

Commit

Permalink
add documents about customizing TiDB parameters
Browse files Browse the repository at this point in the history
  • Loading branch information
tennix committed May 1, 2019
1 parent acbf223 commit 26fdc6e
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions deploy/aws/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,8 @@ To scale TiDB cluster, modify `tikv_count` or `tidb_count` to your desired count
## Customize

### Customize AWS related resources

By default, the terraform script will create a new VPC. You can use an existing VPC by setting `create_vpc` to `false` and specify your existing VPC id and subnet ids to `vpc_id` and `subnets` variables.

An ec2 instance is also created by default as bastion machine to connect to the created TiDB cluster, because the TiDB service is exposed as an [Internal Elastic Load Balancer](https://aws.amazon.com/blogs/aws/internal-elastic-load-balancers/). The ec2 instance has MySQL and Sysbench pre-installed, so you can SSH into the ec2 instance and connect to TiDB using the ELB endpoint. You can disable the bastion instance creation by setting `create_bastion` to `false` if you already have an ec2 instance in the VPC.
Expand All @@ -76,6 +78,10 @@ The TiDB version and component count are also configurable in variables.tf, you

Currently, the instance type of TiDB cluster component is not configurable because PD and TiKV relies on [NVMe SSD instance store](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ssd-instance-store.html), different instance types have different disks.

### Customize TiDB parameters

Currently, there are not much parameters exposed to be customizable. If you need to customize these, you should modify the `templates/tidb-cluster-values.yaml.tpl` files before deploying. Or if you modify it and run `terraform apply` again after the cluster is running, it will not take effect unless you manually delete the pod via `kubectl delete po -n tidb --all`. This will be resolved when issue [#255](https://github.com/pingcap/tidb-operator/issues/225) is fixed.

## TODO

- [ ] Use [cluster autoscaler](https://github.com/kubernetes/autoscaler)
Expand Down

0 comments on commit 26fdc6e

Please sign in to comment.