pingcap / tidb-lightning

This repository has been moved to https://github.com/pingcap/br
Apache License 2.0
142 stars 66 forks source link

*: add method to check whether need local SST of table #491

Closed lance6716 closed 3 years ago

lance6716 commented 3 years ago

What problem does this PR solve?

in DBaaS environment resuming TiDB can't assure existence of local SST, so we should add a checking method.

What is changed and how it works?

status between "chunk position > chunk start offset" and "index engine imported" have unrecoverable data in local SST, so check it

Check List

Tests

Side effects

Related changes

lance6716 commented 3 years ago

ping @glorv @kennytm

lance6716 commented 3 years ago

/run-all-tests

lance6716 commented 3 years ago

/run-all-tests

config 'tikv-importer.backend' value 'local' different from checkpoint value 'importer', please destroy all checkpoints and remove all restored tables and try again

don't know why test local_backend will generate importer backend checkpoint

lance6716 commented 3 years ago

/run-all-tests

tidb lightning encountered error: restore table cpeng.b failed: pebble: could not open manifest file "MANIFEST-000001" for DB "/tmp/lightning_test_result/sorted/7553a9f1-d15d-58e9-9d34-99cd0ed0a85e": open /tmp/lightning_test_result/sorted/7553a9f1-d15d-58e9-9d34-99cd0ed0a85e/MANIFEST-000001: no such file or directory

lance6716 commented 3 years ago

ping @glorv

glorv commented 3 years ago

LGTM

kennytm commented 3 years ago

LGTM