diff --git a/src/cluster.c b/src/cluster.c index f2c08690985a592ae0991e49a88abbc119441a58..d1d839cbae5cc47d97207d457b45e53e3a9f1352 100644 --- a/src/cluster.c +++ b/src/cluster.c @@ -1363,8 +1363,9 @@ void clusterProcessGossipSection(clusterMsg *hdr, clusterLink *link) { clusterNodeFailureReportsCount(node) == 0) { uint32_t pongtime = ntohl(g->pong_received); - if (pongtime > node->pong_received) + if (pongtime > node->pong_received) { node->pong_received = pongtime; + } } /* If we already know this node, but it is not reachable, and diff --git a/utils/create-cluster/create-cluster b/utils/create-cluster/create-cluster index 98941496fe72d87b462dd28ee8fdbaa907eaf701..d821683f62051f761e9e1bafec1e7e19a4735e55 100755 --- a/utils/create-cluster/create-cluster +++ b/utils/create-cluster/create-cluster @@ -86,6 +86,12 @@ then exit 0 fi +if [ "$1" == "clean-logs" ] +then + rm -rf *.log + exit 0 +fi + echo "Usage: $0 [start|create|stop|watch|tail|clean]" echo "start -- Launch Redis Cluster instances." echo "create -- Create a cluster using redis-trib create." @@ -93,3 +99,4 @@ echo "stop -- Stop Redis Cluster instances." echo "watch -- Show CLUSTER NODES output (first 30 lines) of first node." echo "tail -- Run tail -f of instance at base port + ID." echo "clean -- Remove all instances data, logs, configs." +echo "clean-logs -- Remove just instances logs."