apache/hadoop · error · IOException
Interrupted waiting for getJournalCTime() response
Error message
Interrupted waiting for getJournalCTime() response
What it means
The getJournalCTime() quorum wait was interrupted — InterruptedException occurred while blocking for JournalNode responses and was wrapped in this IOException. It is not a fault in the JNs themselves; the waiting thread was told to stop.
Source
Thrown at hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/qjournal/client/QuorumJournalManager.java:813
timeoutMs, "getJournalCTime");
if (call.countExceptions() > 0) {
call.rethrowException("Could not journal CTime for one "
+ "more JournalNodes");
}
// Either they all return the same thing or this call fails, so we can
// just return the first result.
try {
DFSUtil.assertAllResultsEqual(call.getResults().values());
} catch (AssertionError ae) {
throw new IOException("Results differed for getJournalCTime", ae);
}
for (Long result : call.getResults().values()) {
return result;
}
} catch (InterruptedException e) {
throw new IOException("Interrupted waiting for getJournalCTime() " +
"response");
} catch (TimeoutException e) {
throw new IOException("Timed out waiting for getJournalCTime() " +
"response");
}
throw new AssertionError("Unreachable code.");
}
}
View on GitHub (pinned to 2add963021)
Solutions
- Identify the interrupt source in adjacent log lines (shutdown, failover, operator action) and remove it.
- Restart the NameNode / re-run the upgrade procedure in a stable environment where nothing will interrupt it.
- If tooling-owned, raise the outer timeout instead of interrupting the thread performing the quorum wait.
- Confirm the NN comes up cleanly afterwards; an interrupted pre-upgrade check leaves no partial state, so a clean retry is safe.
Defensive patterns
Strategy: try-catch
Type guard
static boolean isCTimeInterrupted(IOException ioe) {
return ioe.getMessage() != null
&& ioe.getMessage().contains("Interrupted waiting for getJournalCTime");
} Try / catch
try {
long ct = qjm.getJournalCTime();
} catch (IOException ioe) {
if (isCTimeInterrupted(ioe)) {
Thread.currentThread().interrupt();
return OperationStatus.CANCELLED; // no partial state on the JNs
}
throw ioe;
} Prevention
- Keep NN startup/upgrade uninterruptible: fix systemd/send signal timing so SIGTERM does not land mid-check.
- A cancelled cTime check leaves no partial JN state — a clean restart of the procedure is safe.
When it happens
Trigger: Thread interrupt during getJournalCTime(): NameNode shutdown or HA state transition during the upgrade-startup check, operator cancellation of startup/upgrade, or calling code interrupting its worker.
Common situations: NN startup with '-upgrade' aborted mid-check; systemd/upstart sends SIGTERM while the NN is checking shared edits; upgrade automation interrupts the NN on an outer deadline.
Related errors
- Interrupted waiting for lockSharedStorage() response
- Results differed for getJournalCTime
- Timed out waiting for getJournalCTime() response
- Interrupted waiting for doPreUpgrade() response
- Timed out waiting for doPreUpgrade() response
AI-assisted analysis of apache/hadoop@2add963021 (2026-08-22).
Data as JSON: /api/errors/b5390262ff5600b2.
Report an issue: GitHub.