Back to all use cases
Cross-IndustryRemediationOn-Premises

Every small file costs NameNode heap, and heap is the cluster's hard limit

GL
Global Logistics Operator

Overview

HDFS keeps the entire namespace in NameNode memory, so file count — not data volume — is what constrains the cluster. When small-file sprawl pushes heap toward its ceiling, GC pauses lengthen until clients begin timing out and failover flaps. AceMQ stabilizes the NameNode and eliminates the sources producing the files.

Challenge

Ingest jobs writing one file per micro-batch, over-partitioned Hive tables, and years of uncompacted landing zones produce tens of millions of objects that individually hold very little data. Heap climbs, full GC pauses grow into the tens of seconds, the standby NameNode's health check fails, and automatic failover triggers during a pause that was not actually a failure. Restarts become risky because loading the fsimage and replaying edits takes progressively longer.

Environment

On-premises HDFS clusters with HA NameNodes, JournalNodes, and mixed Hive, Spark, and ingest workloads.

Approach

AceMQ profiles the namespace to find where the file count is concentrated, then buys headroom immediately through heap and GC tuning and failover timing adjustments so the cluster stops flapping. Compaction runs against the worst directories under controlled load, and the producing jobs are corrected so the file count stops climbing. Where sprawl is structural, archival and format changes are applied.

Solution

  • Namespace profiling from fsimage analysis to rank directories by file count against bytes stored
  • NameNode heap sizing and GC configuration tuned to reduce full-collection pause duration
  • Failover and health-check timing adjusted so long GC pauses stop triggering unnecessary standby promotion
  • Staged compaction of the highest-file-count directories under controlled load, including Hive table concatenation
  • Correction of producing jobs — batch interval, output partition count, and partition column choice
  • HAR archival or format migration for cold datasets that must be retained but not queried directly

Outcome

GC pauses return to a range where failover no longer triggers spuriously, and NameNode restart time comes back under control. Because the producing jobs are fixed in the same engagement, the namespace stops growing back toward the ceiling.

Technologies

Apache HadoopApache HiveApache SparkYARN

Ready to Get Started?

Whether you need architecture advisory, 24/7 support, or full managed services, AceMQ has the expertise to help.

Contact Us