astrid-runtime/astrid · error
FUSE service launch exceeds limit
Error message
FUSE service launch exceeds limit
What it means
The FUSE service reads its launch configuration (JSON) from stdin, capping input at MAX_LAUNCH_BYTES by reading exactly one byte more. If the input exceeds the cap, run bails before attempting to decode, protecting the process from oversized or hostile launch payloads.
Source
Thrown at crates/astrid-storage-provider-fuse/src/service.rs:38
use crate::control::{KernelControlRequest, KernelControlResponse, bind_control_listener};
use crate::filesystem::{self, FuseBackgroundSession};
use crate::mountpoint;
const MAX_LAUNCH_BYTES: u64 = 64 * 1024;
const MAX_CONTROL_BYTES: usize = 64 * 1024;
const MAX_CALLBACK_BYTES: usize = 8 * 1024 * 1024;
const SERVICE_POLL: Duration = Duration::from_secs(1);
/// Run the hidden target-free service mode.
pub(crate) async fn run() -> Result<()> {
let mut bytes = Vec::new();
std::io::stdin()
.lock()
.take(MAX_LAUNCH_BYTES + 1)
.read_to_end(&mut bytes)
.context("read target-free FUSE service launch")?;
if bytes.len() as u64 > MAX_LAUNCH_BYTES {
bail!("FUSE service launch exceeds limit");
}
let launch: StorageProviderServiceLaunchV1 =
serde_json::from_slice(&bytes).context("decode target-free FUSE service launch")?;
run_launch(launch).await
}
async fn run_launch(launch: StorageProviderServiceLaunchV1) -> Result<()> {
if launch.schema != STORAGE_FILESYSTEM_SERVICE_LAUNCH_SCHEMA_V1 {
bail!("unsupported FUSE service launch schema {}", launch.schema);
}
validate_launch(&launch)?;
let challenge = storage_provider_service_ready_challenge(
&launch.parent.token,
STORAGE_FILESYSTEM_SERVICE_READY_SCHEMA_V1,
crate::PROVIDER_NAME,
launch.lease.mount_id.as_uuid(),
&launch.control_path,
&launch.lease.resource_path,View on GitHub (pinned to affd8760f4)
Solutions
- Reduce the size of the launch payload (trim tokens, options, or embedded data)
- Inspect what the parent process writes to stdin and fix the pipeline
- Check MAX_LAUNCH_BYTES in service.rs and whether the payload legitimately needs a larger limit (code change)
- Ensure only a single StorageProviderServiceLaunchV1 document is piped
Example fix
// before cat large-launch-and-logs.json | fuse-service // after cat launch.json | fuse-service # single JSON doc within MAX_LAUNCH_BYTES
Defensive patterns
Strategy: validation
Validate before calling
fn launch_fits_limit(json: &str, max_bytes: u64) -> bool {
(json.len() as u64) <= max_bytes
} Try / catch
match service::run().await {
Err(e) if e.to_string().contains("launch exceeds limit") => {
eprintln!("launch payload too large; trim config or raise MAX_LAUNCH_BYTES");
}
other => other?,
} Prevention
- Keep launch payloads small; avoid embedding large tokens or blobs
- Pipe exactly one launch JSON document to stdin
- Verify what the supervisor writes to the child's stdin
- If payloads legitimately grew, raise MAX_LAUNCH_BYTES in a code change
When it happens
Trigger: Piping a launch JSON document larger than MAX_LAUNCH_BYTES into the service's stdin; a parent process accidentally feeding a log or binary blob instead of the launch config.
Common situations: Misconfigured supervisor piping the wrong file to stdin; an embedding tool serializing an unexpectedly huge token or config; concatenating multiple launch documents.
Understand the failure class
Background: payload too large / request exceeds maximum size: why libraries cap bytes and how to fix oversize payloads — this error's family across 50 libraries.
Related errors
- provider request exceeds limit
- opaque capsule assets cannot be symlinks: {}
- FSKit service control request exceeds limit
- FUSE control request exceeds the bounded frame size
- FUSE service control response exceeds the bounded frame size
AI-assisted analysis of astrid-runtime/astrid@affd8760f4 (2026-09-09).
Data as JSON: /api/errors/c04ed37afd9ba3c7.
Report an issue: GitHub.