Troubleshooting
The engine logs one JSON object per line on stdout, with a level of debug, info, warn, error or critical. A crash is a critical line: panic carries the message and where it was raised, and engine_fatal says the engine stopped on a fault it cannot recover from. A startup failure is a single startup_failed line whose message is one of those below. In the Docker image the loader verifies a key given before the engine starts and reports its own failures the same way, as a loader_failed line: a key that does not verify carries the license messages below behind a license error: prefix. Request errors come back in the route’s JSON envelope with the status shown.
Startup
| Message | Cause and fix |
|---|---|
--api-key takes the key clients send (--api-key <KEY>), not ... |
--api-key without its key, so the word after it (a flag, a command or an address) would be the key. Put a key of your choosing after the flag, or drop it. |
--api-key takes a key of your own, not a license key: ... (or LAYERSCALE_API_KEY ...) |
Every client holds the API key, so it is never the license key. Choose another. |
more than one GPU needs a Pro license key (M requested; pass --tp 1) |
--tp above 1 without a Pro key, or a multi-GPU host with no --tp, which means every GPU. Pass --tp 1, or a Pro key. |
the Dynamo worker needs a Pro license key |
The Dynamo worker started without a Pro key. Pass a Pro key, or run layerscale serve. |
--num-speculative-tokens N: ... |
It sets the MTP head’s drafts: refused where nothing drafts with one, and outside 1 to 16. |
--speculative-draft-model-path: ... |
The block drafter runs on CUDA on one node, at any --tp its heads and width split, as the target’s do, under --speculative-algorithm mtp and without --num-speculative-tokens, beside a target that ships no MTP head; the draft checkpoint must be built for the target (the message names the mismatch: hidden size, vocabulary, a target layer past the model’s). |
license key must start with LSK- |
The value is not a LayerScale key. Check for a truncated or wrong variable. |
license key contains invalid characters, license key decodes to N bytes, expected 112 |
The key was mangled when copied. |
license key signature is invalid |
The key was not issued for this engine, or has been edited. |
license expired at unix ... |
Past the key’s expiry and its two-day grace. Renew at layerscale.ai/pricing. |
--model <DIR|ORG/NAME> is required; run --help for usage |
Every command needs --model. |
--model ORG/NAME: ORG/NAME is a gated model: ... no token is set ... |
The repo is gated. Accept its license on its Hugging Face page, create a read token at huggingface.co/settings/tokens and set HF_TOKEN (in Docker, -e HF_TOKEN=hf_...). |
--model ORG/NAME: ... is a gated model, and Hugging Face rejected the token in HF_TOKEN as invalid or expired ... |
The token is wrong or revoked. Create a new one. |
--model ORG/NAME: ... is a gated model, and the account that owns the token in HF_TOKEN has not been granted access to it ... |
Accept the license on the model’s page; a manually reviewed request can take a while. A fine-grained token also needs read access to public gated repos. |
--model ORG/NAME: no model ORG/NAME on Hugging Face ... |
The repo id is misspelled, or the repo is private and HF_TOKEN cannot read it. |
--model ORG/NAME: downloading from Hugging Face needs curl, which is not installed ... |
A build run outside the image on a host without curl. Install curl and ca-certificates, or pass a directory. |
--model ORG/NAME: could not resolve huggingface.co ..., could not reach huggingface.co ... |
No network. Download the model elsewhere and pass its directory, or mount a Hugging Face cache that has it. |
--model ORG/NAME: TLS with huggingface.co failed ... |
curl cannot verify the Hub’s certificate; install ca-certificates. |
--model ORG/NAME: could not write ... into the Hugging Face cache ... |
The disk is full or the cache directory is read-only. Point HF_HOME or HF_HUB_CACHE at a writable volume. |
--model ORG/NAME: not in the Hugging Face cache at ..., and HF_HUB_OFFLINE is set ... |
Downloads are off. Unset HF_HUB_OFFLINE or fetch the model first. |
unknown command '...'; run --help for usage |
A flag was mistyped and landed as the command, or the command was misspelled. |
config.json: architecture '...' is not implemented |
The model family is not supported. The message lists the families this build knows. |
layer N needs ..., which the GPU backend does not implement |
The checkpoint uses a layer feature outside the supported set: a chunked attention mask that is not a whole number of KV pages, a sliding window at a head_dim other than 64 or 128, a scaled routed expert, or routers that differ between layers. A latent-attention or Gated DeltaNet shape the kernels are not instantiated for is refused in the same words, without the layer N prefix. |
no tokenizer.json or tekken.json in ... |
The directory has no tokenizer. Check the download completed. |
model.safetensors.index.json: missing 'weight_map' |
The shard index is damaged; download the checkpoint again. |
config.json has no max_position_embeddings; pass --ctx |
The checkpoint does not state a context length. |
the KV pool is N tokens but the context is M (...); one full context must fit |
Not enough memory for one context after the weights. Raise --gpu-memory-utilization or --max-total-tokens, lower --ctx, use --kv-cache-dtype fp8, or add GPUs with --tp (a Pro license). The parenthesis says where the context length came from: --ctx or the model's default context. |
the KV pool cannot hold one sequence: --gpu-memory-utilization X allows ... a card, the card holds ... outside the pool ... |
Once warm, the engine measured what the card holds beside its KV pool (the weights, the engine’s buffers, any other process), and the rest of the allowed memory holds no context at all. Where it holds a shorter context than planned, the engine serves that one and logs ctx_clamped. Lower --max-num-seqs, or raise --gpu-memory-utilization. |
no accelerator: the CUDA runtime reports "..."; ... / no accelerator: the CUDA runtime sees no device; ... |
The GPU build found no device before loading anything. The line carries the runtime’s own words and the cause the probe points to: no driver visible (the container was started without --gpus), a host driver older than the image’s toolkit (CUDA 13.x needs a driver that reports 13.0 or newer, the R580 branch), or CUDA_VISIBLE_DEVICES hiding every device. --device auto runs on the CPU instead and logs device_fallback. |
this GPU is not supported yet: ... is consumer Blackwell. ... |
LayerScale supports datacenter Hopper, datacenter Blackwell and Vera Rubin cards; consumer Blackwell is refused before the license check, the download and the load. Use a supported card, or pass --device cpu. |
--tp N needs N GPUs, this host shows M |
More ranks were asked for than the process can see. Pass --tp M, or give the container more devices. |
--nnodes N needs --dist-init-addr <host:port>, where node 0 listens |
Above one node every node needs node 0’s address. Pass the same --dist-init-addr on every node. |
--dist-init-addr ADDR: not a host:port |
Give a name or an IP address, then a port: node0:29500, 10.0.0.1:29500, [fd00::1]:29500. |
--node-rank K is not below --nnodes N |
Node ranks run from 0 to N-1. |
--tp T does not split over --nnodes N into equal shares, --tp T over --nnodes N needs L GPUs a node, this host shows M |
Every node holds --tp / --nnodes ranks on its own GPUs. Pick a --tp that divides by the node count and fits each node. |
node K: node 0 at ADDR did not answer: ... |
That node could not reach node 0 for ten minutes: a wrong --dist-init-addr, node 0 not started, or the port blocked. In Docker, run with --network host. |
node K never said hello |
Node 0 waited 30 minutes for that node. Start it with the same command and its own --node-rank. |
node K was started with other options than node 0 (...) |
Start every node with the same command; only --node-rank changes. |
node 0 has no place for a node K in a world of N nodes: ... |
Two nodes were started with the same --node-rank. Give each node its own. |
--nnodes needs NCCL 2.32.6 or newer (libnccl.so.2) on the library path: ..., libnccl.so.2 is NCCL X; ... |
A server over several nodes loads NCCL. Install NCCL 2.32.6 or newer for CUDA 13 where the loader finds it. |
node K loaded NCCL X, node 0 Y: every node runs the same NCCL |
Run the same image, or the same NCCL, on every node. |
joining the world failed: ... |
NCCL could not connect the nodes’ ranks; its own message follows. Most often the nodes cannot reach each other on the interface NCCL picked: set NCCL_SOCKET_IFNAME to the right one on every node, and in Docker run with --network host. On an NVL72 rack, check that the IMEX service runs and the container has its channel. |
a collective across the nodes failed: ... |
A node or the network between the nodes was lost while serving. Restart every node. |
node K: ... |
Another node’s start failed; the rest of the line is that node’s own message. |
a device among the first N reports 0 bytes of memory |
A visible card answered the memory query with nothing; check it with the vendor’s smi tool. |
the n-gram embedding table needs N of pinned host memory (...) and this host has M available (MemAvailable); ... |
The run’s working set needs the table’s device memory for the KV pool, and the host has less free memory than the table plus a margin. Free host memory, or pin a pool that fits beside the table with --max-total-tokens. |
--gpu-memory-utilization X is not in (0, 1] |
The value must be a fraction above 0 and at most 1. |
this checkpoint's tokenizer has no ... token, so it was not trained on the ... chat template this engine renders for its architecture |
The checkpoint uses a template variant the engine does not render for this architecture. |
--kv-cache-dtype fp8 needs head_dim 128 or 256 and this model's is ..., --kv-cache-dtype fp8 the sliding-window attention kernels are built over a bf16 cache only, --kv-cache-dtype fp8 QSA's sparse attention reads an e4m3 cache at 12 query heads of 256 a key head alone, ... |
fp8 KV needs head_dim 128 or 256, a checkpoint with no sliding-window layers, and on a QSA model the release’s head shape. Use bfloat16, or auto. |
this checkpoint holds NVFP4 ..., which datacenter Blackwell alone serves; ..., this checkpoint holds MXFP4 ..., which datacenter Blackwell alone serves; ... |
NVFP4 and MXFP4 run on datacenter Blackwell only, and the engine does not convert them to bfloat16. On Hopper, serve the model’s FP8 or bfloat16 release. |
this checkpoint holds ... the kernels on ... do not read as stored: ... |
A quantized weight no kernel on the card reads as stored, such as int8 or a quantized vision tower; the message says why. The engine does not convert it to bfloat16. Use the model’s FP8 or bfloat16 release. |
--kv-cache-dtype nvfp4 needs datacenter Blackwell ... |
An NVFP4 KV cache is read through datacenter Blackwell’s 4-bit conversion; on other cards use fp8 or bfloat16. The fp8 shape rules apply to it as well, and latent attention (MLA) is refused. |
config.json quantization_config: quant_method '...' is not implemented |
An unsupported quantization format; see Models. |
--device cuda: this build is CPU-only (built with --no-default-features --features cpu) |
The binary was built without a GPU backend; the published images carry one. |
cannot bind ADDR: ... |
The port is taken or the address is not local. |
the warm-up failed: ... |
A request of the warm-up the engine runs before it binds failed, so a client’s would have: the rest of the line is that request’s error, as in the Requests table below. The process exits non-zero and the port never opens. |
GPU and container
| Symptom | Cause and fix |
|---|---|
no kernel image is available for execution on the device |
The GPU is older than Hopper. LayerScale supports datacenter Hopper, datacenter Blackwell and Vera Rubin cards. |
| The container exits at start with status 132 (an illegal instruction) | The host CPU is older than the image’s baseline: x86-64-v3 (AVX2, FMA and BMI2) on x86-64, Arm Neoverse V2 (NVIDIA Grace) on arm64. Run on a newer host. |
The container exits at once with no accelerator: ... |
The host driver is too old for the image’s CUDA 13.5 runtime (it needs the R580 branch, a driver reporting CUDA 13.0 or newer), or the container was started without --gpus. The line says which. |
| The port refuses connections after start | Expected: the engine binds after loading and warming up. Follow the logs for ready. |
/health answers 503 |
The engine thread stopped or stalled. Restart the container and check the last error or critical line in the log. After a fault the engine cannot recover from (an engine_fatal line, which names the cause) the process exits non-zero by itself, for a supervisor to restart. |
Requests
| Status and message | Meaning |
|---|---|
401 missing or invalid API key; send it as 'Authorization: Bearer <KEY>' |
The server was started with --api-key <KEY>: send that key as a bearer token or x-api-key. The license key is not one. |
400 This model's maximum context length is M tokens. However, your messages resulted in N tokens, leaving no room for the reply. (prompt is too long: N tokens > M maximum on /v1/messages, Your input exceeds the context window of this model (N tokens; the window is M). with code context_length_exceeded on /v1/responses, inside a response.failed event when streamed) |
The conversation no longer fits. Trim it, or restart with a larger --ctx. |
400 '...' is not supported |
A request parameter the engine refuses by name. The API reference lists what each route accepts. |
400 'max_tokens' is required |
/v1/messages requires it, as Anthropic’s API does. |
400 'stop' takes at most 4 sequences |
Send at most 4 stop strings of at most 64 bytes each. |
404 no such session '...' |
Sessions must be created with POST /v1/sessions first. |
409 session '...' has a request in flight |
One request per session at a time. Wait for it, or delete the session. |
409 session '...' already exists |
Pick another id, or delete the old session. |
408 request took too long to arrive |
The full request did not arrive within 60 seconds, a wait for room to read its body included. |
413 body too large |
Bodies are limited to 1088 MiB, enough for the largest picture a request may carry. |
413 ... past the N MiB this host holds for requests in flight |
One body, with the JSON values it parses into, is larger than a quarter of the host’s memory. Past that bound in total, the next body waits to be read; requests without a body never wait. |
503 ... have no room for this body now; retry |
The memory the host holds for requests in flight filled up while this request was arriving. Send it again. |
500 engine stopped |
The engine thread has died. /health answers 503 too; restart. |
500 backend error: ... the engine must restart |
A GPU lost its CUDA context (the message names the CUDA error, such as cudaErrorIllegalAddress), or at --tp above 1 a GPU never arrived at a step and the others’ wait for it ran out (ten seconds). The requests in flight get this error, the log carries engine_fatal, and the process exits non-zero by itself; the supervisor’s restart is the recovery. |
500 backend error: the engine stopped on a fault it cannot recover from |
The request arrived while the engine was stopping on such a fault. Retry once the process is back. |
A streaming response that fails after it has started carries the error as its last data: frame (an error event on /v1/messages; an error event, then response.failed, on /v1/responses), because the status line is already 200.
Output quality
- A request that names no sampling gets the checkpoint’s
generation_config.json(temperature,top_p,top_k), andtemperature1.0,top_p1.0 and notop_kwhere that file sets none. Send"temperature": 0for greedy output. - Speculative decoding (a checkpoint’s MTP head where it ships one, prompt lookup elsewhere) is not bit-exact against a plain decode. Start with
--speculative-algorithm nonewhen comparing outputs across runs or engines. - A tool call the model wrote but the engine could not parse is returned as plain content when the reply is not streamed. Streamed, a call whose name already went out ends as that call with
{}arguments, and one that never named a function is dropped, so the content ends where the call began. Thetool_call_unparseablelog line and thelayerscale_tool_calls_malformed_totalmetric show when this happens. - A reply cut off at
max_tokenshasfinish_reason: "length"; raise it.
Performance figures for supported models and GPUs are at layerscale.ai/benchmarks.