Skip to content

Hive partition JOIN queries intermittently fail with dispatch timeout (dispatch process not registered within 30s) #25211

Closed

Description

@Ariznawlll

Summary

External hive partition JOIN queries intermittently fail with dispatch process not registered within 30s, remote CN may have failed. The same two JOIN SQLs fail every time the issue occurs, while other queries in the same test file succeed.

This is a recurring flaky failure — it does not reproduce every run.

Affected SQL

-- Query 1: fact JOIN dim
select d.part_name, count(*) as rowcount
from external_hive_partition_2000_large.fact_hive_2000 f
join external_hive_partition_2000_large.dim_part_2000 d
on f.part_id = d.part_id
where d.part_id in (1, 7, 2000)
group by d.part_name order by d.part_name

-- Query 2: fact self-JOIN
select a.part_id, count(*) as rowcount
from external_hive_partition_2000_large.fact_hive_2000 a
join external_hive_partition_2000_large.fact_hive_2000 b
on a.part_id = b.part_id and a.col_uuid = b.col_uuid
where a.part_id in (1, 7)
group by a.part_id order by a.part_id

Error

ERROR 20101 (HY000): internal error: dispatch process not registered within 30s, remote CN may have failed

Recent Occurrences

Run Date Job Branch
28338073448 2026-06-29 Query 1Y / 16 Hive Partition main
28133872754 2026-06-25 BIG DATA TEST main

Previous Tracking

Loki Evidence (from 2026-06-25 occurrence)

CN logs showed:

  • objectio/cache.go:354: dedup load did not complete on all 3 CNs
  • compile/remoterunServer.go:545: dispatch process not registered within 30s
  • GC forced on one CN
  • CN-to-CN (port 6002) connections broken
  • cannot get salt / i/o timeout on all CNs

Environment

  • Cluster: TKE, 3 CNs + 1 DN
  • CN memory limit: 55 GiB
  • cn_gomemlimit: 25000 MiB
  • Test file: cases/big_data_test/04_QUERIES/29_external_hive_partition_agg_join.sql

Expected Behavior

JOIN queries on external hive partition tables should complete without dispatch timeout, even under concurrent S3 read pressure.

Activity

  1. added
    kind/bug
    severity/s0
    on Jun 29, 2026
  2. added theissue type on Jun 29, 2026
  3. added this to the MO-202606 milestone on Jun 29, 2026
  4. jiangxinmeng1 commented on Jul 2, 2026

    @jiangxinmeng1
    Contributor

    fixed by #25238

  5. Ariznawlll commented on Jul 3, 2026

    @Ariznawlll
    CollaboratorAuthor

    没出现了

  6. 22 remaining items

  7. Ariznawlll commented on Jul 16, 2026

    @Ariznawlll
    CollaboratorAuthor

    Latest main recurrence after #25682

    The Hive partition JOIN path failed again in the latest 1Y big-data regression:

    Git ancestry confirms that the tested MatrixOne commit already contains #25682 (17c9953d7d8e94421082e2e28c8f29ed643f1f3e), so this is not a stale run missing the per-CN colexec.Server isolation fix.

    First effective failure

    The first six statements in 29_external_hive_partition_agg_join.sql completed. The first statement that stopped making progress was the same fact/dimension JOIN tracked by this issue:

    select d.part_name, count(*) as rowcount
    from external_hive_partition_2000_large.fact_hive_2000 f
    join external_hive_partition_2000_large.dim_part_2000 d
      on f.part_id = d.part_id
    where d.part_id in (1, 7, 2000)
    group by d.part_name
    order by d.part_name;

    It started at 2026-07-16 01:51:12 +08:00 and reached the client-side 1800-second timeout at 02:21:12.

    Cascading timeouts

    After that timeout, the self-JOIN, a two-branch partition-count UNION ALL, and the final aggregate/order query each also consumed the full 1800-second timeout.

    These later three timeouts should not yet be treated as independent MO failures. The regression runner implements the limit with func_timeout(...), then continues with the same PyMySQL cursor/conn without killing the server-side query or reconnecting. The original query may therefore remain active, or the connection may no longer be safe to reuse, causing a cascade.

    Assessment

    The previous occurrence in run 29211194235 / job 86704634878 returned the explicit error:

    internal error: dispatch process not registered within 30s, remote CN may have failed
    

    for the same fact/dimension JOIN. The latest runner log only exposes the outer 1800-second timeout, so it proves that the same query path still hangs after #25682, but it does not by itself prove that the internal cause is again receiver registration. CN logs/query profiles are needed to distinguish a remaining dispatch hang from a new partition-pruning or JOIN performance regression.

    Suggested next checks:

    1. Re-run only HIVE_AGG_07_JOIN_DIM_TABLE and collect all CN logs and query profile.
    2. Check receiver UUID registration/attachment and remote pipeline conversion records.
    3. Verify whether d.part_id in (1, 7, 2000) is propagated to the fact-side external scan and whether Hive partition pruning is effective.
    4. On client timeout, cancel the server query and recreate the SQL connection before running another statement, so one failure cannot hide subsequent results.
  8. Ariznawlll commented on Jul 17, 2026

    @Ariznawlll
    CollaboratorAuthor

    由25816跟踪,这个先关闭

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

Metadata

Metadata

Assignees

Labels

kind/bugseverity/s0

Type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions