Returns the number of active failure reports active for a node.
CLUSTER
COUNT-FAILURE-REPORTS
node-id
The command returns the number of failure reports for the specified node. Failure reports are the way Valkey Cluster uses in order to promote a PFAIL
state, that means a node is not reachable, to a FAIL
state, that means that the majority of primaries in the cluster agreed within a window of time that the node is not reachable.
A few more details:
PFAIL
when the node is not reachable for a time greater than the configured node timeout, which is a fundamental configuration parameter of a Valkey Cluster.PFAIL
state are provided in gossip sections of heartbeat packets.PFAIL
condition.PFAIL
, and at the same time collected the majority of other primary nodes failure reports about this node (including itself if it is a primary), then it elevates the failure state of the node from PFAIL
to FAIL
, and broadcasts a message forcing all the nodes that can be reached to flag the node as FAIL
.This command returns the number of failure reports for the current node which are currently not expired (so received within two times the node timeout time). The count does not include what the node we are asking this count believes about the node ID we pass as argument, the count only includes the failure reports the node received from other nodes.
This command is mainly useful for debugging, when the failure detector of Valkey Cluster is not operating as we believe it should.
Integer reply: the number of active failure reports for the node.
O(N) where N is the number of failure reports
@admin @dangerous @slow
ASKING, CLUSTER, CLUSTER ADDSLOTS, CLUSTER ADDSLOTSRANGE, CLUSTER BUMPEPOCH, CLUSTER COUNTKEYSINSLOT, CLUSTER DELSLOTS, CLUSTER DELSLOTSRANGE, CLUSTER FAILOVER, CLUSTER FLUSHSLOTS, CLUSTER FORGET, CLUSTER GETKEYSINSLOT, CLUSTER HELP, CLUSTER INFO, CLUSTER KEYSLOT, CLUSTER LINKS, CLUSTER MEET, CLUSTER MYID, CLUSTER MYSHARDID, CLUSTER NODES, CLUSTER REPLICAS, CLUSTER REPLICATE, CLUSTER RESET, CLUSTER SAVECONFIG, CLUSTER SET-CONFIG-EPOCH, CLUSTER SETSLOT, CLUSTER SHARDS, CLUSTER SLOT-STATS, CLUSTER SLOTS, READONLY, READWRITE.