Kafka警告:No checkpointed highwatermark is found for partition
測試環境使用的Kafka出現了點兒問題,伺服器被停止,所有的topic日誌不知怎的被清空。一番大清洗(清理zookeeper節點、kafka topic log)、重啟Kafka、建立分割槽後發現報瞭如下的錯誤:
[2018-10-24 19:34:31,834] WARN Partition [test_topic_xxx,30] on broker 3: No checkpointed highwatermark is found for partition [test_topic_xxx,30] (kafka.cluster.Partition) [2018-10-24 19:34:31,839] WARN Partition [test_topic_xxx,27] on broker 3: No checkpointed highwatermark is found for partition [test_topic_xxx,27] (kafka.cluster.Partition) [2018-10-24 19:34:31,843] WARN Partition [test_topic_xxx,24] on broker 3: No checkpointed highwatermark is found for partition [test_topic_xxx,24] (kafka.cluster.Partition) [2018-10-24 19:34:31,846] WARN Partition [test_topic_xxx,21] on broker 3: No checkpointed highwatermark is found for partition [test_topic_xxx,21] (kafka.cluster.Partition) [2018-10-24 19:34:31,850] WARN Partition [test_topic_xxx,18] on broker 3: No checkpointed highwatermark is found for partition [test_topic_xxx,18] (kafka.cluster.Partition) [2018-10-24 19:34:31,854] WARN Partition [test_topic_xxx,15] on broker 3: No checkpointed highwatermark is found for partition [test_topic_xxx,15] (kafka.cluster.Partition) [2018-10-24 19:34:31,857] WARN Partition [test_topic_xxx,12] on broker 3: No checkpointed highwatermark is found for partition [test_topic_xxx,12] (kafka.cluster.Partition) [2018-10-24 19:34:31,860] WARN Partition [test_topic_xxx,9] on broker 3: No checkpointed highwatermark is found for partition [test_topic_xxx,9] (kafka.cluster.Partition) [2018-10-24 19:34:31,863] WARN Partition [test_topic_xxx,6] on broker 3: No checkpointed highwatermark is found for partition [test_topic_xxx,6] (kafka.cluster.Partition) [2018-10-24 19:34:31,866] WARN Partition [test_topic_xxx,3] on broker 3: No checkpointed highwatermark is found for partition [test_topic_xxx,3] (kafka.cluster.Partition) [2018-10-24 19:34:31,870] WARN Partition [test_topic_xxx,0] on broker 3: No checkpointed highwatermark is found for partition [test_topic_xxx,0] (kafka.cluster.Partition) [2018-10-24 19:34:31,873] WARN Partition [test_topic_xxx,10] on broker 3: No checkpointed highwatermark is found for partition [test_topic_xxx,10] (kafka.cluster.Partition)
ofollow,noindex">找了些資料 知道了報警的原因。
日誌中提到的high watermark指的是一個partition中上一次提交的訊息的offset。報警是因為topic剛建立、消費已開始、但是還沒有生產者推送訊息過來、對應topic沒有任何offset的記錄導致的。
所以該警告可以忽略,待有訊息推送過來即可。
相關資料
Intra-cluster Replication in Apache Kafka
#####