You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug]: restore from pitr report 'FATAL' error. #19357
similar to #19288, the result of the query based on the primary key returns 0 rows.
{"level":"FATAL","time":"2024/10/15 10:39:28.348482 +0000","name":"cn-service","caller":"incrservice/store_sql.go:153","msg":"BUG: read incr record invalid","service":"30663632-6334-6633-3961-313239613832","uuid":"30663632-6334-6633-3961-313239613832","fetch-sql":"select offset, step from mo_increment_columns where table_id = 272927 and col_name = '__mo_fake_pk_col' for update","account":0,"table":272927,"col":"__mo_fake_pk_col","rows":0,"cost":"63.832666ms","ctx-done":false,"stacktrace":"github.com/matrixorigin/matrixone/pkg/incrservice.(*sqlStore).Allocate.func2\n\t/go/src/github.com/matrixorigin/matrixone/pkg/incrservice/store_sql.go:153\ngithub.com/matrixorigin/matrixone/pkg/sql/compile.(*sqlExecutor).ExecTxn\n\t/go/src/github.com/matrixorigin/matrixone/pkg/sql/compile/sql_executor.go:134\ngithub.com/matrixorigin/matrixone/pkg/incrservice.(*sqlStore).Allocate\n\t/go/src/github.com/matrixorigin/matrixone/pkg/incrservice/store_sql.go:129\ngithub.com/matrixorigin/matrixone/pkg/incrservice.(*allocator).doAllocate\n\t/go/src/github.com/matrixorigin/matrixone/pkg/incrservice/allocator.go:173\ngithub.com/matrixorigin/matrixone/pkg/incrservice.(*allocator).run\n\t/go/src/github.com/matrixorigin/matrixone/pkg/incrservice/allocator.go:160\ngithub.com/matrixorigin/matrixone/pkg/common/stopper.(*Stopper).doRunCancelableTask.func1\n\t/go/src/github.com/matrixorigin/matrixone/pkg/common/stopper/stopper.go:277"}
The prolonged restore transaction 481c93f16e7a211117fe1ab03e64c04e took over five hours before it failed, involving a large workspace.
Despite the insert SQL statement(insert into mo_increment_columns(table_id, col_name, col_index, offset, step) values(272927, '__mo_fake_pk_col', 25, 0, 1)) executing successfully less than 200ms earlier, the subsequent select SQL statement could not retrieve that record from the workspace.
This issue has not been reproduced locally. Let's see what the newly added log can tell upon reproduction in the big-data test
Activity
sukki37 commentedon Oct 15, 2024
similar to #19288, the result of the query based on the primary key returns 0 rows.
{"level":"FATAL","time":"2024/10/15 10:39:28.348482 +0000","name":"cn-service","caller":"incrservice/store_sql.go:153","msg":"BUG: read incr record invalid","service":"30663632-6334-6633-3961-313239613832","uuid":"30663632-6334-6633-3961-313239613832","fetch-sql":"select offset, step from mo_increment_columns where table_id = 272927 and col_name = '__mo_fake_pk_col' for update","account":0,"table":272927,"col":"__mo_fake_pk_col","rows":0,"cost":"63.832666ms","ctx-done":false,"stacktrace":"github.com/matrixorigin/matrixone/pkg/incrservice.(*sqlStore).Allocate.func2\n\t/go/src/github.com/matrixorigin/matrixone/pkg/incrservice/store_sql.go:153\ngithub.com/matrixorigin/matrixone/pkg/sql/compile.(*sqlExecutor).ExecTxn\n\t/go/src/github.com/matrixorigin/matrixone/pkg/sql/compile/sql_executor.go:134\ngithub.com/matrixorigin/matrixone/pkg/incrservice.(*sqlStore).Allocate\n\t/go/src/github.com/matrixorigin/matrixone/pkg/incrservice/store_sql.go:129\ngithub.com/matrixorigin/matrixone/pkg/incrservice.(*allocator).doAllocate\n\t/go/src/github.com/matrixorigin/matrixone/pkg/incrservice/allocator.go:173\ngithub.com/matrixorigin/matrixone/pkg/incrservice.(*allocator).run\n\t/go/src/github.com/matrixorigin/matrixone/pkg/incrservice/allocator.go:160\ngithub.com/matrixorigin/matrixone/pkg/common/stopper.(*Stopper).doRunCancelableTask.func1\n\t/go/src/github.com/matrixorigin/matrixone/pkg/common/stopper/stopper.go:277"}
aptend commentedon Oct 17, 2024
The log indicates:
481c93f16e7a211117fe1ab03e64c04etook over five hours before it failed, involving a large workspace.insert into mo_increment_columns(table_id, col_name, col_index, offset, step) values(272927, '__mo_fake_pk_col', 25, 0, 1)) executing successfully less than 200ms earlier, the subsequent select SQL statement could not retrieve that record from the workspace.This issue has not been reproduced locally. Let's see what the newly added log can tell upon reproduction in the big-data test
aptend commentedon Oct 18, 2024
After conducting some tests, it seems that the issue is not related to S3 flushing. Instead, the txnOffset seems to be worthy of further investigation
aptend commentedon Oct 21, 2024
No luck in reproducing the issue.
Ariznawlll commentedon Oct 22, 2024
Same restore operation to repro this issue,but mo oom unfortunately, details in issue #19511
aptend commentedon Oct 23, 2024
No repro yet, consider downgrading its severity
aressu1985 commentedon Oct 24, 2024
一致复现不了,先降级处理
Ariznawlll commentedon Oct 30, 2024
job url: https://github.com/matrixorigin/mo-nightly-regression/actions/runs/11575242906/job/32222238080
restore执行的sql:RESTORE ACCOUNT sys FROM SNAPSHOT sys_sp01
数据量:大约1.2T
log: https://grafana.ci.matrixorigin.cn/explore?panes=%7B%22tFc%22:%7B%22datasource%22:%22loki%22,%22queries%22:%5B%7B%22refId%22:%22A%22,%22expr%22:%22%7Bnamespace%3D%5C%22mo-snapshot-test-20241029%5C%22%7D%22,%22queryType%22:%22range%22,%22datasource%22:%7B%22type%22:%22loki%22,%22uid%22:%22loki%22%7D,%22editorMode%22:%22builder%22%7D%5D,%22range%22:%7B%22from%22:%221730218087000%22,%22to%22:%221730230669000%22%7D%7D%7D&schemaVersion=1&orgId=1
XuPeng-SH commentedon Nov 1, 2024
fixed
Ariznawlll commentedon Nov 2, 2024
fixed