All error codes

server_busy

HTTP 409 Server state does not allow this operation

What happened

Another operation on this server is already running or is being submitted at this moment - a create, a reinstall, a backup, a restore from a backup (while it runs, none of the server's backups can be deleted either), a disk or plan change, a network card being added, changed or removed (a deletion of the server waits for it too; the detail names the card task), or a second request of your own. Once a deletion of a server has been accepted, a second DELETE of it is the exception: it is not refused but joins the running deletion (202 with its task); only a DELETE that arrives while the first one is still being submitted gets this code. The same code answers concurrent operations on one network, including attaching or detaching its router, and creating a server or attaching a network interface in a network whose deletion is already queued (the detail names the network and the deletion task; once that task finishes the network is gone and the repeat answers network_not_found). It also answers when another request of the same project is choosing or ordering a public address at this moment - creating a server with public_ipv4, POST /v1/ips, or moving a network interface to a public network with reuse: these are queued one at a time per project. The request itself is valid; the resource is occupied. Two states answer with the same code but do not pass by waiting, and their response carries no Retry-After: a GPU Pro server that holds a detached volume refuses to be deleted or reinstalled (the volume would be erased, and volumes are managed only in the client area), and a server in an error state refuses the operations it cannot run in that state until it is reinstalled.

What to do

When the response carries Retry-After, wait for the running task to finish, honouring Retry-After, then repeat the same request with the same idempotency key. Without Retry-After, waiting does not help: read detail, which names the state to change first - attach or delete the detached volume in the client area, or reinstall the server that is in an error state - and only then repeat the request. A server in an error state whose image no longer exists (your own server image that was deleted) cannot be reinstalled either - the reinstall answers rebuild_image_unavailable - and the only way out is to delete it. This is not a failure on our side - that arrives as 503; here the state is what blocks you.

Retrying

Change the state this refers to, then repeat the same request with the same idempotency key.

How it arrives

{
    "type": "https://docs.fiberax.com/errors/server_busy",
    "title": "Server state does not allow this operation",
    "status": 409,
    "code": "server_busy",
    "request_id": "a277dcd1ca652c65"
}

Branch your code on code, never on the wording of title.