dosubot[bot] commented on issue #3007: URL: https://github.com/apache/hugegraph/issues/3007#issuecomment-4306172490
<!-- Answer --> 感谢确认这是一个全新集群。既然不是旧版本数据升级的问题,那这很可能是 hstore 后端在集群初始化阶段的一个 bug 或时序问题。 根据代码分析,有几个可能的原因: **1. Store 节点未完全就绪时 Server 就开始查询数据** `ServerInfoManager` 在启动时会立即尝试读写 `server-1` 系统顶点。如果 hstore 的分区分配还未完成,写入可能产生不完整/损坏的数据,后续读取就会出现 varint 解析错误。HugeGraph 存在已知的分区分配超时问题 [[1]](https://github.com/apache/hugegraph/issues/2999)。 **2. 节点间时钟不同步** `ServerInfoManager` 对时钟偏差有严格要求(>30秒会抛异常)[[2]](https://github.com/apache/hugegraph/blob/9126c80e414c073b60fc074361b211cfb409e0eb/hugegraph-server/hugegraph-core/src/main/java/org/apache/hugegraph/task/ServerInfoManager.java#L110-L114),时钟偏差也可能导致初始化异常。 **建议排查步骤:** 1. **确保正确的启动顺序并等待就绪**:先启动所有 PD 节点 → 等 PD leader 选举完成 → 启动所有 Store 节点 → **等 Store 日志确认分区分配完成** → 最后再启动 Server 节点 2. **检查三个节点的时钟同步**: ```bash # 在三个节点上分别执行,确认时间差在几秒以内 date # 确保 NTP/chrony 服务正常运行 systemctl status chronyd ``` 3. **清理数据后重试**:停止所有服务,清空 hstore 数据目录(`pd_data` 以及 Store 的数据目录),然后按上述顺序重新启动 4. **确认所有组件版本一致**:PD、Store、Server 三个组件必须来自同一个 master commit 编译 5. **验证是否为 hstore 特有问题**:如果方便,可以临时改用 RocksDB 后端(单节点模式)测试,如果 RocksDB 正常启动,则可以确认是 hstore 后端的序列化 bug 另外,日志中的 Jersey 错误 `"Error occurred when processing a response created from an already mapped exception"` 是 Raft leader 选举期间的正常瞬态现象 [[3]](https://github.com/apache/incubator-hugegraph/issues/2787),与序列化错误无关,可以忽略。 如果清理数据并严格按顺序启动后仍然复现,这很可能是 hstore 后端在 1.7.0 master 分支中的序列化 bug——hstore 集成层存在一些已知的[不完整之处](https://github.com/apache/hugegraph/blob/9126c80e414c073b60fc074361b211cfb409e0eb/hugegraph-server/hugegraph-core/src/main/java/org/apache/hugegraph/backend/serializer/BinarySerializer.java#L442)。建议在这个 issue 中补充 PD 和 Store 的启动日志,以便进一步定位。 <!-- Dosu Comment Footer --> *To reply, just mention [@dosu](https://go.dosu.dev/dosubot?utm_source=github&utm_medium=bot-comment&utm_campaign=github-comment-footer-20260415&utm_content=reply-with-mention&utm_term=apache%2Fhugegraph).* --- Docs are dead. Just use [Dosu](https://dosu.dev?utm_source=github&utm_medium=bot-comment&utm_campaign=github-comment-footer-20260415&utm_content=static-docs-tagline&utm_term=apache%2Fhugegraph). [](https://app.dosu.dev/response-feedback?utm_source=github&utm_medium=bot-comment&utm_campaign=github-comment-footer-20260415&utm_content=static-docs-feedback&utm_term=apache%2Fhugegraph#message_id=41ed3588-5f5b-44ba-8ab5-871c1f1f3451) [](https://github.dosu.com/apache/hugegraph?utm_source=github&utm_medium=bot-comment&utm_campaign=github-comment-footer-20260415&utm_content=static-docs-ask-repo&utm_term=apache%2Fhugegraph) [](https://app.dosu.dev/signup?referrer=openSource&source=github-footer&utm_source=github&utm_medium=bot-comment&utm_campaign=github-comment-footer-20260415&utm_content=static-docs-share-team&utm_term=apache%2Fhugegraph) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
