agentleFS
apacheapache/doris-skills/skills/doris-debug/data-lake/SKILL.md

doris-debug-data-lake

Skill50 starsChanged 13 days agoApache-2.0View on GitHub

Use for Doris external catalog issues: Hive/Iceberg/Paimon/Hudi query failures, metadata refresh, filesystem S3/HDFS connectivity, external MV rewrite misses.

The file

We split this skill into the rules it gives an agent

1 rule. About 0 are common, 0 are distinctive, and 1 is very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈0

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    If refresh is slow, check HMSClient cache settings (fe.conf):

    line 59

≈ “Common” is an estimate: at least 1 in 5 of the 372,429 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Data Lake (Multi-Catalog)

Causes

IDCauseEvidenceSource anchor
AMetadata staleQuery returns old data / missing partitions after upstream writeHMSClient.java, CachedHMSClient.java
BS3/HDFS connectivityAccess Denied, Timeout, NoSuchBucketS3FileSystem.java, HdfsResource.java
CExternal MV rewrite missEXPLAIN shows no MATERIALIZED_REWRITEMTMVService.java rewrite rules
DSchema mismatchParquet/ORC schema ≠ Hive Metastore schemaParquetReader.cpp, schema merge
ECredential / IAM expirySTS / IAM token rotated; 403 on S3S3FileSystem.java credential refresh
FToo many open filesFD exhaustion listing large table directoriesBE ulimit -n, FileSystem.listFiles()

10 min triage

-- Verify catalog is alive
SHOW CATALOGS;

-- Refresh metadata (hive / iceberg / paimon)
REFRESH CATALOG hive_catalog;
REFRESH DATABASE hive_catalog.db_name;
REFRESH TABLE hive_catalog.db_name.tbl_name;

-- Check if external MV rewrite is enabled
SET materialized_view_rewrite_enable_contain_external_table = true;

-- Analyze external table for CBO stats
ANALYZE TABLE hive_catalog.db_name.tbl_name;
# BE logs for S3/HDFS errors
./scripts/doris-debug log-grep be/log --query-id "$QID"
grep -r "403\|Access Denied\|Timeout\|NoSuchBucket\|Token.*expired" be/log/

# Check BE file descriptor limit
cat /proc/$BE_PID/limits | grep "open files"

Cause A — Metadata staleness

Hive Metastore metadata is cached; REFRESH CATALOG invalidates the cache. For large catalogs, prefer:

-- Refresh only the changed partition
REFRESH TABLE catalog.db.tbl PARTITION (dt='2026-07-15');

If refresh is slow, check HMSClient cache settings (fe.conf):

hive_metastore_client_timeout_second = 10

Cause B — S3/HDFS connectivity

# be.conf — S3 credential chain
aws_access_key_id = ...
aws_secret_access_key = ...
aws_region = us-east-1
# Test S3 reachability from BE host
curl -I "https://<bucket>.s3.<region>.amazonaws.com"
# fe.conf for HDFS catalog
hadoop_conf_dir = /path/to/hadoop/conf  # must contain core-site.xml + hdfs-site.xml

Cause E — Credential rotation

For STS/AssumeRole-based S3 access, the cached credential may expire:

-- Force credential refresh (Doris 2.1+ / 3.0)
REFRESH CATALOG hive_catalog;

For long-running queries against external tables, ensure credential TTL > query timeout.

Source

  • fe/.../datasource/hive/HMSExternalCatalog.java
  • fe/.../datasource/hive/HMSClient.java
  • be/src/io/fs/s3/S3FileSystem.cpp — S3 connector
  • be/src/io/fs/hdfs/HdfsFileSystem.cpp — HDFS connector
  • be/src/vec/exec/format/parquet/vparquet_reader.cpp — parquet reader
  • fe/.../mtmv/MTMVService.java — external MV rewrite

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.