Skip to content
This repository was archived by the owner on Jul 24, 2024. It is now read-only.
This repository was archived by the owner on Jul 24, 2024. It is now read-only.

BR full restore won't rebase auto_random counter #241

@3pointer

Description

@3pointer

Please answer these questions before submitting your issue. Thanks!

  1. What did you do?
    If possible, provide a recipe for reproducing the error.
    BR didn't rebase auto_random after restore

    1. set tidb config auto_random to true.
    2. create table t(a int key auto_random); insert into t values (), (), ();
    3. br backup table --db t --table t --pd xxx -s xxx
    4. drop table t
    5. br restore table --db t --table t --pd xxx -s xxx
    6. insert into t values (),(),();

before backup:

MySQL [t]> select a & b'0000011111111111111111111111111' from t.t;
+----------------------------------------+
| a & b'0000011111111111111111111111111' |
+----------------------------------------+
|                                      1 |
|                                      2 |
|                                      3 |
+----------------------------------------+
  1. What did you expect to see?

after restore:

select a & b'0000011111111111111111111111111' from t.t;
+----------------------------------------+
| a & b'0000011111111111111111111111111' |
+----------------------------------------+
|                                      4 |
|                                      5 |
|                                      6 |
|                                      1 |
|                                      2 |
|                                      3 |
+----------------------------------------+
  1. What did you see instead?

after restore:

select a & b'0000011111111111111111111111111' from t.t;
+----------------------------------------+
| a & b'0000011111111111111111111111111' |
+----------------------------------------+
|                                      1 |
|                                      2 |
|                                      3 |
|                                      1 |
|                                      2 |
|                                      3 |
+----------------------------------------+
  1. What version of BR and TiDB/TiKV/PD are you using?
    master

Metadata

Metadata

Assignees

No one assigned

    Labels

    type/bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions