apache/hadoop · error · InterruptedIOException

Interrupted receiveBlock

Error message

Interrupted receiveBlock

What it means

Error "Interrupted receiveBlock" thrown in apache/hadoop.

Source

Thrown at hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/BlockReceiver.java:1111

        try {
          responder.interrupt();
          // join() on the responder should timeout a bit earlier than the
          // configured deadline. Otherwise, the join() on this thread will
          // likely timeout as well.
          long joinTimeout = datanode.getDnConf().getXceiverStopTimeout();
          joinTimeout = joinTimeout > 1  ? joinTimeout*8/10 : joinTimeout;
          responder.join(joinTimeout);
          if (responder.isAlive()) {
            String msg = "Join on responder thread " + responder
                + " timed out";
            LOG.warn(msg + "\n" + StringUtils.getStackTrace(responder));
            throw new IOException(msg);
          }
        } catch (InterruptedException e) {
          responder.interrupt();
          // do not throw if shutting down for restart.
          if (!datanode.isRestarting()) {
            throw new InterruptedIOException("Interrupted receiveBlock");
          }
        }
        responder = null;
      }
    }
  }

  /**
   * If we have downstream DNs and peerMetrics are enabled, then initialize
   * some state for monitoring the performance of downstream DNs.
   *
   * @param downstreams downstream DNs, or null if there are none.
   */
  private void initPerfMonitoring(DatanodeInfo[] downstreams) {
    if (downstreams != null && downstreams.length > 0) {
      downstreamDNs = downstreams;
      isPenultimateNode = (downstreams.length == 1);
      if (isPenultimateNode && datanode.getDnConf().peerStatsEnabled) {

View on GitHub (pinned to 2add963021)

Solutions

  1. Treat as normal if it coincides with DataNode shutdown, block invalidation, or pipeline recovery; no action needed.
  2. If frequent without shutdown/recovery, check what issues interrupts (e.g., premature client disconnects) and review thread management around the receiver.

When it happens

Trigger: The BlockReceiver thread is interrupted while receiving a block, commonly during DataNode shutdown or aborted pipeline operations.

Common situations: The receiveBlock thread was interrupted, typically by DataNode shutdown or pipeline recovery. Harmless during planned restarts; otherwise check for premature interrupts.


AI-assisted analysis of apache/hadoop@2add963021 (2026-08-22). Data as JSON: /api/errors/b2ee3b35b3321da0. Report an issue: GitHub.