diff --git a/cluster.go b/cluster.go index 754b37e8..70196e8c 100644 --- a/cluster.go +++ b/cluster.go @@ -429,15 +429,17 @@ func (c *Cluster) ready(timeout time.Duration) { timer := time.NewTimer(timeout) select { case <-timer.C: - logger.Error("**************************************************") - logger.Error("***** ipfs-cluster consensus start timed out *****") - logger.Error("This peer was not able to become part of the cluster.") - logger.Error("This might be due to one or several causes:") - logger.Error(` - Check that there is connectivity to the "bootstrap" and "peers" multiaddresses`) - logger.Error(` - Check that all cluster peers are using the same "secret"`) - logger.Error(` - Check that this peer is reachable on its "listen_multiaddress"`) - logger.Error(` - Check that there is a majority of available peers`) - logger.Error("**************************************************") + logger.Error("***** ipfs-cluster consensus start timed out (tips below) *****") + logger.Error(` +************************************************** +This peer was not able to become part of the cluster. +This might be due to one or several causes: + - Check that there is connectivity to the "bootstrap" and "peers" multiaddresses + - Check that all cluster peers are using the same "secret" + - Check that this peer is reachable on its "listen_multiaddress" + - Check that there is a majority of available peers +************************************************** +`) c.Shutdown() return case <-c.consensus.Ready(): diff --git a/consensus/raft/logging.go b/consensus/raft/logging.go index 154bc5d8..33440b62 100644 --- a/consensus/raft/logging.go +++ b/consensus/raft/logging.go @@ -63,8 +63,8 @@ func (fw *logForwarder) repeated(t int, msg string) bool { fw.lastTip = make(map[int]time.Time) } - // We we haven't tipped about repeated log messages - // in while, do it and forget the list + // We haven't tipped about repeated log messages + // in a while, do it and forget the list if time.Now().After(fw.lastTip[t].Add(repeatReset)) { fw.lastTip[t] = time.Now() fw.lastMsgs[t] = nil