spacedriveapp/spacedrive · warning

Cannot access path: {}

Error message

Cannot access path: {}

What it means

With no volume backend configured, the handler falls back to tokio::fs::try_exists(path) and that OS-level check failed. The path's existence simply cannot be determined: a parent directory denies search permission, a path component is unreadable, or the filesystem is in a transient bad state. The handler warn-logs (noting the volume may be offline) and returns the error.

Source

Thrown at core/src/ops/indexing/change_detection/handler.rs:108

			Err(e) => {
				tracing::warn!(
					"Volume error when checking path existence for {}: {}",
					path.display(),
					e
				);
				Err(e.into())
			}
		}
	} else {
		match tokio::fs::try_exists(path).await {
			Ok(exists) => Ok(exists),
			Err(e) => {
				tracing::warn!(
					"Cannot verify path existence for {} (volume may be offline): {}",
					path.display(),
					e
				);
				Err(anyhow::anyhow!("Cannot access path: {}", e))
			}
		}
	}
}

/// Evaluates indexing rules to determine if a path should be skipped.
pub async fn should_filter_path(
	path: &Path,
	rule_toggles: RuleToggles,
	location_root: &Path,
	backend: Option<&Arc<dyn crate::volume::VolumeBackend>>,
) -> Result<bool> {
	let ruler = build_default_ruler(rule_toggles, location_root, path).await;

	let metadata = if let Some(backend) = backend {
		backend
			.metadata(path)
			.await

View on GitHub (pinned to 6dfeccf211)

Solutions

  1. Check the daemon user's permissions on the path and every parent directory
  2. Verify the mount hosting the path is present and healthy
  3. Retry after the environment settles - races with unmount are transient
  4. If systemic, exclude the affected tree from indexing via rules
Defensive patterns

Strategy: fallback

Try / catch

match tokio::fs::try_exists(path).await {
    Ok(exists) => Ok(exists),
    Err(e) if e.kind() == std::io::ErrorKind::PermissionDenied => {
        // Existence unknowable: defer the event rather than classify it as created or deleted.
        defer_event(path);
        Ok(false)
    }
    Err(e) => Err(anyhow::anyhow!("Cannot access path: {}", e)),
}

Prevention

When it happens

Trigger: Permission denied on the path or a parent directory for the daemon user; NFS stale handles; the path sits on a mount that vanished without a clean unmount; unusual filesystem errors during concurrent modification.

Common situations: Restrictive permissions after user changes, daemon running as a user without access to external mounts, races between indexing and unmount.

Related errors


AI-assisted analysis of spacedriveapp/spacedrive@6dfeccf211 (2026-08-16). Data as JSON: /api/errors/f14b447c33fab11b. Report an issue: GitHub.