Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tikv: add command line flag --config-info #10615

Merged
merged 4 commits into from
Jul 27, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions command-line-flags-for-tikv-configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,31 @@ TiKV 的命令行参数支持一些可读性好的单位转换。
+ 默认:0(无限)
+ PD 需要使用这个值来对整个集群做 balance 操作。(提示:你可以使用 10GB 来替代 10737418240,从而简化参数的传递)。

## `--config-info <FORMAT>`

+ 按照指定的 `FORMAT` 输出各个配置项的取值信息并退出。
+ `FORMAT` 可选值:`json`。
+ 目前仅支持以 JSON 格式输出每个配置项的名字 (Name)、默认值 (DefaultValue) 和当前配置值 (ValueInFile)。当执行此命令时,若同时指定了 `-C` 或 `--config` 参数,则对应的配置文件包含的配置项会同时输出当前配置值和默认值,其他未指定的配置项仅输出默认值,示例如下:

```json
{
"Component": "TiKV Server",
"Version": "6.2.0",
"Parameters": [
{
"Name": "log-level",
"DefaultValue": "info",
"ValueInFile": "warn"
},
{
"Name": "log-file",
"DefaultValue": ""
},
...
]
}
```

## `--data-dir`

+ TiKV 数据存储路径。
Expand Down