Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

[Bug]

未关闭
#2,098 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 3 天内回复

@yjhjstz 已经在做这个了。

开始于 2026年10月8日。

  • #2099 来自 @yjhjstz —— 未关闭

评估

难度
4/5
预计耗时
3-5 天
新手友好度
15/100
Issue 类型
缺陷
描述清晰度
基本清楚
活跃度
停滞
技术栈
c, postgresql, sql
领域
databases

调研方向

Start by reproducing with the SQL in the report: create a table, run gpcheckcat on the database, then create the materialized view and run it again. The failing check is inconsistent_pg_class, which reports relmvrefcount as 1 on the coordinator (content -1) and 0 on the segments. Done means gpcheckcat is clean after the materialized view is created. Pull request #2099 is already open against this issue, so review it before starting new work.

由索引模型根据 Issue 内容生成。

描述

type: Bug
Apache Cloudberry version

Apache Cloudberry 2.1.0-incubating build bdf90c5518f

What happened

gpcheckcat is reporting issues on a database with materialized views

Relation oid: 7016964
Relation schema: XXXX
Relation name: XXXXXX

Name of test which found this issue: inconsistent_pg_class
   relmvrefcount is '1' on content -1 (XXXXXX:5432)
   relmvrefcount is '0' on all other segments

Gpcheckcat is showing no errors before creation of materialized view

After a materialized view is created and run the gpcheckcat is reporting inconsistencies in pg_class

Seems like relmvrefcount is not being updated on the segments

What you think should happen instead

Either relmvrefcount is updated correctly or gpcheckcat should ignore this test. We have multiple CB clusters with multiple databases. And our daily online catalog check is failing on any database with MV

How to reproduce

CREATE TABLE public.test_table (
col1 int,
col2 int
)
DISTRIBUTED randomly;
run gpcheckcat This shows no error

CREATE MATERIALIZED VIEW public.test_table_mv
WITH (appendonly = true, blocksize='32768', compresslevel='3', compresstype=zstd, checksum='true') AS
SELECT * from public.test_table;

run gpcheckcat

Relation oid: 7018655
Relation schema: public
Relation name: test_table

Name of test which found this issue: inconsistent_pg_class
   relmvrefcount is '1' on content -1 (XXXXXX:5432)
   relmvrefcount is '0' on all other segments
Operating System

NAME="Red Hat Enterprise Linux" VERSION="9.7 (Plow)"

Anything else

Every time. We can reproduce this at will

Are you willing to submit PR?
  • Yes, I am willing to submit a PR!
Code of Conduct
主要语言
C
星标
1.4k
派生
260
平均合并
4 天 5 小时
30 天内合并 PR
51

环境准备

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

apache/cloudberry 的其他 Issue

查看 apache/cloudberry 的全部 Issue

相似的 Issue

更多 C Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。