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 configs: add 7 log-related configs (#6996) #7061

Merged
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
40 changes: 39 additions & 1 deletion tikv-configuration-file.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,51 @@ TiKV 配置文件比命令行参数支持更多的选项。你可以在 [etc/con

+ 默认值:false

### `log-level`

+ 日志等级。
+ 可选值:"trace","debug","info","warning","error","critical"
+ 默认值:"info"

### `log-file`

+ 日志文件。如果未设置该项,日志会默认输出到 "stderr"。
+ 默认值:""

### `log-format`

+ 日志的格式。
+ 可选值:"json","text"
+ 默认值:"text"

### `log-rotation-timespan`

+ 轮换日志的时间跨度。当超过该时间跨度,日志文件会被轮换,即在当前日志文件的文件名后附加一个时间戳,并创建一个新文件。
+ 默认值:"24h"

### `log-rotation-size`

+ 触发日志轮换的文件大小。一旦日志文件大小超过指定的阈值,日志文件将被轮换,将旧文件被置于新文件中,新文件名即旧文件名加上时间戳后缀。
+ 默认值:"300MB"

### `slow-log-file`

+ 存储慢日志的文件。
+ 如果未设置本项但设置了 `log-file`,慢日志将输出至 `log-file` 指定的日志文件中。如果本项和 `log-file` 均未设置,所有日志默认输出到 "stderr"。
+ 默认值:""

### `slow-log-threshold`

+ 输出慢日志的阈值。处理时间超过该阈值后会输出慢日志。
+ 默认值:"1s"

## server

服务器相关的配置项。

### `status-thread-pool-size`

+ Http API 服务的工作线程数量。
+ HTTP API 服务的工作线程数量。
+ 默认值:1
+ 最小值:1

Expand Down