Steps to delete mirroring policies in RabbitMQ
search cancel

Steps to delete mirroring policies in RabbitMQ

book

Article ID: 433537

calendar_today

Updated On:

Products

VMware Tanzu Data Suite

Issue/Introduction

RabbitMQ upgrade might fail with below error:

From the logs we could see that:
2026-03-16 13:09:33.520000+00:00 [error] <0.3001.0> BOOT FAILED
2026-03-16 13:09:33.520000+00:00 [error] <0.3001.0> ===========
2026-03-16 13:09:33.520000+00:00 [error] <0.3001.0> Error during startup: {error,
2026-03-16 13:09:33.520000+00:00 [error] <0.3001.0>                           {failed_to_deny_deprecated_features,
2026-03-16 13:09:33.520000+00:00 [error] <0.3001.0>                               [classic_queue_mirroring]}}
2026-03-16 13:09:33.520000+00:00 [error] <0.3001.0> 

This error means the RabbitMQ node refused to start because it detected that a deprecated feature, classic queue mirroring, is still in use while the configuration says it must be denied.

Cause

Classic queue mirroring is deprecated and removed in 4.*

Having policies related to mirroring can cause issues in upgrade.

Resolution

The recommended procedure for safely removing HA policies in a cluster(precautions).

-Export your definitions (rabbitmqctl export_definitions /path/to/definitions.file.json) before making changes so you can restore the policy structure if needed.
-Before removing the policy, ensure all queues are in a Synchronized state. Removing a policy from an unsynchronized queue can lead to data gaps if the leader is currently lagging.
-It is recommended to pause/stop publishers. This prevents new data from entering a "non-redundant" state during the transition.
-Ensure all messages from Classic Queues are consumed before the upgrade.

-Identify Policies. Run rabbitmqctl list_policies to find any policy containing ha-mode, ha-params, or ha-sync-mode.

-Use below command to remove policies:
rabbitmqctl -q remove_classic_queue_mirroring_from_policies

-Verify. Run rabbitmqctl list_policies again to ensure the "Definition" column no longer contains ha- keys.

-Once the metadata is clean, proceed with the RabbitMQ 4.* installation.