Skip to content

Commit

Permalink
Lock Omap file before changing it to protect against multi gateway co…
Browse files Browse the repository at this point in the history
…rruption

In case the Omap file was changed, read it again before trying to change it
Fixes #56

Signed-off-by: Gil Bregman <[email protected]>
  • Loading branch information
gbregman committed Nov 7, 2023
1 parent 643879a commit 1bf23ec
Show file tree
Hide file tree
Showing 6 changed files with 649 additions and 385 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-container.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ jobs:
strategy:
fail-fast: false
matrix:
test: ["cli", "state", "multi_gateway", "server", "grpc"]
test: ["cli", "state", "multi_gateway", "server", "grpc", "omap_lock"]
runs-on: ubuntu-latest
env:
HUGEPAGES: 512 # for multi gateway test, approx 256 per gateway instance
Expand Down
4 changes: 4 additions & 0 deletions ceph-nvmeof.conf
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,10 @@ state_update_interval_sec = 5
#min_controller_id = 1
#max_controller_id = 65519
enable_spdk_discovery_controller = False
#omap_file_lock_duration = 60
#omap_file_lock_retries = 15
#omap_file_lock_retry_sleep_interval = 5
#omap_file_update_retries = 10

[discovery]
addr = 0.0.0.0
Expand Down
Loading

0 comments on commit 1bf23ec

Please sign in to comment.