TiFlash v8.5.8: SIGSEGV in Block::cloneEmptyColumns while flushing a ColumnFileInMemory
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 45/100
調査の方向性
Start with dbms/src/Core/Block.cpp around line 373 and trace how Block slots are created or mutated before ColumnFileInMemory::readDataForFlush calls cloneEmptyColumns(). Instrument the slot’s column and type pointers along that path to find where both become unset. Done means identifying the creation or mutation path that produces the invalid slot; the issue provides no standalone reproducer or named test.
索引モデルが issue の本文から書いたものです。
説明
TiFlash crashed while flushing a Region on a production cluster. The application signal log reported a read from a null address. The service manager restarted TiFlash after the crash.
Environment: TiFlash v8.5.8, engine Git hash 3abdec8bff315647a056e6bf910abd4b59af2011, Linux x86-64.
Crash stack (caller → callee, selected frames):
TiFlashObserver::pre_exec_admin
→ TryFlushData
→ KVStore::tryFlushRegionData
→ KVStore::forceFlushRegionDataImpl
→ Segment::flushCache
→ DeltaValueSpace::flush
→ MemTableSet::buildFlushTask
→ ColumnFileInMemory::readDataForFlush
→ Block::cloneEmptyColumns() const
Evidence from the faulting thread: The application stack and core identify the same instruction offset, tiflash+0x782ea24. GDB resolved it to Block::cloneEmptyColumns() const+244, at dbms/src/Core/Block.cpp:373. The relevant source expression is:
columns[i] = data[i].column ? data[i].column->cloneEmpty() : data[i].type->createColumn();
In the disassembly, the null check on column took the fallback branch. That branch loaded type into %rsi. At the faulting instruction, mov (%rsi),%rax, %rsi was zero. The loop index was 8. This indicates that both pointers read from this in-memory Block slot were null. The crash occurred before the virtual call to createColumn().
Diagnostic limits: The core was truncated. GDB warned of a possible executable mismatch, and the TiFlash executable had no build ID. The faulting instruction offset agrees with the application stack, but the core did not retain enough accessible memory to inspect the slot independently or recover the Region ID. We do not know how the Block reached this state.
Reproduction: Observed in production. We do not have a standalone reproducer.
Is there a known issue in this version that can leave a ColumnFileInMemory Block slot with both column and type unset? Which creation or mutation path would you instrument to identify when the slot first enters this state?
- 主要言語
- C++
- スター
- 1k
- フォーク
- 428
- 平均マージ
- 2日 7時間
- マージ済み PR(30日)
- 100
環境構築
このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドなし
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
pingcap/tiflash のほかの issue
-
component/compute type/bug
難易度 2/5 1〜2日 初心者へのやさしさ 82/100
メンテナーはふだん 1 日以内に返信
-
Out-of-bounds read in MyDateTime formatting from unvalidated packed values対応中かも @ChangRui-Ryan が今日担当しました。 オープンaffects-25.10 affects-26.3 affects-26.9 affects-7.5 affects-8.1 affects-8.5 severity/major type/bug
難易度 4/5 3〜5日 初心者へのやさしさ 30/100
メンテナーはふだん 1 日以内に返信
-
component/storage severity/moderate type/bug
難易度 4/5 3〜5日 初心者へのやさしさ 48/100
pingcap/tiflash#11335 · コメント 5 件 ·
メンテナーはふだん 1 日以内に返信
-
Missing validation in JSON constructors, LEFT expressions, and CH-block decoding対応中かも @windtalker が今日担当しました。 オープンtype/bug
難易度 4/5 3〜5日 初心者へのやさしさ 25/100
メンテナーはふだん 1 日以内に返信
-
[disagg] Query fails with Code: 11000 NoSuchKey when S3 GC (ScanThenDelete) removes a DMFile that a compute node still reads対応中かも @JinheLin が 6 日前に担当しました。 オープンmay-affects-25.10 may-affects-26.3 may-affects-26.9 may-affects-7.5 may-affects-8.1 may-affects-8.5 severity/moderate type/bug
pingcap/tiflash#11291 · コメント 1 件 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
pingcap/tiflash の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信
-
useless statementオープン
難易度 1/5 1時間未満 初心者へのやさしさ 86/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
-
難易度 2/5 1〜3時間 初心者へのやさしさ 65/100
grizzlypeak3d/DJV#962 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
メンテナーはふだん 1 日以内に返信