Host network placement
Use this REST API to get assistance with placement decisions when you deploy or migrate a virtual machine to a host. The API provides information about the hosts that fulfill the network requirements for a virtual machine.
Network placement API options
Method | URI | Description |
---|---|---|
GET |
|
Lists network placement data. |
GET |
|
Lists network placement data for a specific host. |
GET |
|
Lists network mappings for a specified network. |
GET |
|
Lists all networks that are supported by the hosts for a specified host group. |
GET |
|
Lists all hosts that are compatible with the specified Neutron port accounting for network ID, SR-IOV capacity (if applicable), and SR-IOV logical ports (if applicable). |
GET |
|
Lists the union of all networks supported by the hosts in an availability zone (AZ). |
Get host network placement
The following is an example of a GET operation, which is a request for information about valid combinations of hosts and networks. The host and network data is included in the response and can be used to make virtual machine placement decisions. A host can have multiple networks, and a network can be on multiple hosts.
- Normal response code: 200
- Error response codes: Bad Request (400), Unauthorized (401), Not Found (404)
host
and the network_id
are specified at the same time.GET /v2.1/{tenant_id}/host-network-placement
Accept: application/json
Response JSON:
Name | In | Type | Description |
---|---|---|---|
|
body |
String |
Name of the host that is used by OpenStack configuration. The host name is not the same as the host name of a networking concept that is used for Domain Name Service. |
|
body |
String |
The ID for the network that is used by OpenStack configuration. |
|
body |
String |
A unique identifier that refers to an isolated portion of the physical network infrastructure. |
|
body |
Integer |
The number of valid SR-IOV physical ports that can host this network. If this number is 2 or greater, you can deploy a virtual machine with a redundant adapter. A valid physical port is one with nonzero capacity, nonzero available logical ports, and a port label that matches the network's physical network name. |
|
body |
Integer |
The The |
|
body |
Integer |
The The |
|
body |
Integer |
The The |
|
body |
Integer |
The capacity cannot be lower than this value and must be a multiple of this value. |
200 (OK)
Content-Type: application/json
{
"host-network-placement": [
{
"host_name": "828642A_21C1B7V",
"networks": [
{
"network_id": "0b248872-852c-4c09-b66d-12d401d928cc"
},
{
"network_id": "c214345d-6cd9-4b69-91c6-4028a00a3087"
},
{
"network_id": "d60cefa4-e9c1-42d0-a3fa-b5e4c9eb9a31"
}
]
},
{
"host_name": "828642A_21C1B5V",
"networks": [
{
"network_id": "0b248872-852c-4c09-b66d-12d401d928cc"
},
{
"network_id": "c214345d-6cd9-4b69-91c6-4028a00a3087"
},
{
"network_id": "d60cefa4-e9c1-42d0-a3fa-b5e4c9eb9a31"
}
]
}
],
"host-network-placement-sea": [
{
"host_name": "828642A_21C1B7V",
"networks": [
{
"network_id": "0b248872-852c-4c09-b66d-12d401d928cc"
},
{
"network_id": "c214345d-6cd9-4b69-91c6-4028a00a3087"
},
{
"network_id": "d60cefa4-e9c1-42d0-a3fa-b5e4c9eb9a31"
}
]
},
{
"host_name": "828642A_21C1B5V",
"networks": [
{
"network_id": "0b248872-852c-4c09-b66d-12d401d928cc"
},
{
"network_id": "c214345d-6cd9-4b69-91c6-4028a00a3087"
},
{
"network_id": "d60cefa4-e9c1-42d0-a3fa-b5e4c9eb9a31"
}
]
}
],
"host-network-placement-sriov": [
{
"host_name": "828642A_21C1B7V",
"networks": [
{
"available_pps": 2,
"capacity_step": 2,
"min_capacity_2x": 68,
"min_capacity_lower": 20,
"min_capacity_upper": 68,
"network_id": "d60cefa4-e9c1-42d0-a3fa-b5e4c9eb9a31",
"physical_network_name": "default"
},
{
"available_pps": 3,
"capacity_step": 2,
"min_capacity_2x": 40,
"min_capacity_lower": 36,
"min_capacity_upper": 50,
"network_id": "0b248872-852c-4c09-b66d-12d401d928cc",
"physical_network_name": "Data1"
},
{
"available_pps": 1,
"capacity_step": 2,
"min_capacity_2x": 48,
"min_capacity_lower": 48,
"min_capacity_upper": 48,
"network_id": "c214345d-6cd9-4b69-91c6-4028a00a3087",
"physical_network_name": "Data3"
}
]
},
{
"host_name": "828642A_21C1B5V",
"networks": [
{
"available_pps": 1,
"capacity_step": 2,
"min_capacity_2x": 26,
"min_capacity_lower": 26,
"min_capacity_upper": 26,
"network_id": "d60cefa4-e9c1-42d0-a3fa-b5e4c9eb9a31",
"physical_network_name": "default"
},
{
"available_pps": 3,
"capacity_step": 2,
"min_capacity_2x": 56,
"min_capacity_lower": 40,
"min_capacity_upper": 84,
"network_id": "3491b6f8-07c5-78d9-ed1a-24a309f427db",
"physical_network_name": "Data1"
},
{
"available_pps": 1,
"capacity_step": 2,
"min_capacity_2x": 18,
"min_capacity_lower": 18,
"min_capacity_upper": 18,
"network_id": "b258F43c-89d3-5c83-1c95-48c32f92a391",
"physical_network_name": "Data3"
}
]
},
{
"host_name": "8246L2D_2110DFA",
"networks": []
}
]
}
],
"host-network-placement-ovs": [
{
"host_name": "host1",
"networks": [
{
"network_id": "3491bb01-18e4-4240-2df7-3b0a9fe21c9e",
"physical_network_name": "br-ex"
},
{
"network_id": "b258f43c-452c-2828-3a2e-3b4af2d8e2c6",
"physical_network_name": "br-ex"
}
]
},
{
"host_name": "host2",
"networks": [
{
"network_id": "b258f43c-452c-2828-3a2e-3b4af2d8e2c6",
"physical_network_name": "br-ex"
}
]
}
]
}
Get host network placement for a specific host
The following is an example of a GET operation, which is a request to get the details for a specific host. The API takes the host name in the URI as input and returns all networks that are connected to the host in the response.
- Normal Response Code: 200
- Error Response Codes:
- Bad Request (400)
- Unauthorized (401)
- Not Found (404)
GET /v2.1/{tenant_id}/host-network-placement/{host_name}
Accept: application/json
Response JSON:
Name | In | Type | Description |
---|---|---|---|
|
body |
string |
Name of the host that is used by OpenStack configuration. The host name is not the same as the host name of a networking concept that is used for Domain Name Service. |
|
body |
string |
The ID for the network that is used by OpenStack configuration. |
|
body |
String |
A unique identifier that refers to an isolated portion of the physical network infrastructure. |
|
body |
Integer |
The number of valid SR-IOV physical ports that can host this network. If this number is 2 or greater, you can deploy a virtual machine with a redundant adapter. A valid physical port is one with nonzero capacity, nonzero available logical ports, and a port label that matches the network's physical network name. |
|
body |
Integer |
The The |
|
body |
Integer |
The The |
|
body |
Integer |
The The |
|
body |
Integer |
The capacity cannot be lower than this value and must be a multiple of this value. |
200 (OK)
Content-Type: application/json
{
"host-network-placement": [
{
"host_name": "828642A_21C1B5V",
"networks": [
{
"network_id": "0b248872-852c-4c09-b66d-12d401d928cc"
},
{
"network_id": "c214345d-6cd9-4b69-91c6-4028a00a3087"
},
{
"network_id": "d60cefa4-e9c1-42d0-a3fa-b5e4c9eb9a31"
}
]
}
],
"host-network-placement-sea": [
{
"host_name": "828642A_21C1B5V",
"networks": [
{
"network_id": "0b248872-852c-4c09-b66d-12d401d928cc"
},
{
"network_id": "c214345d-6cd9-4b69-91c6-4028a00a3087"
},
{
"network_id": "d60cefa4-e9c1-42d0-a3fa-b5e4c9eb9a31"
}
]
}
],
"host-network-placement-sriov": [
{
"host_name": "828642A_21C1B5V",
"networks": [
{
"available_pps": 1,
"capacity_step": 2,
"min_capacity_2x": 26,
"min_capacity_lower": 26,
"min_capacity_upper": 26,
"network_id": "d60cefa4-e9c1-42d0-a3fa-b5e4c9eb9a31",
"physical_network_name": "default"
},
{
"available_pps": 3,
"capacity_step": 2,
"min_capacity_2x": 56,
"min_capacity_lower": 40,
"min_capacity_upper": 84,
"network_id": "0b248872-852c-4c09-b66d-12d401d928cc",
"physical_network_name": "Data1"
},
{
"available_pps": 1,
"capacity_step": 2,
"min_capacity_2x": 18,
"min_capacity_lower": 18,
"min_capacity_upper": 18,
"network_id": "c214345d-6cd9-4b69-91c6-4028a00a3087",
"physical_network_name": "Data3"
}
]
}
],
"host-network-placement-ovs": [
{
"host_name": "host1",
"networks": [
{
"network_id": "3491bb01-18e4-4240-2df7-3b0a9fe21c9e",
"physical_network_name": "br-ex"
},
{
"network_id": "b258f43c-452c-2828-3a2e-3b4af2d8e2c6",
"physical_network_name": "br-ex"
}
]
}
]
}
Get host network placement for a specific network
The following is an example of a GET operation, which is a request to get the details for a specific network ID. The API takes the network ID of the host in the URI as input and returns all hosts that are connected to the network in the response.
Response Codes
- Normal Response Code: 200
- Error Response Codes:
- Bad Request (400)
- Unauthorized (401)
- Not Found (404)
GET /v2.1/{tenant_id}/host-network-placement?network_id={network_id}
Accept: application/json
Response JSON:
Name | In | Type | Description |
---|---|---|---|
|
body |
string |
Name of the host that is used by OpenStack configuration. The host name is not the same as the host name of a networking concept that is used for Domain Name Service. |
|
body |
string |
The ID for the network that is used by OpenStack configuration. |
|
body |
String |
A unique identifier that refers to an isolated portion of the physical network infrastructure. |
|
body |
Integer |
The number of valid SR-IOV physical ports that can host this network. If this number is 2 or greater, you can deploy a virtual machine with a redundant adapter. A valid physical port is one with nonzero capacity, nonzero available logical ports, and a port label that matches the network's physical network name. |
|
body |
Integer |
The The |
|
body |
Integer |
The The |
|
body |
Integer |
The The |
|
body |
Integer |
The capacity cannot be lower than this value and must be a multiple of this value. |
200 (OK)
Content-Type: application/json
{
"host-network-placement": [
{
"host_name": "828642A_21C1B7V",
"networks": [
{
"network_id": "0b248872-852c-4c09-b66d-12d401d928cc"
}
]
},
{
"host_name": "828642A_21C1B5V",
"networks": [
{
"network_id": "0b248872-852c-4c09-b66d-12d401d928cc"
}
]
}
],
"host-network-placement-sea": [
{
"host_name": "828642A_21C1B7V",
"networks": [
{
"network_id": "0b248872-852c-4c09-b66d-12d401d928cc"
}
]
},
{
"host_name": "828642A_21C1B5V",
"networks": [
{
"network_id": "0b248872-852c-4c09-b66d-12d401d928cc"
}
]
}
],
"host-network-placement-sriov": [
{
"host_name": "828642A_21C1B7V",
"networks": [
{
"available_pps": 3,
"capacity_step": 2,
"min_capacity_2x": 40,
"min_capacity_lower": 36,
"min_capacity_upper": 50,
"network_id": "0b248872-852c-4c09-b66d-12d401d928cc",
"physical_network_name": "Data1"
}
]
},
{
"host_name": "828642A_21C1B5V",
"networks": [
{
"available_pps": 3,
"capacity_step": 2,
"min_capacity_2x": 56,
"min_capacity_lower": 40,
"min_capacity_upper": 84,
"network_id": "0b248872-852c-4c09-b66d-12d401d928cc",
"physical_network_name": "Data1"
}
]
}
],
"host-network-placement-ovs": []
}
Get host network placement for a host group
The following is an example of a GET operation, which is a request to get the details of all hosts in the group and all networks compatible with each host and then create a group of the network list.
Response Codes
- Normal Response Code: 200
- Error Response Codes:
- Bad Request (400)
- Unauthorized (401)
- Not Found (404)
GET compute/v2.1/{tenant_id}/host-network-placement?host_aggregate={host_aggregate}
Accept: application/json
Response JSON:
Name | In | Type | Description |
---|---|---|---|
|
body |
string |
Name of the host group that is used by OpenStack configuration. |
|
body |
string |
The ID for the network that is used by OpenStack configuration. |
|
body |
String |
A unique identifier that refers to an isolated portion of the physical network infrastructure. |
|
body |
Integer |
The number of valid SR-IOV physical ports that can host this network. If this number is 2 or greater, you can deploy a virtual machine with a redundant adapter. A valid physical port is one with nonzero capacity, nonzero available logical ports, and a port label that matches the network's physical network name. |
|
body |
Integer |
The The |
|
body |
Integer |
The The |
|
body |
Integer |
The The |
|
body |
Integer |
The capacity cannot be lower than this value and must be a multiple of this value. |
200 (OK)
Content-Type: application/json
{
"host-network-placement": [
{
"host_aggregate": "1",
"networks": [
{
"network_id": "0b248872-852c-4c09-b66d-12d401d928cc"
},
{
"network_id": "c214345d-6cd9-4b69-91c6-4028a00a3087"
},
{
"network_id": "d60cefa4-e9c1-42d0-a3fa-b5e4c9eb9a31"
}
]
}
],
"host-network-placement-sea": [
{
"host_aggregate": "1",
"networks": [
{
"network_id": "0b248872-852c-4c09-b66d-12d401d928cc"
},
{
"network_id": "c214345d-6cd9-4b69-91c6-4028a00a3087"
},
{
"network_id": "d60cefa4-e9c1-42d0-a3fa-b5e4c9eb9a31"
}
]
}
],
"host-network-placement-sriov": [
{
"host_aggregate": "1",
"networks": [
{
"min_capacity_2x": 40,
"min_capacity_upper": 50,
"network_id": "0b248872-852c-4c09-b66d-12d401d928cc",
"min_capacity_lower": 36,
"available_pps": 3,
"physical_network_name": "Data1",
"capacity_step": 2
},
{
"min_capacity_2x": 48,
"min_capacity_upper": 48,
"network_id": "c214345d-6cd9-4b69-91c6-4028a00a3087",
"min_capacity_lower": 48,
"available_pps": 1,
"physical_network_name": "Data3",
"capacity_step": 2
},
{
"min_capacity_2x": 86,
"min_capacity_upper": 86,
"network_id": "a3677b1f-403a-403e-b22d-546f7f0f9311",
"min_capacity_lower": 60,
"available_pps": 2,
"physical_network_name": "Data2",
"capacity_step": 2
}
]
}
],
],
"host-network-placement-ovs": [
{
"host_aggregate": "1",
"networks": [
{
"network_id": "3491bb01-18e4-4240-2df7-3b0a9fe21c9e"
},
{
"network_id": "b258f43c-452c-2828-3a2e-3b4af2d8e2c6"
}
]
}
]
}
Get host network placement for a port ID
The following is an example of a GET operation, which is a request to get all hosts that are compatible with the specified Neutron port accounting for network ID, SR-IOV capacity (if applicable), and SR-IOV logical ports (if applicable).
- Normal Response Code: 200
- Error Response Codes:
- Bad Request (400)
- Unauthorized (401)
- Not Found (404)
GET compute/v2/tenant/host-network-placement?port_id={port_id}
Accept: application/json
Response JSON:
Name | In | Type | Description |
---|---|---|---|
|
body |
string |
Name of the host group that is used by OpenStack configuration. |
|
body |
string |
The ID for the network that is used by OpenStack configuration. |
|
body |
String |
A unique identifier that refers to an isolated portion of the physical network infrastructure. |
|
body |
Integer |
The number of valid SR-IOV physical ports that can host this network. If this number is 2 or greater, you can deploy a virtual machine with a redundant adapter. A valid physical port is one with nonzero capacity, nonzero available logical ports, and a port label that matches the network's physical network name. |
|
body |
Integer |
The The |
|
body |
Integer |
The The |
|
body |
Integer |
The The |
|
body |
Integer |
The capacity cannot be lower than this value and must be a multiple of this value. |
200 (OK)
Content-Type: application/json
{
"host-network-placement": [],
"host-network-placement-sea": [],
"host-network-placement-sriov": [
{
"host_name": "host1 ",
"networks": [
{
"network_id": "ade3c5e807ff479c9ed1ad43",
"physical_network_name": "DATA1",
"available_pps": 2,
"min_capacity_lower": 60,
"min_capacity_2x": 60,
"min_capacity_upper": 80,
"capacity_step": 2
}
]
}
],
"host-network-placement-ovs": []
}
Get host network placement for availability zone
The following is an example of a GET operation, which is a request to get all hosts in the availability zone (AZ), find all networks compatible with each host, and then perform a union of that network list.
- Normal Response Code: 200
- Error Response Codes:
- Bad Request (400)
- Unauthorized (401)
- Not Found (404)
GET compute/v2/tenant/host-network-placement?availability_zone={az1}
Accept: application/json
Response JSON:
Name | In | Type | Description |
---|---|---|---|
|
body |
string |
Name of the availability zones that are used by OpenStack configuration. |
|
body |
string |
The ID for the network that is used by OpenStack configuration. |
|
body |
String |
A unique identifier that refers to an isolated portion of the physical network infrastructure. |
|
body |
Integer |
The number of valid SR-IOV physical ports that can host this network. If this number is 2 or greater, you can deploy a virtual machine with a redundant adapter. A valid physical port is one with nonzero capacity, nonzero available logical ports, and a port label that matches the network's physical network name. |
|
body |
Integer |
The The |
|
body |
Integer |
The The |
|
body |
Integer |
The The |
|
body |
Integer |
The capacity cannot be lower than this value and must be a multiple of this value. |
200 (OK)
Content-Type: application/json
{
"host-network-placement": [
{
"availability_zone": "az1",
"networks": [
{
"network_id": "ade3c5e807ff479c9ed1ad43"
},
{
"network_id": "e807fade3c5f399ed1ad43c9"
}
]
}
],
"host-network-placement-sea": [
{
"availability_zone": "az1",
"networks": [
{
"network_id": "ade3c5e807ff479c9ed1ad43"
},
{
"network_id": "e807fade3c5f399ed1ad43c9"
}
]
}
],
"host-network-placement-sriov": [
{
"availability_zone": "az1",
"networks": [
{
"network_id": "ade3c5e807ff479c9ed1ad43",
"physical_network_name": "DATA1",
"available_pps": 2,
"min_capacity_lower": 60,
"min_capacity_2x": 60,
"min_capacity_upper": 80,
"capacity_step": 2
},
{
"network_id": "e807fade3c5f399ed1ad43c9",
"physical_network_name": "DATA1",
"available_pps": 2,
"min_capacity_lower": 60,
"min_capacity_2x": 60,
"min_capacity_upper": 80,
"capacity_step": 2
}
]
}
]
}