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
rabbit_db: Skip reset if the node is already virgin
[Why]
If we run `reset` again on an already virgin node, it will take
decisions based on the wrong state. In particular, the previous use of
Khepri or Mnesia is lost with the first reset. Therefore, the second
reset wolud delete non-Khepri related files that belong to the
coordination Ra system.
This is particularily problematic with the previously documented way of
joining two nodes using the CLI:
rabbitmqctl stop_app
rabbitmqctl reset
rabbitmqctl join_cluster $REMOTE_NODE
rabbitmqctl start_app
Indeed, `join_cluster` implies a reset. If the admin already reset the
node as documented, `join_cluster` implied reset would delete too many
files, breaking Khepri after the join if Khepri is used by the remote
node.
[How]
In `rabbit_db:reset/0`, we skip the reset if the node is already virgin.
Fixes #14748.
0 commit comments