influxdata/influxdb · error · TableIndexCacheError

Failed to list table indices from object store

Error message

Failed to list table indices from object store

What it means

TableIndexCacheError::ListIndices wraps an object_store::Error raised when listing table index objects from the object store fails. The cache lists all table index paths under the node's prefix (e.g. during purge_db or update_all_from_object_store) and this variant signals that listing itself failed, independent of any per-path parsing.

Solutions

  1. Inspect the wrapped object_store::Error; for permission failures, grant ListBucket/ListBlob permissions on the index prefix.
  2. Verify the node identifier prefix and bucket configuration are correct and the prefix exists (or is expected to be empty).
  3. For throttling on large prefixes, reduce listing concurrency or enable/raise retries with backoff.
  4. Retry the operation (purge_db / initialize) once the object store is reachable again.

Example fix

// before: IAM policy without list permission
{ "Effect": "Allow", "Action": ["s3:GetObject", "s3:PutObject"], "Resource": "arn:aws:s3:::my-bucket/*" }
// after: add list permission on the bucket
{ "Effect": "Allow", "Action": ["s3:GetObject", "s3:PutObject", "s3:ListBucket"], "Resource": ["arn:aws:s3:::my-bucket/*", "arn:aws:s3:::my-bucket"] }
Defensive patterns

Strategy: retry

Validate before calling

// verify list permission before operations that scan the index prefix
object_store.list(Some(&indices_prefix)).try_next().await?; // surfaces list errors early

Type guard

fn is_list_indices_err(e: &TableIndexCacheError) -> Option<&object_store::Error> {
    match e { TableIndexCacheError::ListIndices(oe) => Some(oe), _ => None }
}

Try / catch

match stream.map_err(TableIndexCacheError::ListIndices).try_collect::<Vec<_>>().await {
    Err(TableIndexCacheError::ListIndices(e)) if retryable(e) => backoff_and_relist().await,
    other => other?,
}

Prevention

When it happens

Trigger: object_store.list(Some(&prefix)) stream errors while collecting table index paths in purge_db (table_index_cache.rs:770) or update_all_from_object_store (table_index_cache.rs:1188); note the list call itself returns Err lazily from the stream.

Common situations: S3 ListObjects permission missing (s3:ListBucket), throttling on list APIs during large-prefix scans, network failures mid-pagination, or a mistyped node identifier prefix pointing at a non-listable location.

Understand the failure class

Background: "API error: {status}" and "HTTP 401/403/404/429/5xx" errors: non-2xx HTTP responses explained — this error's family across 27 libraries.

Related errors


AI-assisted analysis of influxdata/influxdb@06200ef96b (2026-09-19). Data as JSON: /api/errors/b615e33f9a1001bf. Report an issue: GitHub.

Appendix: source

Thrown at influxdb3_write/src/table_index_cache.rs:63

    #[error("JSON serialization/deserialization failed")]
    Json(#[source] serde_json::Error),

    #[error("TableIndex operation failed")]
    TableIndex(#[source] crate::table_index::TableIndexError),

    #[error("Object meta is missing filename")]
    MissingFilename,

    #[error("Failed to parse snapshot sequence number from filename")]
    InvalidSnapshotSequenceNumber,

    #[error("Unexpected error")]
    Unexpected(#[source] anyhow::Error),

    #[error("Table snapshot persistence task failed")]
    TableSnapshotPersistenceTaskFailed(#[source] tokio::task::JoinError),

    #[error("Failed to list table indices from object store")]
    ListIndices(#[source] object_store::Error),

    #[error("Failed to parse table index path from object store path")]
    TableIndexPath(#[source] crate::paths::PathError),

    #[error("Failed to list table index snapshots from object store")]
    ListSnapshots(#[source] object_store::Error),

    #[error("Failed to parse table index snapshot path from object store path")]
    TableIndexSnapshotPath(#[source] crate::paths::PathError),

    #[error("Failed to update table index: join task failed")]
    UpdateTaskFailed(#[source] tokio::task::JoinError),

    #[error("Failed to list object store metadata")]
    ListMetasError(#[source] object_store::Error),

    #[error("Failed to load table index conversion marker bytes from object store")]

View on GitHub (pinned to 06200ef96b)