Rebuild server

Method URI Description
POST /v2/{tenant_id}/servers/{server_id}/action Rebuilds the specified server. Specify the rebuild action in the request body.

Normal response codes: 202

Request

This table shows the URI parameters for the rebuild server request:

Name Type Description
{tenant_id} UUID Project ID
{server_id} UUID The UUID for the server.

This table shows the body parameters for the rebuild server request:

Name Type Description
imageRef string The UUID of the image to use for your server instance.
name string

(Optional)

The name for the new server.
metadata string

(Optional)

Metadata key and value pairs. The maximum size of the metadata key and value is 255 bytes each.

Example. Rebuild server: JSON request


{
	"rebuild": {
		"imageRef": "70a599e0-31e7-49b7-b260-868f441e862b",
		"name": "foobar",
		"adminPass": "seekr3t",
		"accessIPv4": "1.2.3.4",
		"accessIPv6": "fe80::100",
		"metadata": {
			"meta var": "meta val"
		}
	}
}
     

Response

This table shows the header parameters for the rebuild server response:

Name Type Description
Location AnyURI

(Required)

Specific URL of the server you want to rebuild.

Example. Rebuild server: JSON response


{
	"server": {
		"accessIPv4": "1.2.3.4",
		"accessIPv6": "fe80::100",
		"addresses": {
			"private": [
				{
					"addr": "192.168.0.3",
					"version": 4
				}
			]
		},
		"adminPass": "seekr3t",
		"created": "2012-09-12T17:20:36Z",
		"flavor": {
			"id": "1",
			"links": [
				{
					"href": "http://openstack.example.com/openstack/flavors/1",
					"rel": "bookmark"
				}
			]
		},
		"hostId": "1e3da81662354c25560b7e5ea6d8123031f67168b6992f20bb84df69",
		"id": "075e40fe-9f03-4652-ba8e-5f8e2547899a",
		"image": {
			"id": "70a599e0-31e7-49b7-b260-868f441e862b",
			"links": [
				{
					"href": "http://openstack.example.com/openstack/images/70a599e0-31e7-49b7-b260-868f441e862b",
					"rel": "bookmark"
				}
			]
		},
		"links": [
			{
				"href": "http://openstack.example.com/v2/openstack/servers/075e40fe-9f03-4652-ba8e-5f8e2547899a",
				"rel": "self"
			},
			{
				"href": "http://openstack.example.com/openstack/servers/075e40fe-9f03-4652-ba8e-5f8e2547899a",
				"rel": "bookmark"
			}
		],
		"metadata": {
			"meta var": "meta val"
		},
		"name": "foobar",
		"progress": 0,
		"status": "ACTIVE",
		"tenant_id": "openstack",
		"updated": "2012-09-12T17:20:37Z",
		"user_id": "fake"
	}
}