pingcap / pingcap/docs

Improve documentation of tidb-server oom behavior

Open
#4,477 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

lifecycle/frozen
Dominant language
Python
Stars
617
Forks
724
Avg merge
2d 10h
Merged PRs (30d)
223

Description

Change Request

This repository is ONLY used to solve issues related to DOCS.
For other issues (related to TiDB, PD, etc), please move to other repositories.

Please answer the following questions before submitting your issue. Thanks!

  1. Describe what you find is inappropriate or missing in the existing docs.

The current explanations of TiDB memory management and behavior when a query uses a large amount of memory are incomplete and confusing.

  1. Describe your suggestion or addition.

https://docs.pingcap.com/tidb/dev/configure-memory-usage discusses configuration and behavior of some options, but it does not discuss the circumstances or operation of oom-use-tmp-storage, which controls whether large operations can be "spilled" to disk.

https://docs.pingcap.com/tidb/dev/tidb-configuration-file#oom-use-tmp-storage should be updated to clarify what "some operators" means. Which operators can use temporary storage and which can't? Can the location of the temporary storage be configured? How can usage of this temporary storage be monitored?

  1. Provide some reference materials (documents, websites, etc) if you could.

@tiancaiamao reports:

  • sort and merge join and hash join may use conf.OOMUseTmpStorage
  • aggregates cannot spill to disk

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the memory-management page and the tidb-configuration-file#oom-use-tmp-storage section named in the issue. Verify the documented behavior for sort, merge join, hash join, and aggregates, then determine how temporary-storage location and usage monitoring are covered. Done means the documentation clearly explains which operators can spill to disk, which cannot, and how the temporary storage is configured and monitored.

Written by the indexing model from the issue text.

Assessment

Tech stack
sql
Domain
databases, documentation
Issue type
Documentation
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.