Skip to content

tiup: clarify limits.conf behavior in no-sudo mode#21729

Open
doc-claw-bot wants to merge 4 commits into
pingcap:masterfrom
doc-claw-bot:docs/nosudo-limits-user-manager
Open

tiup: clarify limits.conf behavior in no-sudo mode#21729
doc-claw-bot wants to merge 4 commits into
pingcap:masterfrom
doc-claw-bot:docs/nosudo-limits-user-manager

Conversation

@doc-claw-bot

@doc-claw-bot doc-claw-bot commented Jun 23, 2026

Copy link
Copy Markdown

What is changed, added or deleted? (Required)

This PR updates the Chinese TiUP no-sudo documentation to clarify how resource limits take effect for the per-user systemd manager.

  • Clarify that /etc/security/limits.conf might be applied through PAM when user@<UID>.service starts, but the effective Max open files value still depends on the limits obtained by the user manager itself.
  • Add a verification step to check the effective Max open files value of the running user@${uid}.service.
  • Add a documented fallback: if the effective value is still too low, configure a system-level drop-in for user@${uid}.service with LimitNOFILE=1000000.
  • Explain that restarting user@${uid}.service stops all user services managed by that user, so existing clusters should be stopped first or handled in a maintenance window.

Which TiDB version(s) do your changes apply to? (Required)

Tips for choosing the affected version(s):

By default, CHOOSE MASTER ONLY so your changes will be applied to the next TiDB major or minor releases. If your PR involves a product feature behavior change or a compatibility change, CHOOSE THE AFFECTED RELEASE BRANCH(ES) AND MASTER.

For details, see tips for choosing the affected versions (in Chinese).

  • master (the latest development version)
  • v9.0 (TiDB 9.0 versions)
  • v8.5 (TiDB 8.5 versions)
  • v8.1 (TiDB 8.1 versions)
  • v7.5 (TiDB 7.5 versions)
  • v7.1 (TiDB 7.1 versions)
  • v6.5 (TiDB 6.5 versions)
  • v6.1 (TiDB 6.1 versions)

What is the related PR or file link(s)?

Do your changes match any of the following descriptions?

  • Delete files
  • Change aliases
  • Need modification after applied to another branch
  • Might cause conflicts after applied to another branch

@ti-chi-bot ti-chi-bot Bot added contribution This PR is from a community contributor. first-time-contributor Indicates that the PR was contributed by an external member and is a first-time contributor. labels Jun 23, 2026
@ti-chi-bot

ti-chi-bot Bot commented Jun 23, 2026

Copy link
Copy Markdown

Hi @doc-claw-bot. Thanks for your PR.

I'm waiting for a pingcap member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@ti-chi-bot ti-chi-bot Bot added needs-ok-to-test Indicates a PR created by contributors and need ORG member send '/ok-to-test' to start testing. missing-translation-status This PR does not have translation status info. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Jun 23, 2026
@ti-chi-bot

ti-chi-bot Bot commented Jun 23, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign oreoxmt for approval. For more information see the Code Review Process.
Please ensure that each of them provides their approval before proceeding.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@ti-chi-bot ti-chi-bot Bot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Jun 23, 2026
@qiancai qiancai added translation/done This PR has been translated from English into Chinese and updated to pingcap/docs-cn in a PR. and removed missing-translation-status This PR does not have translation status info. labels Jun 23, 2026
@lilin90 lilin90 self-assigned this Jun 24, 2026
@lilin90 lilin90 added translation/from-docs This PR is translated from a PR in pingcap/docs. ONCALL Relates to documentation oncall. and removed translation/done This PR has been translated from English into Chinese and updated to pingcap/docs-cn in a PR. labels Jun 24, 2026
@lilin90

lilin90 commented Jun 24, 2026

Copy link
Copy Markdown
Member

/ok-to-test

@ti-chi-bot ti-chi-bot Bot added ok-to-test Indicates a PR is ready to be tested. and removed needs-ok-to-test Indicates a PR created by contributors and need ORG member send '/ok-to-test' to start testing. labels Jun 24, 2026
@lilin90 lilin90 requested a review from Copilot June 24, 2026 02:51

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the Chinese TiUP no-sudo deployment documentation to clarify how file descriptor limits (nofile) actually take effect under per-user systemd (user@<UID>.service) and to provide concrete verification and remediation steps.

Changes:

  • Explain why /etc/security/limits.conf may not fully determine the effective Max open files for the per-user systemd manager in no-sudo mode.
  • Add steps to restart user@${uid}.service after updating limits, verify the effective limit via /proc/<pid>/limits, and document a system-level drop-in fallback using LimitNOFILE=1000000.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

$ systemctl restart user@${uid}.service
```

3. 检查运行中的 `user@${uid}.service` 实际生效的 `Max open files` 值。
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

contribution This PR is from a community contributor. first-time-contributor Indicates that the PR was contributed by an external member and is a first-time contributor. ok-to-test Indicates a PR is ready to be tested. ONCALL Relates to documentation oncall. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. translation/from-docs This PR is translated from a PR in pingcap/docs.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants