Skip to content

Commit aa515f5

Browse files
sre-bottoutdesuite
andauthored
tiflash: add more explanation for multi disk deployment (#2467) (#2473)
Co-authored-by: toutdesuite <guizhiluo2014@163.com>
1 parent 408866d commit aa515f5

File tree

3 files changed

+12
-4
lines changed

3 files changed

+12
-4
lines changed

how-to/deploy/orchestrated/tiup.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -921,7 +921,7 @@ Key parameters of TiDB:
921921
| TiKV | 16 Vcore 32 GB * 3 | 10.0.1.1 <br> 10.0.1.2 <br> 10.0.1.3 | Default port configuration |
922922
|TiDB | 16 Vcore 32 GB * 3 | 10.0.1.7 <br> 10.0.1.8 <br> 10.0.1.9 | Default port configuration;<br>`enable_binlog` enabled; <br> `ignore-error` enabled |
923923
| PD | 4 Vcore 8 GB * 3| 10.0.1.4 <br> 10.0.1.5 <br> 10.0.1.6 | Default port configuration |
924-
| TiFlash | 1 | 32 VCore 64 GB | 10.0.1.10 | Default port configuration; <br> Customized deployment directory - the `data_dir` parameter is set to `/data1/tiflash/data,/data2/tiflash/data` for multi-disk deployment |
924+
| TiFlash | 32 VCore 64 GB | 10.0.1.10 | Default port configuration; <br> Customized deployment directory - the `data_dir` parameter is set to `/data1/tiflash/data,/data2/tiflash/data` for [multi-disk deployment](/reference/tiflash/configuration.md#multi-disk-deployment) |
925925
| Pump|8 Vcore 16GB * 3|10.0.1.6<br>10.0.1.7<br>10.0.1.8 | Default port configuration; <br> The GC time is set to 7 days |
926926
| Drainer | 8 Vcore 16GB | 10.0.1.9 | Default port configuration; <br>Set default initialization commitTS |
927927

reference/tiflash/configuration.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ This section introduces the configuration parameters of TiFlash.
2828

2929
```
3030
tmp_path = The path in which the TiFlash temporary files are stored.
31-
path = The TiFlash data storage path. # If there are multiple directories, separate each directory with a comma. For example, `/ssd_a/data/tiflash,/hdd_b/data/tiflash,/hdd_c/data/tiflash`. If your environment has multiple disks, it is recommended that each path corresponds to one disk and you put disks with best performance at the front to fully use performance of all disks.
31+
path = The TiFlash data storage path. # If there are multiple directories, separate each directory with a comma.
3232
path_realtime_mode = false # The default value is `false`. If you set it to `true` and multiple directories are deployed in the path, the latest data is stored in the first directory and older data is stored in the rest directories.
3333
listen_host = The TiFlash service listening host. # Generally, it is configured as `0.0.0.0`.
3434
tcp_port = The TiFlash TCP service port.
@@ -78,3 +78,11 @@ Multiple TiFlash nodes elect a master to add or delete placement rules to PD, an
7878
engine-addr = The listening address of the TiFlash coprocessor service.
7979
status-addr = The port and IP through which Prometheus pulls proxy metrics information.
8080
```
81+
82+
### Multi-disk deployment
83+
84+
TiFlash supports multi-disk deployment, controlled by the `path` and `path_realtime_mode` parameters in the [`tiflash.toml` file](#configure-the-tiflashtoml-file).
85+
86+
If there are multiple data storage directories in `path`, separate each with a comma. For example, `/ssd_a/data/tiflash,/hdd_b/data/tiflash,/hdd_c/data/tiflash`. If there are multiple disks in your environment, it is recommended that each directory corresponds to one disk and you put disks with the best performance at the front to maximize the performance of all disks.
87+
88+
The default value of the `path_realtime_mode` parameter is `false`, which means that data are evenly distributed on all storage directories. If the parameter is set to `true`, and `path` contains multiple directories, it means that the first directory only stores the latest data, and the older data are evenly distributed on other directories.

reference/tiflash/deploy.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ It is recommended to use an SSD disk to buffer the real-time data being replicat
2727

2828
For other hard disks, you can use multiple HDDs or regular SSDs. A better hard disk will surely bring better performance.
2929

30-
TiFlash supports multi-directory storage, so there is no need to use RAID.
30+
TiFlash supports [multi-disk deployment](/reference/tiflash/configuration.md#multi-disk-deployment), so there is no need to use RAID.
3131

3232
### TiFlash and TiKV are deployed on the same node
3333

@@ -97,7 +97,7 @@ TiUP cluster is the deployment tool for TiDB 4.0 or later versions. It is recomm
9797
- host: 172.19.0.103
9898
```
9999

100-
If you want to customize the deployment directory, configure the `data_dir` parameter. If you want to deploy TiFlash on multiple disks, separate each directory with commas. For example:
100+
If you want to customize the deployment directory, configure the `data_dir` parameter. If you want to [deploy TiFlash on multiple disks](/reference/tiflash/configuration.md#multi-disk-deployment), separate each directory with commas. For example:
101101

102102
{{< copyable "" >}}
103103

0 commit comments

Comments
 (0)