{"record":{"id":"78ea86e1c0aa9b9d","repo":"astrid-runtime/astrid","slug":"kernel-lease-metadata-does-not-match-the-fuse-prov","errorCode":null,"errorMessage":"kernel lease metadata does not match the FUSE provider registry","messagePattern":"kernel lease metadata does not match the FUSE provider registry","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"crates/astrid-storage-provider-fuse/src/main.rs","lineNumber":420,"sourceCode":"        mount_id: record.mount_id,\n        mountpoint: record.mountpoint,\n        access: record.access,\n        dirty: lease_status.dirty,\n    })\n}\n\nasync fn unmount(\n    client: &mut AdminClient,\n    acting_principal: &astrid_core::PrincipalId,\n    selector: &StorageMountSelectorV1,\n) -> Result<StorageProviderSuccessV1> {\n    let record = registry::resolve_record(selector)?;\n    if &record.requested_by != acting_principal {\n        bail!(\"mount was issued to another acting principal\");\n    }\n    let live = if let Some(status) = kernel_lease_status(client, &record.mount_id).await? {\n        if status.mountpoint != record.mountpoint || status.access != record.access {\n            bail!(\"kernel lease metadata does not match the FUSE provider registry\");\n        }\n        true\n    } else {\n        cleanup_stale_record(client, acting_principal, &record).await?;\n        false\n    };\n    if live {\n        let control_result = control_unmount(&record.control_path, acting_principal);\n        if let Err(error) = control_result {\n            eprintln!(\n                \"falling back to stale FUSE cleanup after control unmount failure: {error:#}\"\n            );\n            cleanup_stale_record(client, acting_principal, &record).await?;\n        } else {\n            into_success(\n                client\n                    .request(AdminRequestKind::StorageMountRevoke {\n                        mount_id: record.mount_id,","sourceCodeStart":402,"sourceCodeEnd":438,"githubUrl":"https://github.com/astrid-runtime/astrid/blob/affd8760f44190dbdfbec23403f4c4b642c33112/crates/astrid-storage-provider-fuse/src/main.rs#L402-L438","documentation":"Consistency check during FUSE unmount: the kernel lease metadata for the mount id disagrees with the provider's local registry record (different mount identity or state), so the unmount cannot safely proceed against a mismatched lease.","triggerScenarios":"Thrown at crates/astrid-storage-provider-fuse/src/main.rs:420 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Re-list mounts to get the current registry state and retry with the correct selector","Clean up the stale registry record if the kernel lease has already been released","Investigate how registry and kernel lease diverged (crash between create steps)"],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"affd8760f44190dbdfbec23403f4c4b642c33112","analyzedAt":"2026-09-09T21:28:12.402Z","contentChangedAt":"2026-09-09T21:28:12.402Z","schemaVersion":2},"datasetVersion":"2026-09-17T15:17:12.973Z"}