-
Type:
Bug
-
Resolution: Fixed
-
Priority:
Major - P3
-
Affects Version/s: None
-
Component/s: Transactions
-
Storage Engines
-
StorEng - 2024-12-24
-
5
In this patch build, it generates the following failure:
[2024/12/06 18:53:29.930] [Current thread is 1 (Thread 0xffff87fff1f0 (LWP 13623))] [2024/12/06 18:53:29.930] #0 0x0000ffff9fb5d834 in raise () from /lib64/libc.so.6 [2024/12/06 18:53:29.951] #1 0x0000ffff9fb5f140 in abort () from /lib64/libc.so.6 [2024/12/06 18:53:29.951] #2 0x0000ffff9ff0e338 in __wt_abort (session=session@entry=0x43d5cd0) at /data/mci/9136bc97f64ddc569d0dd65d56b3ac8d/wiredtiger/src/os_common/os_abort.c:31 [2024/12/06 18:53:29.952] #3 0x0000ffff9ffb95c0 in __wt_txn_timestamp_usage_check (session=session@entry=0x43d5cd0, op=op@entry=0xffff800097c0, op_ts=<optimized out>, prev_op_durable_ts=56939) at /data/mci/9136bc97f64ddc569d0dd65d56b3ac8d/wiredtiger/src/include/txn_inline.h:610 [2024/12/06 18:53:29.969] #4 0x0000ffff9ffbb750 in __txn_resolve_prepared_op (session=session@entry=0x43d5cd0, op=op@entry=0xffff800097c0, commit=commit@entry=true, cursorp=cursorp@entry=0xffff87ffe448) at /data/mci/9136bc97f64ddc569d0dd65d56b3ac8d/wiredtiger/src/txn/txn.c:1239 [2024/12/06 18:53:29.981] #5 0x0000ffff9ffc0438 in __wt_txn_commit (session=session@entry=0x43d5cd0, cfg=cfg@entry=0xffff87ffe4e8) at /data/mci/9136bc97f64ddc569d0dd65d56b3ac8d/wiredtiger/src/txn/txn.c:1793 [2024/12/06 18:53:29.982] #6 0x0000ffff9ff75928 in __session_commit_transaction (wt_session=0x43d5cd0, config=<optimized out>) at /data/mci/9136bc97f64ddc569d0dd65d56b3ac8d/wiredtiger/src/session/session_api.c:1832 [2024/12/06 18:53:29.982] #7 0x00000000004107f0 in commit_transaction (tinfo=tinfo@entry=0x48daa10, prepared=prepared@entry=true) at /data/mci/9136bc97f64ddc569d0dd65d56b3ac8d/wiredtiger/test/format/ops.c:588 [2024/12/06 18:53:29.982] #8 0x000000000041592c in ops (arg=0x48daa10) at /data/mci/9136bc97f64ddc569d0dd65d56b3ac8d/wiredtiger/test/format/ops.c:1394 [2024/12/06 18:53:29.982] #9 0x0000ffff9fcfa230 in start_thread () from /lib64/libpthread.so.0 [2024/12/06 18:53:29.982] #10 0x0000ffff9fc067dc in thread_start () from /lib64/libc.so.6
(gdb) p *txn
$1 = {
id = 47285,
isolation = WT_ISO_SNAPSHOT,
forced_iso = 0,
txn_logsync = 0,
snapshot_data = {
snap_max = 47286,
snap_min = 47286,
snapshot = 0xffff80004c10,
snapshot_count = 0
},
backup_snapshot_data = 0x0,
commit_timestamp = 56934,
durable_timestamp = 56934,
first_commit_timestamp = 56934,
prepare_timestamp = 56932,
checkpoint_read_timestamp = 0,
checkpoint_stable_timestamp = 0,
checkpoint_oldest_timestamp = 0,
mod = 0xffff80009600,
mod_alloc = 1120,
mod_count = 6,
prepare_count = 5,
logrec = 0x0,
ckpt_lsn = {
l = {
offset = 0,
file = 0
},
file_offset = 0
},
ckpt_nsnapshot = 0,
ckpt_snapshot = 0x0,
full_ckpt = false,
operation_timeout_us = 2000000,
rollback_reason = 0x0,
flags = 25212,
__snapshot = 0xffff80004c10
}
(gdb) p *upd
$2 = {
txnid = 47307,
durable_ts = 0,
start_ts = 56957,
prev_durable_ts = 56939,
next = 0xffff6847c430,
size = 40,
type = 3 '\003',
prepare_state = 1 '\001',
flags = 0 '\000',
data = 0xffff685ff1cf "0000000001/OMNOPQRSTfedcbtsrqponcbazyxwv"
}
(gdb) p *upd->next
$3 = {
txnid = 47290,
durable_ts = 56939,
start_ts = 56939,
prev_durable_ts = 56937,
next = 0xffff6823ff10,
size = 35,
type = 3 '\003',
prepare_state = 0 '\000',
flags = 0 '\000',
data = 0xffff6847c45f "0000000001/OMNOPQRSTUV--j-----srqpo"
}
(gdb) p *upd->next->next
$4 = {
txnid = 47288,
durable_ts = 56937,
start_ts = 56937,
prev_durable_ts = 56934,
next = 0xffff800e03c0,
size = 22,
type = 3 '\003',
prepare_state = 0 '\000',
flags = 0 '\000',
data = 0xffff6823ff3f "0000000001/OMNOPQRSTUV"
}
The core dump shows that we are committing on a prepared update that is not written by the transaction. I double checked the key and it is matching. Therefore, it seems we land on the right key. I suspect we missed handling a write conflict and we didn't successfully write the update for that prepared update in the test.