为提高效率,提问时请提供以下信息,问题描述清晰可优先响应。
- 【TiDB 版本】:4.0.0
- 【问题描述】:lightning 无法准确判断是否导入完整
反馈一个lightning的问题,目前通过process的进度无法判断是否导完整。晚点进行全量比对来确定数据是否完整。
这个版本默认开启了analyze table。但是pay_purchase没进行analyze,目前手工在跑
在lightning中的最后的日志
[2020/06/02 14:51:47.818 +08:00] [INFO] [restore.go:1357] ["import and cleanup engine completed"] [engineTag=`pay`.`pay_bill`:-1] [engineUUID=1bcc341d-07ce-5529-9aae-f00881124834] [takeTime=19m9.082370848s] []
[2020/06/02 14:51:47.820 +08:00] [INFO] [tidb.go:238] ["alter table auto_increment start"] [table=`pay`.`pay_bill`] [auto_increment=1]
[2020/06/02 14:51:48.832 +08:00] [INFO] [tidb.go:240] ["alter table auto_increment completed"] [table=`pay`.`pay_bill`] [auto_increment=1] [takeTime=1.011917343s] []
[2020/06/02 14:51:48.832 +08:00] [INFO] [restore.go:1058] ["local checksum"] [table=`pay`.`pay_bill`] [checksum="{cksum=2218256298104834937,size=1549389486622,kvs=17525022690}"]
[2020/06/02 14:51:48.839 +08:00] [INFO] [restore.go:1424] ["remote checksum start"] [table=`pay`.`pay_bill`]
[2020/06/02 14:56:11.193 +08:00] [INFO] [restore.go:503] [progress] [files="5109/6641 (76.9%)"] [tables="49/51 (96.1%)"] [speed(MiB/s)=34.04884868177228] [state=writing] [remaining=3h2m55s]
[2020/06/02 14:59:59.381 +08:00] [INFO] [restore.go:1438] ["remote checksum completed"] [table=`pay`.`pay_bill`] [takeTime=8m10.541698186s] []
[2020/06/02 14:59:59.387 +08:00] [INFO] [restore.go:1387] ["checksum pass"] [table=`pay`.`pay_bill`] [local="{cksum=2218256298104834937,size=1549389486622,kvs=17525022690}"]
[2020/06/02 14:59:59.387 +08:00] [INFO] [restore.go:1392] ["analyze start"] [table=`pay`.`pay_bill`]
[2020/06/02 15:01:11.193 +08:00] [INFO] [restore.go:503] [progress] [files="5109/6641 (76.9%)"] [tables="49/51 (96.1%)"] [speed(MiB/s)=33.772028705470156] [state=writing] [remaining=3h4m25s]
[2020/06/02 15:06:11.202 +08:00] [INFO] [restore.go:503] [progress] [files="5109/6641 (76.9%)"] [tables="49/51 (96.1%)"] [speed(MiB/s)=33.49966523015206] [state=writing] [remaining=3h5m55s]
[2020/06/02 15:11:11.197 +08:00] [INFO] [restore.go:503] [progress] [files="5109/6641 (76.9%)"] [tables="49/51 (96.1%)"] [speed(MiB/s)=33.23167263310829] [state=writing] [remaining=3h7m25s]
[2020/06/02 15:16:11.200 +08:00] [INFO] [restore.go:503] [progress] [files="5109/6641 (76.9%)"] [tables="49/51 (96.1%)"] [speed(MiB/s)=32.967926756948486] [state=writing] [remaining=3h8m55s]
[2020/06/02 15:21:11.197 +08:00] [INFO] [restore.go:503] [progress] [files="5109/6641 (76.9%)"] [tables="49/51 (96.1%)"] [speed(MiB/s)=32.7083393744271] [state=writing] [remaining=3h10m25s]
[2020/06/02 15:26:11.194 +08:00] [INFO] [restore.go:503] [progress] [files="5109/6641 (76.9%)"] [tables="49/51 (96.1%)"] [speed(MiB/s)=32.45280768558197] [state=writing] [remaining=3h11m55s]
[2020/06/02 15:28:14.248 +08:00] [INFO] [restore.go:1395] ["analyze completed"] [table=`pay`.`pay_bill`] [takeTime=28m14.861250134s] []
[2020/06/02 15:28:14.248 +08:00] [INFO] [restore.go:600] ["restore table completed"] [table=`pay`.`pay_bill`] [takeTime=8h17m3.25048472s] []
[2020/06/02 15:28:14.249 +08:00] [INFO] [restore.go:266] ["user terminated"] [step=2] [error="restore table `pay`.`pay_purchase` failed: rpc error: code = Canceled desc = Cancelled"]
[2020/06/02 15:28:14.249 +08:00] [INFO] [restore.go:276] ["the whole procedure completed"] [takeTime=10h42m55.297718533s] []
[2020/06/02 15:28:14.248 +08:00] [INFO] [restore.go:472] ["everything imported, stopping periodic actions"]
[2020/06/02 15:28:14.262 +08:00] [INFO] [main.go:82] ["tidb lightning exit"]
在tikv-import中的日志
[2020/06/02 14:50:51.203 +08:00] [INFO] [import.rs:320] ["import sst"] [sst="SSTFile { uuid: 81ab4e40-78ae-425b-8d71-80d7f6101cdb, range: 7480000000000003FFBE5F698000000000FF0000010419A4D6{E0FF67000000038633C0FF5F6C837000000000FCFFFFFFFFA12A749F..E1FFCD000000038633C1FFA581C34001000000FCFFFFFFFFA12A749F}, length: 26358, cf_name: \"write\" }"] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:15:3183]"]
[2020/06/02 14:50:51.204 +08:00] [INFO] [import.rs:363] ["upload and ingest sst"] [region="RegionInfo { region: Region { id: 105661, range: 7480000000000003FFBE5F698000000000FF0000010419A4D6{13FF3A00000003863310FF6F56038000000000FC..E1FFCD000000038633C1FFA584036000000000FC}, region_epoch: RegionEpoch { conf_ver: 5, version: 865 }, peers: [Peer { id: 105662, store_id: 1, is_learner: false }, Peer { id: 105663, store_id: 4, is_learner: false }, Peer { id: 105664, store_id: 5, is_learner: false }] }, leader: Some(Peer { id: 105664, store_id: 5, is_learner: false }) }"] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:15:3183]"]
[2020/06/02 14:50:51.221 +08:00] [INFO] [import.rs:320] ["import sst"] [sst="SSTFile { uuid: ebbf9c8d-e959-4739-ae97-4d927a3faf53, range: 7480000000000003FFBE5F698000000000FF0000010419A4D6{13FF3A00000003863310FF6F56038000000000FCFFFFFFFFA12A749F..E0FF67000000038633C0FF5F5BC37000000000FCFFFFFFFFA12A749F}, length: 70818313, cf_name: \"write\" }"] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:16:3184]"]
[2020/06/02 14:50:51.221 +08:00] [INFO] [import.rs:363] ["upload and ingest sst"] [region="RegionInfo { region: Region { id: 105661, range: 7480000000000003FFBE5F698000000000FF0000010419A4D6{13FF3A00000003863310FF6F56038000000000FC..E1FFCD000000038633C1FFA584036000000000FC}, region_epoch: RegionEpoch { conf_ver: 5, version: 865 }, peers: [Peer { id: 105662, store_id: 1, is_learner: false }, Peer { id: 105663, store_id: 4, is_learner: false }, Peer { id: 105664, store_id: 5, is_learner: false }] }, leader: Some(Peer { id: 105664, store_id: 5, is_learner: false }) }"] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:16:3184]"]
[2020/06/02 14:50:51.235 +08:00] [INFO] [import.rs:478] ["ingest completed"] [region_id=105661] [store=5] [takes=24.141059ms] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:15:3183]"]
[2020/06/02 14:50:51.235 +08:00] [INFO] [import.rs:346] ["import sst completed"] [takes=32.025218ms] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:15:3183]"]
[2020/06/02 14:50:51.236 +08:00] [INFO] [engine.rs:220] ["cleanup SST completed"] [file_path="\"/data32/ssd/data.import/1bcc341d-07ce-5529-9aae-f00881124834/.cc0e2277-43c0-4272-acbf-c48c91595d1b:write\""]
[2020/06/02 14:50:51.599 +08:00] [INFO] [import.rs:478] ["ingest completed"] [region_id=105661] [store=5] [takes=34.448676ms] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:16:3184]"]
[2020/06/02 14:50:51.599 +08:00] [INFO] [import.rs:346] ["import sst completed"] [takes=377.606861ms] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:16:3184]"]
[2020/06/02 14:50:51.599 +08:00] [INFO] [engine.rs:220] ["cleanup SST completed"] [file_path="\"/data32/ssd/data.import/1bcc341d-07ce-5529-9aae-f00881124834/.1cb7f4cc-10b3-43da-b7e6-621f8ce422be:write\""]
[2020/06/02 14:50:52.075 +08:00] [INFO] [import.rs:168] ["dump sst completed"] [sst="[LazySSTInfo { file_path: \"/data32/ssd/data.import/1bcc341d-07ce-5529-9aae-f00881124834/.8c82e7cf-156f-4530-b5e7-1b638302c464:write\", file_size: 69769948, range: Range { start: [116, 128, 0, 0, 0, 0, 0, 3, 255, 190, 95, 105, 128, 0, 0, 0, 0, 255, 0, 0, 3, 3, 133, 211, 212, 20, 255, 197, 131, 80, 0, 4, 25, 164, 208, 255, 42, 231, 0, 0, 0, 3, 134, 47, 255, 72, 107, 240, 67, 64, 0, 0, 0, 253, 255, 255, 255, 255, 161, 42, 116, 159], end: [116, 128, 0, 0, 0, 0, 0, 3, 255, 190, 95, 105, 128, 0, 0, 0, 0, 255, 0, 0, 3, 3, 133, 213, 108, 240, 255, 95, 3, 80, 0, 4, 25, 164, 152, 255, 17, 157, 0, 0, 0, 3, 134, 13, 255, 184, 215, 230, 3, 96, 0, 0, 0, 253, 255, 255, 255, 255, 161, 42, 116, 159] }, cf_name: \"write\" }]"] [range=7480000000000003FFBE5F698000000000FF0000030385{D3D414FFC58350000419A4D0FF2AE700000003862FFF486BF04340000000FDFFFFFFFFA12A749F..D56CF0FF5F0350000419A498FF15E700000003860DFFBCC5C00330000000FDFFFFFFFFA12A749F}] [takes=5.369s]
[2020/06/02 14:50:52.077 +08:00] [INFO] [import.rs:182] ["dispatch-job done"] [ranges_handled=1] [id=9] [tag="[ImportJob 1bcc341d-07ce-5529-9aae-f00881124834]"]
[2020/06/02 14:50:52.097 +08:00] [INFO] [import.rs:320] ["import sst"] [sst="SSTFile { uuid: 7eea01cb-9263-4745-92fa-0f9cadc244b3, range: 7480000000000003FFBE5F698000000000FF0000030385{D3D414FFC58350000419A4D0FF2AE700000003862FFF486BF04340000000FDFFFFFFFFA12A749F..D56CF0FF5F0350000419A498FF119D00000003860DFFB8D7E60360000000FDFFFFFFFFA12A749F}, length: 69769948, cf_name: \"write\" }"] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:18:3185]"]
[2020/06/02 14:50:52.098 +08:00] [INFO] [import.rs:363] ["upload and ingest sst"] [region="RegionInfo { region: Region { id: 114237, range: 7480000000000003FFBE5F698000000000FF0000030385{D3D414FFC58350000419A4D0FF2AE700000003862FFF486BF04340000000FD..D5C80EFF428360000419A5F0FF13780000000386B8FFF5FF920CB0000000FD}, region_epoch: RegionEpoch { conf_ver: 5, version: 1560 }, peers: [Peer { id: 114238, store_id: 1, is_learner: false }, Peer { id: 114239, store_id: 4, is_learner: false }, Peer { id: 114240, store_id: 5, is_learner: false }] }, leader: Some(Peer { id: 114240, store_id: 5, is_learner: false }) }"] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:18:3185]"]
[2020/06/02 14:50:52.438 +08:00] [INFO] [import.rs:478] ["ingest completed"] [region_id=114237] [store=5] [takes=25.405719ms] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:18:3185]"]
[2020/06/02 14:50:52.438 +08:00] [INFO] [import.rs:346] ["import sst completed"] [takes=341.104051ms] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:18:3185]"]
[2020/06/02 14:50:52.438 +08:00] [INFO] [engine.rs:220] ["cleanup SST completed"] [file_path="\"/data32/ssd/data.import/1bcc341d-07ce-5529-9aae-f00881124834/.8c82e7cf-156f-4530-b5e7-1b638302c464:write\""]
[2020/06/02 14:50:59.955 +08:00] [INFO] [import.rs:168] ["dump sst completed"] [sst="[LazySSTInfo { file_path: \"/data32/ssd/data.import/1bcc341d-07ce-5529-9aae-f00881124834/.da8d12e7-92f4-41f7-8fad-f8b2713b3596:write\", file_size: 70675318, range: Range { start: [116, 128, 0, 0, 0, 0, 0, 3, 255, 190, 95, 105, 128, 0, 0, 0, 0, 255, 0, 0, 1, 4, 25, 164, 214, 225, 255, 205, 0, 0, 0, 3, 134, 51, 193, 255, 165, 132, 3, 96, 0, 0, 0, 0, 252, 255, 255, 255, 255, 161, 42, 116, 159], end: [116, 128, 0, 0, 0, 0, 0, 3, 255, 190, 95, 105, 128, 0, 0, 0, 0, 255, 0, 0, 1, 4, 25, 164, 216, 141, 255, 40, 0, 0, 0, 3, 134, 52, 195, 255, 61, 207, 131, 160, 0, 0, 0, 0, 252, 255, 255, 255, 255, 161, 42, 116, 159] }, cf_name: \"write\" }]"] [range=7480000000000003FFBE5F698000000000FF0000010419A4{D6E1FFCD000000038633C1FFA584036000000000FCFFFFFFFFA12A749F..D88DFF28000000038634C3FF3DD2836000000000FCFFFFFFFFA12A749F}] [takes=8.752s]
[2020/06/02 14:50:59.976 +08:00] [INFO] [import.rs:320] ["import sst"] [sst="SSTFile { uuid: ef11f571-d27b-416b-8ceb-f71558c9a4b7, range: 7480000000000003FFBE5F698000000000FF0000010419A4{D6E1FFCD000000038633C1FFA584036000000000FCFFFFFFFFA12A749F..D88DFF28000000038634C3FF3DCF83A000000000FCFFFFFFFFA12A749F}, length: 70675318, cf_name: \"write\" }"] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:2:3186]"]
[2020/06/02 14:50:59.977 +08:00] [INFO] [import.rs:363] ["upload and ingest sst"] [region="RegionInfo { region: Region { id: 105665, range: 7480000000000003FFBE5F698000000000FF0000010419A4{D6E1FFCD000000038633C1FFA584036000000000FC..D891FF26000000038634C5FFFB36037000000000FC}, region_epoch: RegionEpoch { conf_ver: 5, version: 866 }, peers: [Peer { id: 105666, store_id: 1, is_learner: false }, Peer { id: 105667, store_id: 4, is_learner: false }, Peer { id: 105668, store_id: 5, is_learner: false }] }, leader: Some(Peer { id: 105667, store_id: 4, is_learner: false }) }"] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:2:3186]"]
[2020/06/02 14:51:00.097 +08:00] [INFO] [import.rs:320] ["import sst"] [sst="SSTFile { uuid: 9d9fb034-88cd-4103-8ef4-9c5cfeadeba2, range: 7480000000000003FFBE5F698000000000FF0000010419A4D8{8DFF28000000038634C3FF3DD2836000000000FCFFFFFFFFA12A749F..91FF26000000038634C5FFFB35C34000000000FCFFFFFFFFA12A749F}, length: 1210366, cf_name: \"write\" }"] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:12:3187]"]
[2020/06/02 14:51:00.097 +08:00] [INFO] [import.rs:363] ["upload and ingest sst"] [region="RegionInfo { region: Region { id: 105665, range: 7480000000000003FFBE5F698000000000FF0000010419A4{D6E1FFCD000000038633C1FFA584036000000000FC..D891FF26000000038634C5FFFB36037000000000FC}, region_epoch: RegionEpoch { conf_ver: 5, version: 866 }, peers: [Peer { id: 105666, store_id: 1, is_learner: false }, Peer { id: 105667, store_id: 4, is_learner: false }, Peer { id: 105668, store_id: 5, is_learner: false }] }, leader: Some(Peer { id: 105667, store_id: 4, is_learner: false }) }"] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:12:3187]"]
[2020/06/02 14:51:00.163 +08:00] [INFO] [import.rs:478] ["ingest completed"] [region_id=105665] [store=4] [takes=44.287082ms] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:12:3187]"]
[2020/06/02 14:51:00.163 +08:00] [INFO] [import.rs:346] ["import sst completed"] [takes=66.81356ms] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:12:3187]"]
[2020/06/02 14:51:00.163 +08:00] [INFO] [engine.rs:220] ["cleanup SST completed"] [file_path="\"/data32/ssd/data.import/1bcc341d-07ce-5529-9aae-f00881124834/.8f5487b7-e771-4c59-b5b0-c1139ead6f15:write\""]
[2020/06/02 14:51:00.355 +08:00] [INFO] [import.rs:478] ["ingest completed"] [region_id=105665] [store=4] [takes=33.62579ms] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:2:3186]"]
[2020/06/02 14:51:00.355 +08:00] [INFO] [import.rs:346] ["import sst completed"] [takes=378.918897ms] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:2:3186]"]
[2020/06/02 14:51:00.355 +08:00] [INFO] [engine.rs:220] ["cleanup SST completed"] [file_path="\"/data32/ssd/data.import/1bcc341d-07ce-5529-9aae-f00881124834/.da8d12e7-92f4-41f7-8fad-f8b2713b3596:write\""]
[2020/06/02 14:51:05.135 +08:00] [INFO] [import.rs:168] ["dump sst completed"] [sst="[LazySSTInfo { file_path: \"/data32/ssd/data.import/1bcc341d-07ce-5529-9aae-f00881124834/.0a220854-55b4-4c38-a2f7-c25c373fbdeb:write\", file_size: 41356931, range: Range { start: [116, 128, 0, 0, 0, 0, 0, 3, 255, 190, 95, 105, 128, 0, 0, 0, 0, 255, 0, 0, 1, 4, 25, 164, 216, 145, 255, 38, 0, 0, 0, 3, 134, 52, 197, 255, 251, 54, 3, 112, 0, 0, 0, 0, 252, 255, 255, 255, 255, 161, 42, 116, 159], end: [116, 128, 0, 0, 0, 0, 0, 3, 255, 190, 95, 105, 128, 0, 0, 0, 0, 255, 0, 0, 1, 4, 25, 164, 218, 41, 255, 215, 0, 0, 0, 3, 134, 53, 183, 255, 100, 166, 67, 80, 0, 0, 0, 0, 252, 255, 255, 255, 255, 161, 42, 116, 159] }, cf_name: \"write\" }]"] [range=7480000000000003FFBE5F698000000000FF0000010419A4{D891FF26000000038634C5FFFB36037000000000FCFFFFFFFFA12A749F..DA29FFD7000000038635B7FF64A6837000000000FCFFFFFFFFA12A749F}] [takes=5.039s]
[2020/06/02 14:51:05.149 +08:00] [INFO] [import.rs:320] ["import sst"] [sst="SSTFile { uuid: 226cfb41-4de9-4afd-acd4-c1c455ac291e, range: 7480000000000003FFBE5F698000000000FF0000010419A4{D891FF26000000038634C5FFFB36037000000000FCFFFFFFFFA12A749F..DA29FFD7000000038635B7FF64A6435000000000FCFFFFFFFFA12A749F}, length: 41356931, cf_name: \"write\" }"] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:9:3188]"]
[2020/06/02 14:51:05.149 +08:00] [INFO] [import.rs:363] ["upload and ingest sst"] [region="RegionInfo { region: Region { id: 120053, range: 7480000000000003FFBE5F698000000000FF0000010419A4{D891FF26000000038634C5FFFB36037000000000FC..DA32FFA3000000038635BEFF888B036000000000FC}, region_epoch: RegionEpoch { conf_ver: 5, version: 870 }, peers: [Peer { id: 120054, store_id: 1, is_learner: false }, Peer { id: 120055, store_id: 4, is_learner: false }, Peer { id: 120056, store_id: 5, is_learner: false }] }, leader: Some(Peer { id: 120056, store_id: 5, is_learner: false }) }"] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:9:3188]"]
[2020/06/02 14:51:05.160 +08:00] [INFO] [import.rs:182] ["dispatch-job done"] [ranges_handled=1] [id=44] [tag="[ImportJob 1bcc341d-07ce-5529-9aae-f00881124834]"]
[2020/06/02 14:51:05.378 +08:00] [INFO] [import.rs:478] ["ingest completed"] [region_id=120053] [store=5] [takes=25.756177ms] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:9:3188]"]
[2020/06/02 14:51:05.378 +08:00] [INFO] [import.rs:346] ["import sst completed"] [takes=228.898297ms] [tag="[ImportSSTJob 1bcc341d-07ce-5529-9aae-f00881124834:9:3188]"]
[2020/06/02 14:51:05.378 +08:00] [INFO] [engine.rs:220] ["cleanup SST completed"] [file_path="\"/data32/ssd/data.import/1bcc341d-07ce-5529-9aae-f00881124834/.0a220854-55b4-4c38-a2f7-c25c373fbdeb:write\""]
[2020/06/02 14:51:05.380 +08:00] [INFO] [import.rs:99] ["import engine completed"] [takes=1105.683466176s] [tag="[ImportJob 1bcc341d-07ce-5529-9aae-f00881124834]"]
[2020/06/02 14:51:05.381 +08:00] [INFO] [kv_importer.rs:145] ["import completed"] [uuid=1bcc341d-07ce-5529-9aae-f00881124834]
[2020/06/02 14:51:47.814 +08:00] [INFO] [kv_importer.rs:179] ["cleanup completed"] [uuid=1bcc341d-07ce-5529-9aae-f00881124834]