apache/cassandra · warning

Could not fetch log entries from peer, remote =

Error message

Could not fetch log entries from peer, remote = {}, await = {}

What it means

PeerLogFetcher.fetchLogEntriesAndWait logs this warning when a synchronous fetch of log entries from a peer fails via ExecutionException or TimeoutException. The exception itself is only logged at debug level; the method returns the last-known metadata rather than the awaited epoch.

Solutions

  1. Verify the remote peer is up and reachable (ping/nodetool status).
  2. Check the debug-level log line 'Exception while fetching log entries from peer' for the real cause.
  3. Increase RPC/request timeouts if log gaps are large.
  4. Retry the fetch; if persistent, remove or repair the dead peer.
Defensive patterns

Strategy: retry

Validate before calling

if (!FailureDetector.instance.isAlive(remote)) throw new IllegalStateException("peer " + remote + " not alive; skip fetch");

Try / catch

try { return fetchLogEntriesAndWait(remote, epoch); } catch (RuntimeException e) { logger.warn("retrying fetch from another peer"); return fetchFromOtherPeer(epoch); }

Prevention

When it happens

Trigger: Calling fetchLogEntriesAndWait(remote, awaitAtleast) when the remote peer is unreachable, slow, or times out before responding with log entries up to the awaited epoch.

Common situations: Peer restarting or overloaded during topology changes; network partitions; remote node decommissioned but still referenced; RPC timeouts set too low for large log gaps.

Understand the failure class

Background: Request timed out: what client-side request timeouts mean across libraries (Request timed out, TIMED_OUT, APITimeoutError) — this error's family across 39 libraries.

Related errors


AI-assisted analysis of apache/cassandra@88fd0f6a0e (2026-09-10). Data as JSON: /api/errors/b35f5595206f35a8. Report an issue: GitHub.

Appendix: source

Thrown at src/java/org/apache/cassandra/tcm/PeerLogFetcher.java:71

     * fetch log entries from the given remote, we have already seen a message from this replica with epoch awaitAtleast.
     */
    public ClusterMetadata fetchLogEntriesAndWait(InetAddressAndPort remote, Epoch awaitAtleast)
    {
        ClusterMetadata metadata = ClusterMetadata.current();
        if (metadata.epoch.isEqualOrAfter(awaitAtleast))
            return metadata;

        try
        {
            return asyncFetchLog(remote, awaitAtleast).get(DatabaseDescriptor.getRpcTimeout(TimeUnit.MILLISECONDS), TimeUnit.MILLISECONDS);
        }
        catch (InterruptedException e)
        {
            throw new RuntimeException("Can not fetch log entries during shutdown", e);
        }
        catch (ExecutionException | TimeoutException e)
        {
            logger.warn("Could not fetch log entries from peer, remote = {}, await = {}", remote, awaitAtleast);
            logger.debug("Exception while fetching log entries from peer, remote = {}", remote, e);
        }
        return metadata;
    }

    public Future<ClusterMetadata> asyncFetchLog(InetAddressAndPort remote, Epoch awaitAtleast)
    {
        return EpochAwareDebounce.instance.getAsync(() -> fetchLogEntriesAndWaitInternal(remote, awaitAtleast), awaitAtleast);
    }

    private Future<ClusterMetadata> fetchLogEntriesAndWaitInternal(InetAddressAndPort remote, Epoch awaitAtleast)
    {
        Epoch before = ClusterMetadata.current().epoch;
        if (before.isEqualOrAfter(awaitAtleast))
        {
            Promise<ClusterMetadata> res = new AsyncPromise<>();
            res.setSuccess(ClusterMetadata.current());
            return res;

View on GitHub (pinned to 88fd0f6a0e)