Compute API error reference
This page documents common error responses from the Compute API (Nova v2.1), explains what they mean operationally, and provides next-step actions. Use this reference when your API call returns an unexpected status code or when an instance enters an error state.
HTTP status codes#
| Status | Meaning | Typical cause | Retryable? | Next action |
|---|---|---|---|---|
| 400 Bad Request | The request body is malformed or missing required fields | Invalid JSON, missing name or flavorRef in server create | No | Check request syntax against the Compute API reference |
| 401 Unauthorized | Authentication failed | Token missing, expired, malformed, or revoked. The 401 body is identical for all four cases. | No | Re-issue your token: openstack token issue |
| 403 Forbidden | Authorization failed | Quota exceeded, action not permitted for your role | No | Check quota: openstack quota show --usage. See quota troubleshooting |
| 404 Not Found | The resource does not exist | Wrong instance ID, instance already deleted | No | Verify the resource ID: openstack server list |
| 409 Conflict | The action conflicts with the resource's current state | Instance in wrong state for the requested action (e.g., reboot while in BUILD) | Conditional | Check instance status; wait for state transition, then retry |
| 413 Over Limit | Quota exceeded | Resource quota reached (instances, cores, RAM) | No | Check quota: openstack quota show --usage. Free resources or request increase |
| 429 Too Many Requests | API rate limit exceeded | Too many requests in a short time window (enforced at the gateway layer) | Yes | Wait and retry with exponential backoff. Check for a Retry-After header |
| 500 Internal Server Error | Server-side failure | Platform-side issue | Yes | Retry after a brief delay. If persistent, escalate to support |
| 503 Service Unavailable | Service temporarily overloaded | Maintenance or capacity issue | Yes | Retry with exponential backoff |
Nova returns the same 401 body whether the token is missing, expired, malformed, or revoked, so the response does not tell you which case you hit. If openstack token issue succeeds and the request still returns 401, the most common remaining cause is a stale environment variable that points to a different project's token.
Example error response#
{
"forbidden": {
"code": 403,
"message": "Quota exceeded for resources: ['instances']. Requested 1, but already used 10 of 10 instances"
}
}The Compute API (Nova) returns errors as JSON envelopes, as shown above. Not every Quake AI service does: the Image service (Glance) returns error bodies as HTML. Branch on the HTTP status code rather than parsing the response body. For the Glance status codes, see Image API error responses. For the Instance API action endpoints and their async state transitions, see Instance API response codes.
Server fault interpretation#
When an instance enters the ERROR state, the fault field in the server response contains diagnostic information.
Reading the fault object#
The fault field is not a recognized column for openstack server show, so -c fault fails with No recognized column names in ['fault']. Read the field from JSON output instead:
openstack server show YOUR_INSTANCE -f json | jq .faultNova populates fault only when the server is in ERROR status. On ACTIVE, SHUTOFF, and other states the field is null, which is expected. The raw Compute API returns the same data: GET /v2.1/servers/{server_id} includes a top-level fault object when the status is ERROR.
The fault object includes:
message: description of the failurecode: HTTP status code associated with the failurecreated: timestamp when the fault occurred
Common fault messages#
| Fault message | Meaning | Resolution |
|---|---|---|
| "No valid host was found" | The scheduler cannot place the instance on any compute host | Try a smaller flavor. Check quota. If all flavors fail, file a support ticket; capacity may be constrained. |
| "Build of instance aborted: Volume did not finish being created" | The boot volume (Block Storage) timed out during creation | Check for orphaned volumes (openstack volume list). Delete and retry with image-based boot. |
| "Exceeded maximum number of retries" | The scheduler retried placement and failed after retrying | Likely a capacity issue. Wait and retry, or try a different flavor. |
| "PortBindingFailed" | The Networking service (Neutron) cannot bind the instance's port | Verify your network exists and is accessible: openstack network list. Recreate the instance on a working network. |
| "Build of instance aborted: block_device_mapping is not valid" | The block device configuration is invalid | Check your volume or image reference. Verify the specified image or volume exists and is accessible. |
State-conflict handling#
Instance lifecycle actions are only valid in certain states. Sending an action to an instance in the wrong state returns HTTP 409 Conflict.
| Action | Required state | Common conflict scenario |
|---|---|---|
reboot | ACTIVE, SHUTOFF, ERROR | Instance in BUILD; wait for build to complete |
start | SHUTOFF | Instance already ACTIVE |
stop | ACTIVE | Instance already SHUTOFF or in BUILD |
resize | ACTIVE, SHUTOFF | Instance in VERIFY_RESIZE (must confirm or revert first) |
delete | Any (except DELETED) | Instance in DELETING; already being deleted |
rebuild | ACTIVE, SHUTOFF, ERROR | Instance in BUILD; wait for build to complete |
Handling 409 responses#
- Check current instance status:
openstack server show YOUR_INSTANCE -c status -c task_state-
Wait for the current operation to complete. The
task_statefield shows what the instance is doing (e.g.,spawning,rebooting,resize_migrating). -
Once
task_stateisNoneand the instance is in a valid state for your action, retry.
Key pair errors#
Key pair operations return specific errors that are commonly misdiagnosed, especially during instance creation.
| Error | HTTP status | Cause | Resolution |
|---|---|---|---|
| "Invalid key_name provided." | 400 | Instance create references a key pair name that does not exist in the project, or the name is malformed (invalid characters or too long) | List available key pairs: openstack keypair list. Create or import the key pair before launching, and confirm the name uses only alphanumeric characters, dashes, and underscores. |
| "Key pair with key pair name already exists" | 409 | Creating a key pair with a name that is already in use | Choose a different name, or delete the existing key pair first if it is no longer needed. |
| "Invalid key_type" | 400 | Unsupported key type specified during creation | Use ssh (default) or x509. |
| "Keypair data is invalid" | 400 | Imported public key is malformed or uses an unsupported format | Verify the public key file format. Regenerate with ssh-keygen -t ed25519 if needed. |
For SSH connectivity failures after the instance is running (timeouts, permission denied, wrong username), see the instance connectivity runbook.
Quota-related errors#
When the Compute API returns 403 Forbidden with a quota message, the request was valid but your project lacks capacity.
Quota exceeded for resources: ['instances'] (HTTP 403)
Quota exceeded for resources: ['cores', 'ram'] (HTTP 403)Resolution:
- Check quota usage:
openstack quota show --usage - Identify the exhausted resource
- Clean up unused instances or request a quota increase
Quake AI-specific quota names#
openstack quota show --usage lists quota names beyond the upstream Nova and Cinder catalog. The Compute API returns 403 Forbidden against these limits the same way it does for the standard quotas.
| Quota | Scope | Notes |
|---|---|---|
compute_units | Compute | Quake AI capacity metric gated separately from cores and ram. Each flavor carries a per-instance compute_units cost, so you can exhaust compute_units while cores and ram still have headroom. |
volumes_Flash_Premium | Block Storage | Volume count for the Flash_Premium volume type. Other volume types follow the same volumes_<type> pattern. |
gigabytes_Flash_Premium | Block Storage | Capacity in GB for the Flash_Premium volume type. |
snapshots_Flash_Premium | Block Storage | Snapshot count for the Flash_Premium volume type. |
A limit of -1 means unlimited. Read these values with openstack quota show --usage; the GET /v2.1/limits endpoint does not expose the Quake AI-specific quota names.
See the quota and limits troubleshooting page for detailed recovery procedures.
When to escalate#
Escalate to support when:
- An instance is stuck in ERROR state and the fault message does not point to a quota, capacity, or configuration issue you can resolve
- A 500 or 503 error persists after multiple retries with backoff over 5 minutes
- The
faultobject, read withopenstack server show YOUR_INSTANCE -f json | jq .fault, describes a failure you cannot interpret - Instance behavior contradicts the documented state machine (e.g., an ACTIVE instance that accepts no actions)
Escalation-ready evidence checklist#
When a Compute API error is not self-resolvable, collect this evidence before filing a support ticket:
| Item | Command |
|---|---|
| Instance ID, status, fault | openstack server show YOUR_INSTANCE -f json | jq '{id, status, fault}' |
| Console log (last 50 lines) | openstack console log show YOUR_INSTANCE --lines 50 |
| Request details | Note the exact API call, parameters, and timestamp |
| Quota usage | openstack quota show --usage |
| Token validity | openstack token issue (confirms auth is working) |
See also#
- Compute API reference
- Error response format: JSON error structure, fault objects, request correlation
- API rate limits: quotas vs. rate limits,
/limitsendpoint, 429 handling - Retry and resilience patterns: backoff, jitter, and which errors to retry
- Instance lifecycle troubleshooting
- Instance connectivity troubleshooting
- Quota and limits troubleshooting