DBAtlas · Database operations atlas

ERR WAIT cannot be used with replica instances: WAIT cannot be used with replica instances

Redis

What does it mean?

WAIT was run on a replica (replica/slave) instance. WAIT, which waits for a write to reach a given number of replicas, is meaningful only on the primary (master); it cannot be used on a replica.

Why does it happen?

The application mistakenly sent WAIT over a replica connection. This usually happens because the connection is routed to a read replica, or because the client is still connected to a replica after a role change (failover).

How to fix it

Send WAIT only to the primary node. Make sure the client/proxy configuration routes writes and WAIT calls to the master. Detect role changes after failover and redirect connections to the new primary (you can verify the role with the ROLE command).

Open in DBAtlas →

More from this engine