Note:
This topic has been translated from a Chinese forum by GPT and might contain errors.
Original topic: tidb没有tidb_enable_paging变量是什么原因?
[TiDB Usage Environment] Production Environment
[TiDB Version] 6.1.7
[Reproduction Path] TiDB cluster set up using tidb-operator, mostly referring to the official documentation’s manifest
[Encountered Problem: Problem Phenomenon and Impact]
show variables like ‘%paging%’;
No variables are displayed, not sure what the reason is? Do I need to upgrade to 6.5.x?
According to the documentation, this was introduced in v5.4.0.
Could it be related to the way tidb-operator works?
The tidb-operator is version v1.4.7, and it was deployed according to the official steps.
The official documentation for version 6.1 has this.
show variables like ‘tidb_enable%’; What does it have?
6.1 This field is still in a hidden state, but it will be visible after 6.2.
Variables in a hidden state can be set, but you cannot see them.
{Scope: ScopeGlobal | ScopeSession, Name: TiDBEnablePaging, Value: Off, Type: TypeBool, Hidden: true, SetSession: func(s *SessionVars, val string) error {
Hidden: true
{Scope: ScopeGlobal | ScopeSession, Name: TiDBEnablePaging, Value: BoolToOnOff(DefTiDBEnablePaging), Type: TypeBool, Hidden: true, SetSession: func(s *SessionVars, val string) error {
s.EnablePaging = TiDBOptOn(val)
return nil
}
This PR removes the Hidden keyword, so this situation no longer exists.
pingcap:master
← morgo:remove-hidden-sysvars
opened 02:36AM - 27 Jun 22 UTC
### What problem does this PR solve?
Issue Number: close https://github.com/p… ingcap/tidb/issues/35735
Problem Summary:
Hidden system variables are problematic. Despite a[ previously accepted proposal to stop using them](https://github.com/pingcap/tidb/blob/master/docs/design/2021-07-29-hidden-sysvars.md), more have been added. Because between versions hidden variables have been changed in values, clusters are not comparable. The worst case of this was with async_commit which was hidden when introduced, changed behaviors considerably, and has had bugs. But the same can be said of `tidb_enable_mutation_checker` which results in errors in new clusters, which are not present in old clusters, and comparing show variables reveals no insights.
The QA team's process to compare variables between releases is to run `show variables`. There's no QA for changing values of hidden variables :(
This disables support for hidden variables. I hope that you can merge it so that I don't have to carry a separate patch to remove it from my builds.
### What is changed and how it works?
### Check List
Tests
- [x] Unit test
- [ ] Integration test
- [ ] Manual test (add detailed scripts or steps below)
- [ ] No code
Side effects
- [ ] Performance regression: Consumes more CPU
- [ ] Performance regression: Consumes more Memory
- [ ] Breaking backward compatibility
Documentation
- [ ] Affects user behaviors
- [ ] Contains syntax changes
- [x] Contains variable changes
Makes all previously hidden variables visible.
- [ ] Contains experimental features
- [ ] Changes MySQL compatibility
### Release note
Please refer to [Release Notes Language Style Guide](https://pingcap.github.io/tidb-dev-guide/contribute-to-tidb/release-notes-style-guide.html) to write a quality release note.
```release-note
Previously some system variables were hidden from the output of `show variables`. All variables are now made visible.
```
// Deprecated: Hidden previously meant that the variable still responds to SET but doesn't show up in SHOW VARIABLES
// However, this feature is no longer used. All variables are visible.
It should be a version issue.
In the future, strange issues will have to be directly sourced~
This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.