Skip to content

[Bug]: LogService gossip bind-collision regression fails on macOS #32392

Closed

Description

@slyunnn

Is there an existing issue for the same bug?

  • I have checked the existing issues.

Branch Name

main

Commit ID

c99234dcf4c94d1ff9d372917cd35041f1a3a682

Other Environment Information

macOS arm64, Apple M2 Pro, Go 1.27.1, GOEXPERIMENT=simd. Clean detached source and matching native dependencies rebuilt with the repository Makefile. This was found during QA for #32135 and #32134.

Actual Behavior

TestGossipFixtureStartupRealBindCollision fails in both normal and race owning-package runs, and independently in an isolated normal run. The assertion at pkg/logservice/gossip_fixture_test.go:610 expects another fixture startup attempt after the injected collision, but observes attempts == injectedAttempt == 1.

Error: "1" is not greater than "1"
--- FAIL: TestGossipFixtureStartupRealBindCollision (31.01s)
FAIL github.com/matrixorigin/matrixone/pkg/logservice

The isolated command completed with exit code 1 in approximately 32 seconds. The owning normal and race runs also failed at this same assertion. The six targeted heartbeat/bootstrap regression tests for #32134/#32135 separately passed in normal and race modes.

Expected Behavior

The real bind-collision fixture should deterministically exercise its intended collision, recover through the retry path and pass on supported macOS. A platform-specific difference in the injection needs an explicit, verified explanation before changing its assertions.

Steps to Reproduce

Use clean main at the commit above, matching native artifacts and Go 1.27.1.

GOEXPERIMENT=simd .agents/skills/mo-dev/scripts/mo-cgo-test \
  -v -count=1 -timeout=90s \
  -run '^TestGossipFixtureStartupRealBindCollision$' ./pkg/logservice

The same failure was observed with the full ./pkg/logservice package in normal and -race modes. No assertion was weakened and no source was modified.

Additional information

This report tracks an observed test-fixture failure. The assertion alone does not establish a LogService production bind-retry defect or a recurrence of #32134/#32135. The precise socket/platform cause remains to be diagnosed. Exact-name and gossip-fixture issue searches found no matching report at filing time.

Activity

  1. added
    kind/bug
    on Nov 9, 2026
  2. added theissue type on Nov 9, 2026
  3. added this to the MO-202611 milestone on Nov 9, 2026
  4. added a commit that references this issue on Nov 12, 2026
    4760bca
  5. XuPeng-SH commented on Nov 12, 2026

    @XuPeng-SH
    Contributor

    转 QA 验证:修复已随 #32574 合入 main,merge SHA 4760bcaa88b23fabe064b1631b624c0e8c40d549(PR head 071380402a525fd6696823a735ccca4537cc63ea)。本 issue 是可重复的平台测试夹具失败,非据偶发 CI 失败直接关闭。

    修复使真实 gossip bind collision 注入使用与 memberlist 相同的通配 TCP 地址族,并核对碰撞确来自预期 gossip TCP 主机和端口。PR 作者报告:macOS/arm64 Go 1.27.1 旧用例 normal/race 均失败,候选均通过且记录精确端口 EADDRINUSE、回滚及成功重试;真实 Raft 端口碰撞会被新来源/端口断言拒绝。Linux 最终 targeted normal/race 通过,owning package normal 在最后断言增强前通过。

    以上是 PR 中的验证记录,本轮仅核查远端合并状态、issue 及完整评论,没有在最终 merge SHA 新跑测试。请 QA 在 macOS/arm64 和 Linux 验证原根用例 normal/race、真实 gossip 占用与 Raft 端口负对照、回滚/重试和资源释放;保留原断言,不把本次交接视为验收通过。此前无当前适用反例或未完成开发 follow-up,交给 Ariznawlll,issue 保持开放。

  6. slyunnn commented on Nov 13, 2026

    @slyunnn
    Author

    Regression and extended verification for #32392 (2026-11-13)

    Verification Environment

    Target: main@b6f5f597b8923b0f6d762e3b18243f39e49c5840, ci: allow reviewed 4.2 PRs from the designated approver to queue (#32656). Original-platform runs used macOS arm64, Go 1.27.1, GOEXPERIMENT=simd and matching native libraries. No service/test assertions were edited.

    This is a native test-fixture regression. The fixture creates its own LogService cohorts and sockets. CN/TN/Proxy SQL endpoints are not its entry point; the same session's 2 CN / 1 TN / 1 Log service / Proxy deployment (6001/16001/16002) served #32444, and its SQL checks are not used as proof for this issue.

    What Was Covered

    • OK — Original TestGossipFixtureStartupRealBindCollision in normal and race modes on macOS; real wildcard gossip TCP collision occurred on attempt 1, and startup recovered on attempt 2.
    • OK — Exact gossip TCP host/port and bind error asserted, successful rollback/reopen of the previously started node, fresh cohort identities, stale-runtime removal and final service cleanup. The retry assertion was preserved.
    • OK — Real LogService RPC-port collision control plus constructor panic/Goexit, cancellation, configuration and allocation failures: 12 selected test roots passed in each mode, without skips.
    • OK — The separate existing TestNewTestServiceRetriesRaftPortCollisionWithStableIdentity also passed normal/race with a real Raft-port collision. This validates its stable-identity retry/cleanup control; it is not relabeled as gossip-port classification.
    • OK — Linux/amd64 evidence reused from the final repair-head UT job, attempt 1, head 071380402a525fd6696823a735ccca4537cc63ea. The job log, normal coverage artifact and race package selection were inspected. The normal artifact contains 4,177 logservice coverage blocks (3,308 executed); the race job includes logservice and completed successfully.
    • Not covered — A new Linux run at b6f5f597b8 or an independently extracted per-case Linux PASS transcript. Linux evidence is reused from CI, not represented as a fresh local execution. Production LogService bind-retry behavior and the separate [Bug]: HAKeeper shuts down healthy LogService voters after heartbeat client sticks to isolated address #32134/[Bug]: LogService bootstrap briefly resurrects a removed initial HAKeeper replica #32135 incidents are not reclassified by this fixture result.

    Findings

    Associated repair: PR #32574, Fix native preparation and stabilize CI tests, merge 4760bcaa88b23fabe064b1631b624c0e8c40d549. The injection now uses the same wildcard TCP address-family selection as memberlist and verifies that the collision is from the intended gossip listener.

    For CI reuse, pkg/logservice, go.mod, go.sum, Makefile, cgo and thirdparties were compared between the exact CI head and the tested main: no differences. Linux evidence validity is based on those unchanged test/native/module inputs plus inspected execution evidence, not merely a green overall gate. Current macOS normal/race runs directly reproduce and validate the previously failing platform path.

    Large-data regression required: No. The boundary is TCP address-family collision injection and resource lifecycle, exercised by real bounded socket/service cohorts; row volume is unrelated.

    MOTR / BVT Coverage

    Reused the existing native regression and negative controls. A SQL MOTR case cannot directly exercise this socket-family fixture boundary, so no duplicate MOTR commit or PR was created. Native normal/race runs were separately executed with test-owned resources; no SQL scheduling concurrency is substituted for them.

    Final Conclusion

    Fixed for the reported macOS gossip bind-collision test-fixture failure, with current-platform normal/race proof and qualifying Linux CI reuse as described. This is not a broader production fault-tolerance claim.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

kind/bugneeds-triage

Type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions