Host Shared Ethernet Adapters

Use the REST API to read host Shared Ethernet Adapters for PowerVC

Host Shared Ethernet Adapters API options

Note: The REST API returns a 501 error when called in an invalid environment.
Table 1. REST API options to read host Shared Ethernet Adapters
Method URI Description

GET

/v2.1/{tenant_id}/host-seas

Lists all the Shared Ethernet Adapters that are configured on all hosts.

GET

/v2.1/{tenant_id}/host-seas/{host_name}

Lists all the Shared Ethernet Adapters that are configured on the host that is specified.

Note: VLAN ID is ignored when network ID is specified

View all Shared Ethernet Adapters

The operation does not require a request body. If body is specified, it is ignored. This following example lists all Shared Ethernet Adapters for all hosts. The response has the default attribute set to true on the adapter with the lowest pvid. The Shared Ethernet Adapters with high availability for each primary Shared Ethernet Adapter are identified in the returned JSON entries as the VIOS for host1 is configured for high availability.

Response Codes
  • Normal Response Code: 200
  • Error Response Codes:
    • Bad Request (400)
    • Unauthorized (401)
    • Not Found (404)
    • Invalid Environment (501)
Request parameters:
GET /v2.1/{tenant_id}/host-seas
Accept: application/json
Table 2. Parameters for VLAN and network IDs
Name In Type Description

network_id

query

optional

The ID for the network that is used by OpenStack configuration. To filter the returned list by a network ID, specify ?network_id={network_id} in the URI.

vlan_id

query

optional

The ID for the virtual local area network or VLAN. To filter the returned list by a VLAN ID, specify ?vlanid={vlan_id} in the URI.

Response JSON:

Table 3. Parameters in the response for viewing all host Shared Ethernet Adapters
Name In Type Description

host_name

body

string

Name of the host that is used by OpenStack configuration. The host name is not same as the networking concept of a host name that is used for Domain Name Service.

default

body

boolean

Whether the Shared Ethernet Adapter is serving traffic for the specified host and network pair.

network_id

body

string

The ID for the network that is used by OpenStack configuration.

sea_name

body

string

The name of the Shared Ethernet Adapter.

vswitch

body

string

Name of the virtual switch in the PowerVM® hypervisor that this Shared Ethernet Adapter is connected to.

pvid

body

integer

This VLAN ID of the primary virtual ethernet adapter for this Shared Ethernet Adapter. The ID is typically a positive integer in the range 1 - 4094 inclusive.

lpar_id

body

integer

The ID for the Virtual I/O Server logical partition that owns the specified Shared Ethernet Adapter. The ID is typically a positive integer.

ha_lpar_id

body

integer

If the Shared Ethernet Adapter has a redundant adapter that is configured for high availability, this attribute is the ID for the redundant Virtual I/O Server logical partition that owns the redundant Shared Ethernet Adapter. The ID is typically a positive integer and a whole number.

ha_mode

body

string

Whether a redundant Shared Ethernet Adapter is configured for high availability on this host and network combination. Possible values are enabled or disabled.

state

body

string

Shows the availability of the Shared Ethernet Adapter.

ha_state

body

string

The state of the redundant Shared Ethernet Adapter on the redundant Virtual I/O Server.

lpar_name

body

string

Name of the Virtual I/O Server logical partition that owns the Shared Ethernet Adapter.

ha_lpar_name

body

string

Name of the redundant Virtual I/O Server logical partition that owns the redundant Shared Ethernet Adapter.

ha_sea

body

string

Name of the redundant Shared Ethernet Adapter that is configured for high availability.

Example:
{
 "host-seas": [
	{
	 "host_name": "host1",
	 "adapters": [
		{
		"default": false,
		"sea_name": "do-not-use",
		"vswitch": "do-not-use",
		"pvid": null,
		"lpar_id": 0,
		"ha_lpar_id": null,
		"ha_mode": "disabled",
		"state": "Not-Applicable",
		"ha_state": null,
		"lpar_name": null,
		"ha_lpar_name": null,
		"ha_sea": null
		},
		{
		 "default": true,
		 "sea_name": "ent11",
		 "vswitch": "ETHERNET0",
		 "lpar_id": 1,
		 "ha_lpar_id": 2,
		 "ha_mode": "enabled",
		 "pvid": 1,
		 "state": "Available",
		 "ha_state": "Available",
		 "lpar_name": "10-23C2P",
		 "ha_lpar_name": "10-24C2P",
		 "ha_sea": "ent21"
		},
		{
		 "default": false,
		 "sea_name": "ent12",
		 "vswitch": "ETHERNET0",
		 "lpar_id": 1,
		 "ha_lpar_id": 2,
		 "ha_mode": "enabled",
		 "pvid": 2,
		 "state": "Available",
		 "ha_state": "Available",
		 "lpar_name": "10-23C2P",
		 "ha_lpar_name": "10-24C2P",
		 "ha_sea": "ent22"
		},
		{
		 "default": false,
		 "sea_name": "ent13",
		 "vswitch": "ETHERNET0",
		 "lpar_id": 1,
		 "ha_lpar_id": 2,
		 "ha_mode": "enabled",
		 "pvid": 3,
		 "state": "Available",
		 "ha_state": "Available",
		 "lpar_name": "10-23C2P",
		 "ha_lpar_name": "10-24C2P",
		 "ha_sea": "ent23"
		}
	 ]
	},
	{
	 "host_name": "host2",
	 "adapters": [
		{
		"default": false,
		"sea_name": "do-not-use",
		"vswitch": "do-not-use",
		"pvid": null,
		"lpar_id": 0,
		"ha_lpar_id": null,
		"ha_mode": "disabled",
		"state": "Not-Applicable",
		"ha_state": null,
		"lpar_name": null,
		"ha_lpar_name": null,
		"ha_sea": null
		},
		{
		 "default": true,
		 "sea_name": "ent5",
		 "vswitch": "ETHERNET0",
		 "lpar_id": 1,
		 "ha_lpar_id": null,
		 "ha_mode": "disabled",
		 "pvid": 1,
		 "state": "Available",
		 "ha_state": null,
		 "lpar_name": "15-34B9Z",
		 "ha_lpar_name": null,
		 "ha_sea": null
		}
	 ]
	}
 ]
}

View Shared Ethernet Adapters for a VLAN ID

In the following example, the user requested the following:
  • Return all Shared Ethernet Adapters for host1 on tenant e9a2464cf00f4bc98eb2d02c534f47b7.
  • Set default attribute for any Shared Ethernet Adapters that are already configured for VLAN ID 3000.
  • Return only those adapters that are set for VLAN ID 3000.
When a VLAN ID is specified, the Shared Ethernet Adapters that are candidates to host that VLAN are included in the response. The response contains Shared Ethernet Adapters for host1. They are ent11, ent12, and ent13. The VIOS for host1 is configured for high availability. Therefore, the corresponding high availability Shared Ethernet Adapters for each primary Shared Ethernet Adapter are identified in the returned JSON entries. The response also contains a value of true for default on ent13, which indicates that the VLAN ID is configured under the Shared Ethernet Adapter at ent13. The VLAN ID of 3000 was chosen as it was configured on the add_vlan_ids of ent13. However, addl_vlan_ids are not returned in the JSON response. The do-not-use adapter is also returned because no virtual machines are currently using this host and VLAN combination.
Response Codes
  • Normal Response Code: 200
  • Error Response Codes:
    • Bad Request (400)
    • Unauthorized (401)
    • Not Found (404)
    • Invalid Environment (501)
Request URI and Header:
GET /v2.1/{tenant_id}/host-seas/{host_name}?vlanid={vlan_id}
Content-Type: application/json
Accept: application/json

Response JSON:

Table 4. Parameters in the response for viewing Shared Ethernet Adapters for a VLAN ID
Name In Type Description

host_name

body

string

Name of the host that is used by OpenStack configuration. The host name is not same as the networking concept of a host name that is used for Domain Name Service.

default

body

boolean

Whether the Shared Ethernet Adapter is serving traffic for the specified host and network pair.

network_id

body

string

The ID for the network that is used by OpenStack configuration.

sea_name

body

string

The name of the Shared Ethernet Adapter.

vswitch

body

string

Name of the virtual switch in the PowerVM hypervisor that this Shared Ethernet Adapter is connected to.

pvid

body

integer

This VLAN ID of the primary virtual ethernet adapter for this Shared Ethernet Adapter. The ID is typically a positive integer in the range 1 - 4094 inclusive.

lpar_id

body

integer

The ID for the Virtual I/O Server logical partition that owns the specified Shared Ethernet Adapter. The ID is typically a positive integer.

ha_lpar_id

body

integer

If the Shared Ethernet Adapter has a redundant adapter that is configured for high availability, this attribute is the ID for the redundant Virtual I/O Server logical partition that owns the redundant Shared Ethernet Adapter. The ID is typically a positive integer and a whole number.

ha_mode

body

string

Whether a redundant Shared Ethernet Adapter is configured for high availability on this host and network combination. Possible values are enabled or disabled.

state

body

string

Shows the availability of the Shared Ethernet Adapter.

ha_state

body

string

The state of the redundant Shared Ethernet Adapter on the redundant Virtual I/O Server.

lpar_name

body

string

Name of the Virtual I/O Server logical partition that owns the Shared Ethernet Adapter.

ha_lpar_name

body

string

Name of the redundant Virtual I/O Server logical partition that owns the redundant Shared Ethernet Adapter.

ha_sea

body

string

Name of the redundant Shared Ethernet Adapter that is configured for high availability.

Example:
{
 "host-seas": [
	{
	 "host_name": "host1",
	 "adapters": [
		{
		"default": false,
		"sea_name": "do-not-use",
		"vswitch": "do-not-use",
		"pvid": null,
		"lpar_id": 0,
		"ha_lpar_id": null,
		"ha_mode": "disabled",
		"state": "Not-Applicable",
		"ha_state": null,
		"lpar_name": null,
		"ha_lpar_name": null,
		"ha_sea": null
		},
		{
		 "default": false,
		 "sea_name": "ent11",
		 "vswitch": "ETHERNET0",
		 "lpar_id": 1,
		 "ha_lpar_id": 2,
		 "ha_mode": "enabled",
		 "pvid": 1,
		 "state": "Available",
		 "ha_state": "Available",
		 "lpar_name": "10-23C2P",
		 "ha_lpar_name": "10-24C2P",
		 "ha_sea": "ent21"
		},
		{
		 "default": false,
		 "sea_name": "ent12",
		 "vswitch": "ETHERNET0",
		 "lpar_id": 1,
		 "ha_lpar_id": 2,
		 "ha_mode": "enabled",
		 "pvid": 2,
		 "state": "Available",
		 "ha_state": "Available",
		 "lpar_name": "10-23C2P",
		 "ha_lpar_name": "10-24C2P",
		 "ha_sea": "ent22"
		},
		{
		 "default": true,
		 "sea_name": "ent13",
		 "vswitch": "ETHERNET0",
		 "lpar_id": 1,
		 "ha_lpar_id": 2,
		 "ha_mode": "enabled",
		 "pvid": 3,
		 "state": "Available",
		 "ha_state": "Available",
		 "lpar_name": "10-23C2P",
		 "ha_lpar_name": "10-24C2P",
		 "ha_sea": "ent23"
		}
	 ]
	}
 ]
}

View Shared Ethernet Adapters for a network UUID

In the following example, the user requested the following:
  • Return all Shared Ethernet Adapters for the tenant e9a2464cf00f4bc98eb2d02c534f47b7.
  • Set the default attribute for any Shared Ethernet Adapters that are associated with the network be74c86f-b528-4d8d-94f6-0e42e228c770.
The response shows that for host1 only one Shared Ethernet Adapter that is named ent12 is returned. A response also contains value of true for default on ent12, which indicates that the specified network is mapped to this host on Shared Ethernet Adapter ent12. host2 has only one Shared Ethernet Adapter named ent5. It does not have high availability configured, and therefore all the high availability attributes are null. The specified network is not configured under the Shared Ethernet Adapter ent5, and therefore the default attribute is set to true as Shared Ethernet Adapter ent5 is the only adapter that is available on host2. If there are multiple adapters, the adapter with the lowest pvid is picked.
Response Codes
  • Normal Response Code: 200
  • Error Response Codes:
    • Bad Request (400)
    • Unauthorized (401)
    • Not Found (404)
    • Invalid Environment (501)
Request URI and Header:
GET /v2.1/{tenant_id}/host-seas?network_id={network_id}
Content-Type: application/json
Accept: application/json

Response JSON:

Table 5. Parameters in the response body for viewing host Shared Ethernet Adapters for a network UUID
Name In Type Description

host_name

body

string

Name of the host that is used by OpenStack configuration. The host name is not same as the networking concept of a host name that is used for Domain Name Service.

default

body

boolean

Whether the Shared Ethernet Adapter is serving traffic for the specified host and network pair.

network_id

body

string

The ID for the network that is used by OpenStack configuration.

sea_name

body

string

The name of the Shared Ethernet Adapter.

vswitch

body

string

Name of the virtual switch in the PowerVM hypervisor that this Shared Ethernet Adapter is connected to.

pvid

body

integer

This VLAN ID of the primary virtual ethernet adapter for this Shared Ethernet Adapter. The ID is typically a positive integer in the range 1 - 4094 inclusive.

lpar_id

body

integer

The ID for the Virtual I/O Server logical partition that owns the specified Shared Ethernet Adapter. The ID is typically a positive integer.

ha_lpar_id

body

integer

If the Shared Ethernet Adapter has a redundant adapter that is configured for high availability, this attribute is the ID for the redundant Virtual I/O Server logical partition that owns the redundant Shared Ethernet Adapter. The ID is typically a positive integer and a whole number.

ha_mode

body

string

Whether a redundant Shared Ethernet Adapter is configured for high availability on this host and network combination. Possible values are enabled or disabled.

state

body

string

Shows the availability of the Shared Ethernet Adapter.

ha_state

body

string

The state of the redundant Shared Ethernet Adapter on the redundant Virtual I/O Server.

lpar_name

body

string

Name of the Virtual I/O Server logical partition that owns the Shared Ethernet Adapter.

ha_lpar_name

body

string

Name of the redundant Virtual I/O Server logical partition that owns the redundant Shared Ethernet Adapter.

ha_sea

body

string

Name of the redundant Shared Ethernet Adapter that is configured for high availability.

Example:
{
 "host-seas": [
	{
	 "host_name": "host1",
	 "adapters": [
		{
		 "default": true,
		 "sea_name": "ent12",
		 "vswitch": "ETHERNET0",
		 "lpar_id": 1,
		 "ha_lpar_id": 2,
		 "ha_mode": "enabled",
		 "pvid": 2,
		 "state": "Available",
		 "ha_state": "Available",
		 "lpar_name": "10-23C2P",
		 "ha_lpar_name": "10-24C2P",
		 "ha_sea": "ent22"
		}
	 ]
	},
	{
	 "host_name": "host2",
	 "adapters": [
		{
		 "default": true,
		 "sea_name": "ent5",
		 "vswitch": "ETHERNET0",
		 "lpar_id": 1,
		 "ha_lpar_id": null,
		 "ha_mode": "disabled",
		 "pvid": 1,
		 "state": "Available",
		 "ha_state": null,
		 "lpar_name": "15-34B9Z",
		 "ha_lpar_name": null,
		 "ha_sea": null
		}
	 ]
	}
 ]
}