Store v1: Fix three journal replay bugs #157
Open
koolkhel
wants to merge 4 commits from
koolkhel/vitastor:v1-replay-fixes into master
pull from: koolkhel/vitastor:v1-replay-fixes
merge into: vitalif:master
vitalif:master
vitalif:primary-stickiness
vitalif:libvfn
vitalif:canceling
vitalif:immediate-repeering
vitalif:rdma-close-tcp
vitalif:use-degraded-writes
vitalif:fix-write-delete-flow
vitalif:openssl-3.0.12
vitalif:openssl-capture-secrets
vitalif:ignore-small-rdma-end
vitalif:encrypt-batch
vitalif:faster-peering-calc
vitalif:http-hello
vitalif:xxh3-bench
vitalif:create-user-etcd-based
vitalif:aesxts_streaming_nosupport
vitalif:refactor-heap-continue-write
vitalif:ston3lu-patch-0127
vitalif:rdma-credits
vitalif:heap-meta
vitalif:sendmsg-zc-no-more-error
vitalif:fix-clear-refs
vitalif:veeam-trick
vitalif:test-etcd-schizo
vitalif:test
vitalif:test1
vitalif:test2
vitalif:cow-meta
vitalif:kv-readahead
vitalif:qemu-fix-crash-idea
vitalif:eventloop-auto-init-trigger
vitalif:hugo-docs
vitalif:node-mutex-and-postpone
vitalif:check-writeback
vitalif:msgr-iothreads-v2
vitalif:antietcd
vitalif:rel-1.4
vitalif:test-fix-ec-unknown-state-51
vitalif:kv-update
vitalif:kv-debug
vitalif:hotfix-1.2.0
vitalif:rdma-simple-nodp
vitalif:zerocopy-tcp-send
vitalif:csi-staging
vitalif:hotfix-1.1.0
vitalif:hotfix-1.0.0
vitalif:fsync-feedback
vitalif:cached-reads
vitalif:qemu-send-loop
vitalif:test-double-alloc
vitalif:hier-failure-domains
vitalif:mon-self-restart
vitalif:epoch-deletions
vitalif:rdma-flow-control
vitalif:csi-use-vitastor-cli
vitalif:rdma-v2
vitalif:etcd-hide-base64
vitalif:lrc-matrix
vitalif:rm-left-on-dead
vitalif:nfs-proxy-old
vitalif:non-odp-rdma
vitalif:test-zctr
vitalif:separate-data-connections
vitalif:sec_osd_msgr
vitalif:test-assert
vitalif:nbd-vmsplice
vitalif:allow-etcd-address-option
vitalif:rdma-zerocopy
vitalif:rel-0.5
vitalif:openonload
vitalif:sync-io-test
vitalif:trace-sync
vitalif:trace-sqes
vitalif:test-submit-and-wait
vitalif:test-sq-poll
vitalif:blocking-uring-test
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
No description provided.
Delete Branch "koolkhel/vitastor:v1-replay-fixes"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Description
Three store v1 journal replay bugs, found with
test_blockstore_chaos --p-delete 30after #114. Each commit names a seed that fails before it and passes with it.1. Store v1: Start each instance with a journal entry of its own (
--seed 61 --config 14 --steps 30000 --p-delete 30)immediate_commit=all: config 14 is one.vitastor-disk preparezeroes only the first journal block: a fixed start entry would chain into the previous OSD's sectors on a reused disk (commit 4 tests that).2. Store v1: Keep journaled small writes under a deletion (
--seed 553 --config 22 --steps 30000 --p-delete 30)immediate_commit=all.3. Store v1: Do not replay an earlier pass of the journal (
--seed 350 --config 21 --steps 30000 --p-delete 30)crc32_prev) in the superblock'sreservedfield. Replay andvitastor-diskstop on a mismatch. 0, which older versions write, skips the check. A trim also never moves past a sector still open for appends.reserveda meaning. Older binaries ignore it, but please say if you'd rather have a separate field or a version bump. Superblocks written by older versions hold 0, so the first restart after an upgrade is not checked.4. Store v1: Test that a new journal does not chain to an old one
Testing (Ubuntu 24.04, RelWithDebInfo):
test_blockstore_v1: 3 new tests. Each fails without its fix (the last one with a fixed start entry version) and passes with it; all tests pass at every commit.test_blockstore_chaos --p-delete 30, seeds 1-1500 on each of the 12 v1 configurations (18,000 runs): the series passes all, and seeds 1-300 with--steps 30000(3,600 runs) too. Master fails 3 of the 18,000.--seed 553 --config 17is the bug of commit 1.--seed 1204 --config 21and--config 22are a different one: they stop with "deadlock?", the flusher idle with 3 objects queued andtrim_wanted=1. The series does not fix that, it only changes those runs; I'll look into it separately.make build_tests test, as in.gitea/workflows/test.yml: 16 of 16 pass.tests/test_dump_load.shwithOLD=1, plain and with 32k checksums, passes too:vitastor-disk dump-journalandwrite-journalkeep the start entry.Contributor Name
Yury Luneff (MIND Software LLC, https://mindsw.io)
CLA
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.