Miscellaneous server operations#
- Limits Operation
- Used Limits Operation
- Console Operation
- Quota Operation
- Extensions Operations
This section covers the following miscellaneous server operations:
Retrieve list of rate and absolute limits#
GET /limits
This operation retrieves the current rate limits and absolute limits for your account.
Applications can programmatically determine current account limits by using this API operation.
This table shows the possible response codes for this operation:
Response Code |
Name |
Description |
---|---|---|
200 |
Success |
Request succeeded. |
400 |
Error |
A general error has occured. |
401 |
Unauthorized |
Unauthorized. |
403 |
Forbidden |
Forbidden. |
405 |
Bad Method |
Bad method. |
409 |
Conflicting Reqest |
Conflicting request. |
413 |
Over Limit |
The number of items returned is above the allowed limit. |
500 |
API Fault |
API fault. |
503 |
Service Unavailable |
The requested service is unavailable. |
Request#
This operation does not accept a request body.
Example Retrieve list of rate and absolute limits: JSON request
X-Auth-Token: f064c46a782c444cb4ba4b6434288f7c
Content-Type: application/json
Accept: application/json
Response#
This table shows the body parameters for the response:
Name |
Type |
Description |
---|---|---|
limits |
Object |
The container of limits attributes. |
limits.absolute |
Object |
The container of absolute limits attributes. |
limits.absolute.maxTotalRAMSize |
Int |
The maximum amount of RAM allowed. |
limits.absolute.totalRAMUsed |
Int |
The total amount of RAM used. |
limits.absolute.maxServerMeta |
Int |
The maximum allowed server metadata items. |
limits.absolute.maxImageMeta |
Int |
The maximum allowed image metadata items. |
limits.absolute.maxPersonality |
Int |
The maximum number of personality files. |
limits.absolute.maxPersonalitySize |
Int |
The size of the personality files. |
limits.rate |
Array |
The array of rate objects. |
limits.rate.limit |
Array |
The array of rate limit objects. |
limits.rate.limit.next-available |
Date |
The next available rate limit date and time. |
limits.rate.limit.verb |
String |
The HTTP operation. |
limits.rate.limit. value |
String |
The max allowed time in units. |
limits.rate.limit.remaining |
Date |
The time remaining for the rate limit in units. |
limits.rate.limit.unit |
Date |
The type of unit for
the rate limit. For
example, |
Example Retrieve list of rate and absolute limits: JSON response
Status Code: 200 OK
Content-Length: 3010
Content-Type: application/json
Date: Wed, 18 Mar 2015 20:23:18 GMT, Wed, 18 Mar 2015 20:23:19 GMT
Server: Jetty(9.2.z-SNAPSHOT)
Via: 1.1 Repose (Repose/6.2.1.2)
X-Compute-Request-Id: req-48d05db0-dd97-4aef-87f2-11177ab8c262
{
"limits": {
"absolute": {
"totalSnapshotsUsed": 0,
"maxTotalVolumeGigabytes": 1000,
"totalGigabytesUsed": 0,
"maxTotalSnapshots": 10,
"totalVolumesUsed": 0,
"maxTotalVolumes": 10
},
"rate": [
{
"limit": [
{
"next-available": "2012-09-10T20:11:45.146Z",
"remaining": 0,
"unit": "DAY",
"value": 0,
"verb": "POST"
},
{
"next-available": "2012-09-10T20:11:45.146Z",
"remaining": 0,
"unit": "MINUTE",
"value": 0,
"verb": "GET"
}
],
"regex": "/v[^/]/(\\d+)/(rax-networks)/?.*",
"uri": "/rax-networks"
}
]
}
}
Retrieve list of limits including used limits#
GET /limits
This operation retrieves the current rate limits and absolute limits for your account including used limits.
This extension expands the limits operation to show the project usage, including RAM and instance quotas usage.
In the following example, the totalRAMUsed
value is an extended attribute.
This table shows the possible response codes for this operation:
Response Code |
Name |
Description |
---|---|---|
200 |
Success |
Request succeeded. |
400 |
Error |
A general error has occured. |
401 |
Unauthorized |
Unauthorized. |
403 |
Forbidden |
Forbidden. |
405 |
Bad Method |
Bad method. |
409 |
Conflicting Reqest |
Conflicting request. |
413 |
Over Limit |
The number of items returned is above the allowed limit. |
500 |
API Fault |
API fault. |
503 |
Service Unavailable |
The requested service is unavailable. |
Request#
This operation does not accept a request body.
Example Retrieve list of limits including used limits: JSON request
X-Auth-Token: f064c46a782c444cb4ba4b6434288f7c
Content-Type: application/json
Accept: application/json
Response#
This table shows the body parameters for the response:
Name |
Type |
Description |
---|---|---|
limits |
Object |
The container of limits attributes. |
limits.absolute |
Object |
The container of absolute limits attributes. |
limits.absolute.maxTotalRAMSize |
Int |
The maximum amount of RAM allowed. |
limits.absolute.totalRAMUsed |
Int |
The total amount of RAM used. |
limits.absolute.maxServerMeta |
Int |
The maximum allowed server metadata items. |
limits.absolute.maxImageMeta |
Int |
The maximum allowed image metadata items. |
limits.absolute.maxPersonality |
Int |
The maximum number of personality files. |
limits.absolute.maxPersonalitySize |
Int |
The size of the personality files. |
limits.rate |
Array |
The array of rate objects. |
limits.rate.limit |
Array |
The array of rate limit objects. |
limits.rate.limit.next-available |
Date |
The next available rate limit date and time. |
limits.rate.limit.verb |
String |
The HTTP operation. |
limits.rate.limit.value |
String |
The max allowed time in units. |
limits.rate.limit.remaining |
Date |
The time remaining for the rate limit in units. |
limits.rate.limit.unit |
Date |
The type of unit for
the rate limit. For
example, |
Example Retrieve list of limits including used limits: JSON response
{
"limits": {
"rate": [
{
"uri": "*",
"regex": ".*",
"limit": [
{
"value": 10,
"verb": "POST",
"remaining": 2,
"unit": "MINUTE",
"next-available": "2011-12-15T22:42:45Z"
},
{
"value": 10,
"verb": "PUT",
"remaining": 2,
"unit": "MINUTE",
"next-available": "2011-12-15T22:42:45Z"
},
{
"value": 100,
"verb": "DELETE",
"remaining": 100,
"unit": "MINUTE",
"next-available": "2011-12-15T22:42:45Z"
}
]
},
{
"uri": "*changes-since*",
"regex": "changes-since",
"limit": [
{
"value": 3,
"verb": "GET",
"remaining": 3,
"unit": "MINUTE",
"next-available": "2011-12-15T22:42:45Z"
}
]
},
{
"uri": "*/servers",
"regex": "^/servers",
"limit": [
{
"verb": "POST",
"value": 25,
"remaining": 24,
"unit": "DAY",
"next-available": "2011-12-15T22:42:45Z"
}
]
}
],
"absolute": {
"maxTotalRAMSize": 51200,
"totalRAMUsed": 1024,
"maxServerMeta": 5,
"maxImageMeta": 5,
"maxPersonality": 5,
"maxPersonalitySize": 10240
}
}
}
Get console#
POST /servers/{server_id}/action
This operation returns a URL which you use with either a java client or an HTML-based novnc console to open a console connection to your server.
In the URI, specify the server ID.
To use the URL returned from this operation with the java option, you should download and install a VNC Viewer like Real VNC or Tight VNC. Then, from the directory where you saved the Vnc Viewer, run the following command (using the installed jar and the URL from the operation response body):
java -jar VncViewer.jar URL {returnedURL}
To use the URL returned from this operation with the HTML novnc option, open a browser and copy the URL to the address bar of the browser.
The following table shows the possible response codes for this operation:
Response Code |
Name |
Description |
---|---|---|
200 203 |
Success |
Request succeeded. |
400 |
Error |
A general error has occured. |
401 |
Unauthorized |
Unauthorized. |
403 |
Forbidden |
Forbidden. |
405 |
Bad Method |
Bad method. |
409 |
Conflicting Reqest |
Conflicting request. |
413 |
Over Limit |
The number of items returned is above the allowed limit. |
500 |
API Fault |
API fault. |
503 |
Service Unavailable |
The requested service is unavailable. |
Request#
The following table shows the URI parameters for the request:
Name |
Type |
Description |
---|---|---|
{server_id} |
Uuid |
The UUID for the server. |
The following table shows the body parameters for the request:
Name |
Type |
Description |
---|---|---|
os- getVNCConsole |
Object |
A container for console request. |
os- getVNCConsole.type |
String |
A key pair with the type
of vnc console,
containing the value
|
Example Get console - java: JSON request
X-Auth-Token: f064c46a782c444cb4ba4b6434288f7c
Content-Type: application/json
Accept: application/json
{
"os-getVNCConsole":
{
"type": "xvpvnc"
}
}
Example Get console - novnc: JSON request
X-Auth-Token: f064c46a782c444cb4ba4b6434288f7c
Content-Type: application/json
Accept: application/json
{
"os-getVNCConsole":
{
"type": "novnc"
}
}
Response#
The following table shows the body parameters for the response:
Name |
Type |
Description |
---|---|---|
console |
Object |
A container for console response. |
console. url |
String |
The URL for the console for the specified server. Open this URL in a browser to open a VNC console to the server. |
console.type |
String |
The type of VNC console
to the server, for
example |
Example Get console - java: JSON response
Status Code: 200 OK
Content-Length: 143
Content-Type: application/json
Date: Tue, 30 Jun 2015 17:38:17 GMT, Tue, 30 Jun 2015 17:38:19 GMT
Server: Jetty(9.2.z-SNAPSHOT)
Via: 1.1 Repose (Repose/6.2.1.2)
X-Compute-Request-Id: req-910673e3-3b1c-45ce-9f87-6c2eea304692
{
"console": {
"url": "https://dfw.servers.console.rackspacecloud.com:443/console?token=b40c6057-4bcb-4ee7-a359-dcecc752b379",
"type": "xvpvnc"
}
}
Example Get console - novnc: JSON response
Status Code: 200 OK
Content-Length: 143
Content-Type: application/json
Date: Tue, 30 Jun 2015 17:345:17 GMT, Tue, 30 Jun 2015 17:45:19 GMT
Server: Jetty(9.2.z-SNAPSHOT)
Via: 1.1 Repose (Repose/6.2.1.2)
X-Compute-Request-Id: req-9235673f2-4a1d-75cc-2a22-5d3fef994122
{
"console": {
"url": "https://dfw.servers.console.rackspacecloud.com:443/console?token=a71d5697-2aca-5ea2-d991-abad292b351",
"type": "novnc"
}
}
Retrieve quotas#
GET /os-quota-sets/{tenant_id}
This operation shows current quotas for a tenant.
In the URI, specify the tenant ID.
This table shows the possible response codes for this operation:
Response Code |
Name |
Description |
---|---|---|
200 203 |
Success |
Request succeeded. |
400 |
Error |
A general error has occured. |
401 |
Unauthorized |
Unauthorized. |
403 |
Forbidden |
Forbidden. |
405 |
Bad Method |
Bad method. |
409 |
Conflicting Reqest |
Conflicting request. |
413 |
Over Limit |
The number of items returned is above the allowed limit. |
500 |
API Fault |
API fault. |
503 |
Service Unavailable |
The requested service is unavailable. |
Request#
This table shows the URI parameters for the request:
Name |
Type |
Description |
---|---|---|
{tenant_id} |
String |
The tenant id. |
This operation does not accept a request body.
Example Retrieve quotas: JSON request
X-Auth-Token: f064c46a782c444cb4ba4b6434288f7c
Content-Type: application/json
Accept: application/json
Response#
This table shows the body parameters for the response:
Name |
Type |
Description |
---|---|---|
quota-set |
Object |
The container of quota- sets. |
quota-set.ram |
Int |
The quota for ram. |
quota-set.instances |
Uuid |
The quota for instances. |
quota-set.metadata-items |
Uuid |
The quota for metadata- items. |
Example Retrieve quotas: JSON response
Status Code: 200 OK
Content-Length: 513
Content-Type: application/json
Date: Fri, 10 Jul 2015 17:33:12 GMT, Fri, 10 Jul 2015 17:33:12 GMT
Server: Jetty(9.2.z-SNAPSHOT)
Via: 1.1 Repose (Repose/6.2.1.2)
X-Compute-Request-Id: req-01fb912a-5a59-4ac1-80d6-368c2a2e0df8
{
"quota_set": {
"injected_file_content_bytes": 1000,
"metadata_items": 40,
"ram": 131072,
"security_group_rules": -1,
"onmetal-memory-v1-ram": 131072,
"onmetal-compute-v1-instances": 100,
"onmetal-compute-v1-ram": 131072,
"networks": 10,
"floating_ips": -1,
"key_pairs": 100,
"id": "1234567",
"instances": 100,
"onmetal-memory-v1-instances": 100,
"injected_files": 5,
"onmetal-io-v1-instances": 100,
"cores": -1,
"onmetal-io-v1-ram": 131072,
"fixed_ips": -1,
"injected_file_path_bytes": 255,
"security_groups": -1
}
}
Retrieve list of extensions#
GET /extensions
This operation retrieves the list of available extensions.
This table shows the possible response codes for this operation:
Response Code |
Name |
Description |
---|---|---|
200 |
Success |
Request succeeded. |
400 |
Error |
A general error has occured. |
401 |
Unauthorized |
Unauthorized. |
403 |
Forbidden |
Forbidden. |
405 |
Bad Method |
Bad method. |
409 |
Conflicting Reqest |
Conflicting request. |
413 |
Over Limit |
The number of items returned is above the allowed limit. |
500 |
API Fault |
API fault. |
503 |
Service Unavailable |
The requested service is unavailable. |
Request#
This operation does not accept a request body.
Example Retrieve list of extensions: JSON request
X-Auth-Token: f064c46a782c444cb4ba4b6434288f7c
Content-Type: application/json
Accept: application/json
Response#
This table shows the body parameters for the response:
Name |
Type |
Description |
---|---|---|
extensions |
Array |
The array of extensions. |
extensions.updated |
Date |
The most recent update date for the extension. |
extensions.name |
String |
The name of the extension. |
extensions.links |
Array |
The array of links for the extension. |
extensions.namespace |
String |
The namespace of the extension. |
extensions.alias |
String |
The alias, or short name, of the extension. |
extensions.description |
String |
The description of the extension. |
Example Retrieve list of extensions: JSON response
The following example shows only a few extensions in the list for brevity.
Status Code: 200 OK
Content-Length: 6045
Content-Type: application/json
Date: Fri, 10 Jul 2015 19:53:39 GMT, Fri, 10 Jul 2015 19:53:39 GMT
Server: Jetty(9.2.z-SNAPSHOT)
Via: 1.1 Repose (Repose/6.2.1.2)
X-Compute-Request-Id: req-79e5a4fe-81ca-4965-b616-6935bab482b3
{
"extensions": [
{
"updated": "2011-09-27T00:00:00Z",
"name": "DiskConfig",
"links": [],
"namespace": "http://docs.openstack.org/compute/ext/disk_config/api/v1.1",
"alias": "OS-DCF",
"description": "Disk Management Extension."
},
{
"updated": "2012-03-07T14:46:43Z",
"name": "OSNetworksV2",
"links": [],
"namespace": "http://docs.openstack.org/ext/services/api/v1.1",
"alias": "os-networksv2",
"description": "Admin-only Network Management Extension."
},
{
"updated": "2011-08-17T00:00:00Z",
"name": "VirtualInterfaces",
"links": [],
"namespace": "http://docs.openstack.org/compute/ext/virtual_interfacesv2/api/v1.1",
"alias": "os-virtual-interfacesv2",
"description": "Virtual interface support."
},
{
"updated": "2013-03-20T00:00:00Z",
"name": "ScheduledImages",
"links": [],
"namespace": "http://docs.openstack.org/servers/api/ext/scheduled_images/v1.0",
"alias": "rax-si-image-schedule",
"description": "Enables automatic scheduled images to be taken of a server."
}
]
}
Retrieve details for the specified extension#
GET /extensions/{alias}
This operation retrieves a specified extension’s details.
An unavailable extension issues an itemNotFound (404)
response.
This table shows the possible response codes for this operation:
Response Code |
Name |
Description |
---|---|---|
200 |
Success |
Request succeeded. |
400 |
Error |
A general error has occured. |
401 |
Unauthorized |
Unauthorized. |
403 |
Forbidden |
Forbidden. |
405 |
Bad Method |
Bad method. |
409 |
Conflicting Reqest |
Conflicting request. |
413 |
Over Limit |
The number of items returned is above the allowed limit. |
500 |
API Fault |
API fault. |
503 |
Service Unavailable |
The requested service is unavailable. |
Request#
This table shows the URI parameters for the request:
Name |
Type |
Description |
---|---|---|
{alias} |
Uuid |
The alias, which is a name for a pointer to a resource. For example, a named extension. |
This operation does not accept a request body.
Example Retrieve details for the specified extension: JSON request
X-Auth-Token: f064c46a782c444cb4ba4b6434288f7c
Content-Type: application/json
Accept: application/json
Response#
This table shows the body parameters for the response:
Name |
Type |
Description |
---|---|---|
extension |
Object |
The container of extensions attributes. |
extension.updated |
Date |
The most recent update date for the extension. |
extension.name |
String |
The name of the extension. |
extension.links |
Array |
The array of links for the extension. |
extension.namespace |
String |
The namespace of the extension. |
extension.alias |
String |
The alias, or short name, of the extension. |
extension.description |
String |
The description of the extension. |
Example Retrieve details for the specified extension: JSON response
Status Code: 200 OK
Content-Length: 257
Content-Type: application/json
Date: Fri, 10 Jul 2015 19:56:53 GMT, Fri, 10 Jul 2015 19:56:54 GMT
Server: Jetty(9.2.z-SNAPSHOT)
Via: 1.1 Repose (Repose/6.2.1.2)
X-Compute-Request-Id: req-d612f98f-d446-493c-a1ba-6869828f8a80
{
"extension": {
"updated": "2011-08-17T00:00:00Z",
"name": "VirtualInterfaces",
"links": [],
"namespace": "http://docs.openstack.org/compute/ext/virtual_interfacesv2/api/v1.1",
"alias": "os-virtual-interfacesv2",
"description": "Virtual interface support."
}
}