A timeout is set for operations with virtual machines (VMs) in the platform. After this time, VMmanager stops the task. Default timeout values:
- for operations of creating, reinstalling and restoring VMs from a backup — 3600 sec (1 hour);
- to execute a script on a VM or cluster node — 10800 sec (3 hours).
To change the timeout value:
-
Get an authorization token:
curl -k -X POST -H "accept: application/json" -H "Content-Type: application/json" 'https://domain.com/auth/v4/public/token' -d '{"email": "admin_email", "password": "admin_pass"}'
Comments to the commandIn response, you will get the message in the form:
Example of response in JSON{ "confirmed": true, "expires_at": null, "id": "6", "token": "4-e9726dd9-61d9-2940-add3-914851d2cb8a" }
Save the received token value.
-
Execute the request:
Change the timeout for creating a VMcurl -H "x-xsrf-token: <token>" "https://domain.com/vm/v3/settings/task/host_create/timeout" -d '{"timeout_seconds": <seconds>}'
Change the timeout for VM reinstallationcurl -H "x-xsrf-token: <token>" "https://domain.com/vm/v3/settings/task/host_reinstall/timeout" -d '{"timeout_seconds": <seconds>}'
Change the timeout to restore VM from backupcurl -H "x-xsrf-token: <token>" "https://domain.com/vm/v3/settings/task/disk_restore/timeout" -d '{"timeout_seconds": <seconds>}'
Changing the timeout for executing a script on a VMcurl -H "x-xsrf-token: <token>" "https://domain.com/vm/v3/settings/task/host_run_recipe/timeout" -d '{"timeout_seconds": <seconds>}'
Changing the timeout for script execution on the cluster nodecurl -H "x-xsrf-token: <token>" "https://domain.com/vm/v3/settings/task/node_run_script/timeout" -d '{"timeout_seconds": <seconds>}'
Changing the timeout for creating VM backupcurl -H "x-xsrf-token: <token>" "https://domain.com/vm/v3/settings/task/disk_backup/timeout" -d '{"timeout_seconds": <seconds>}'
Comments to commands