Identify runtime and target
Java defines common interfaces, but virtual-machine diagnosis depends on implementation and version. Record vendor, version, PID, process identity, and permissions before collecting evidence. An OpenJ9 javacore and a HotSpot heap dump are not interchangeable formats. On a host with two Java applications, listing order does not identify production; confirm the process through execution context. Choose a supported procedure bounded to the correct target. This module uses HotSpot JDK 25 and OpenJ9 documentation without claiming equivalence with every WebSphere installation.
Reserved, committed, and resident memory
Xmx describes the configured heap maximum rather than all application memory. In NMT, distinguish reserved from committed and compare categories across a window with known workload. The resident set observed by the operating system has a different scope. In an example, RSS grows while NMT categories change little: investigate memory outside coverage and accounting differences. Do not turn the discrepancy into an automatic leak diagnosis. A baseline supports future comparisons; tracking enablement and cost should belong to a planned change rather than an improvised assumption.
Container limits and JVM symptoms
The process needs headroom for resources outside heap, and metric collection may miss a peak between samples. If the container ends with OOMKilled, correlate events, limit, and total usage; do not require a Java OutOfMemoryError before accepting external termination. In an exercise, raising heap from 2 to 3.8 GiB within a 4 GiB limit reduces remaining headroom. In another, reduced CPU quota increases throttling and latency while memory stays stable. Investigate each limit through its corresponding signal before changing pools or collectors without evidence.
Threads, owners, and progress
A thread waiting for a lock does not prove deadlock. In an OpenJ9 javacore, relate state and monitor to the owner and stack, using comparable samples to observe progress. If ownership changes and work advances, severe contention may exist without permanent immobility. If the owner remains in an external call, investigate that dependency and critical-section holding time. With twenty blocked workers, adding workers does not bypass the same monitor. Explain the observed mechanism and the conclusion’s limit before selecting mitigation with the responsible owner.
GC within the timeline
Garbage collection is part of normal execution. To attribute slowness to GC, compare pause duration and frequency with affected requests over the same interval, considering collector and configuration. If pause time is small while requests mostly wait for I/O, the dominant hypothesis may concern the dependency. Avoid choosing a new collector merely because GC messages occur during the incident. In an exercise, build a timeline of requests, pauses, and waiting, then describe which observation supports or contradicts each hypothesis. Average CPU alone does not answer that question.
Capture without worsening the failure
Choose a capture addressing the hypothesis within duration, volume, and impact limits. JFR can retain relevant time-based events, but the selected profile has a cost; heap dumps can also affect service and occupy substantial space. For an intermittent I/O failure, targeted temporal data may be more useful than repeated heap dumps. Confirm protected destination, space, retention, and artifact access. Record the window and instrumentation changes. The package should support later analysis without leaving permanent collection or a full filesystem after the incident ends.
A 4 GiB container restarts after Xmx rises to 3.8 GiB. Heap does not represent all process memory; correlate the limit with usage and events before increasing it again.
Common pitfalls
HotSpot and OpenJ9 as identical tools; reserved as occupied RAM; waiting as deadlock; unbounded dumps.
Related topics: Investigate the JVM, heap, and pauses · Connect threads, pools, and dependencies · Operate TLS, certificates, and configuration
Connect the diagnostic question to the tool, runtime, and actual resource limits.
Reference: Native Memory Tracking · DR Middleware 2026.4; HotSpot JDK 25; JDBC 25; PostgreSQL 18; RabbitMQ 4.3; OpenSSL 3.5; explicitly scoped runtime references