Skip to main content
A newer release of this product is available.

Retrieve ports

Contributors

GET /network/ethernet/ports

Introduced In: 9.6

Retrieves a collection of ports (physical, VLAN and LAG) for an entire cluster.

  • network port show

  • network port ifgrp show

  • network port vlan show

Parameters

Name Type In Required Description

metric.timestamp

string

query

False

Filter by metric.timestamp

  • Introduced in: 9.8

metric.status

string

query

False

Filter by metric.status

  • Introduced in: 9.8

metric.throughput.total

integer

query

False

Filter by metric.throughput.total

  • Introduced in: 9.8

metric.throughput.write

integer

query

False

Filter by metric.throughput.write

  • Introduced in: 9.8

metric.throughput.read

integer

query

False

Filter by metric.throughput.read

  • Introduced in: 9.8

metric.duration

string

query

False

Filter by metric.duration

  • Introduced in: 9.8

speed

integer

query

False

Filter by speed

reachability

string

query

False

Filter by reachability

  • Introduced in: 9.8

statistics.status

string

query

False

Filter by statistics.status

  • Introduced in: 9.8

statistics.timestamp

string

query

False

Filter by statistics.timestamp

  • Introduced in: 9.8

statistics.device.link_down_count_raw

integer

query

False

Filter by statistics.device.link_down_count_raw

  • Introduced in: 9.8

statistics.device.timestamp

string

query

False

Filter by statistics.device.timestamp

  • Introduced in: 9.8

statistics.device.transmit_raw.discards

integer

query

False

Filter by statistics.device.transmit_raw.discards

  • Introduced in: 9.8

statistics.device.transmit_raw.errors

integer

query

False

Filter by statistics.device.transmit_raw.errors

  • Introduced in: 9.8

statistics.device.transmit_raw.packets

integer

query

False

Filter by statistics.device.transmit_raw.packets

  • Introduced in: 9.8

statistics.device.receive_raw.discards

integer

query

False

Filter by statistics.device.receive_raw.discards

  • Introduced in: 9.8

statistics.device.receive_raw.errors

integer

query

False

Filter by statistics.device.receive_raw.errors

  • Introduced in: 9.8

statistics.device.receive_raw.packets

integer

query

False

Filter by statistics.device.receive_raw.packets

  • Introduced in: 9.8

statistics.throughput_raw.total

integer

query

False

Filter by statistics.throughput_raw.total

  • Introduced in: 9.8

statistics.throughput_raw.write

integer

query

False

Filter by statistics.throughput_raw.write

  • Introduced in: 9.8

statistics.throughput_raw.read

integer

query

False

Filter by statistics.throughput_raw.read

  • Introduced in: 9.8

mac_address

string

query

False

Filter by mac_address

reachable_broadcast_domains.uuid

string

query

False

Filter by reachable_broadcast_domains.uuid

  • Introduced in: 9.8

reachable_broadcast_domains.name

string

query

False

Filter by reachable_broadcast_domains.name

  • Introduced in: 9.8

reachable_broadcast_domains.ipspace.name

string

query

False

Filter by reachable_broadcast_domains.ipspace.name

  • Introduced in: 9.8

type

string

query

False

Filter by type

rdma_protocols

string

query

False

Filter by rdma_protocols

  • Introduced in: 9.10

lag.distribution_policy

string

query

False

Filter by lag.distribution_policy

lag.active_ports.node.name

string

query

False

Filter by lag.active_ports.node.name

lag.active_ports.name

string

query

False

Filter by lag.active_ports.name

lag.active_ports.uuid

string

query

False

Filter by lag.active_ports.uuid

lag.mode

string

query

False

Filter by lag.mode

lag.member_ports.node.name

string

query

False

Filter by lag.member_ports.node.name

lag.member_ports.name

string

query

False

Filter by lag.member_ports.name

lag.member_ports.uuid

string

query

False

Filter by lag.member_ports.uuid

discovered_devices.remote_port

string

query

False

Filter by discovered_devices.remote_port

  • Introduced in: 9.11

discovered_devices.version

string

query

False

Filter by discovered_devices.version

  • Introduced in: 9.11

discovered_devices.remaining_hold_time

integer

query

False

Filter by discovered_devices.remaining_hold_time

  • Introduced in: 9.11

discovered_devices.name

string

query

False

Filter by discovered_devices.name

  • Introduced in: 9.11

discovered_devices.chassis_id

string

query

False

Filter by discovered_devices.chassis_id

  • Introduced in: 9.11

discovered_devices.ip_addresses

string

query

False

Filter by discovered_devices.ip_addresses

  • Introduced in: 9.11

discovered_devices.platform

string

query

False

Filter by discovered_devices.platform

  • Introduced in: 9.11

discovered_devices.capabilities

string

query

False

Filter by discovered_devices.capabilities

  • Introduced in: 9.11

discovered_devices.protocol

string

query

False

Filter by discovered_devices.protocol

  • Introduced in: 9.11

discovered_devices.system_name

string

query

False

Filter by discovered_devices.system_name

  • Introduced in: 9.11

vlan.tag

integer

query

False

Filter by vlan.tag

  • Max value: 4095

  • Min value: 0

vlan.base_port.node.name

string

query

False

Filter by vlan.base_port.node.name

vlan.base_port.name

string

query

False

Filter by vlan.base_port.name

vlan.base_port.uuid

string

query

False

Filter by vlan.base_port.uuid

enabled

boolean

query

False

Filter by enabled

node.uuid

string

query

False

Filter by node.uuid

node.name

string

query

False

Filter by node.name

mtu

integer

query

False

Filter by mtu

  • Min value: 68

uuid

string

query

False

Filter by uuid

state

string

query

False

Filter by state

interface_count

integer

query

False

Filter by interface_count

  • Introduced in: 9.11

name

string

query

False

Filter by name

broadcast_domain.uuid

string

query

False

Filter by broadcast_domain.uuid

broadcast_domain.name

string

query

False

Filter by broadcast_domain.name

broadcast_domain.ipspace.name

string

query

False

Filter by broadcast_domain.ipspace.name

fields

array[string]

query

False

Specify the fields to return.

max_records

integer

query

False

Limit the number of records returned.

return_records

boolean

query

False

The default is true for GET calls. When set to false, only the number of records is returned.

  • Default value: 1

return_timeout

integer

query

False

The number of seconds to allow the call to execute before returning. When iterating over a collection, the default is 15 seconds. ONTAP returns earlier if either max records or the end of the collection is reached.

  • Max value: 120

  • Min value: 0

  • Default value: 1

order_by

array[string]

query

False

Order results by specified fields and optional [asc

Response

Status: 200, Ok
Name Type Description

_links

_links

num_records

integer

Number of records

records

array[port]

Example response
{
  "_links": {
    "next": {
      "href": "/api/resourcelink"
    },
    "self": {
      "href": "/api/resourcelink"
    }
  },
  "num_records": 1,
  "records": {
    "_links": {
      "self": {
        "href": "/api/resourcelink"
      }
    },
    "broadcast_domain": {
      "_links": {
        "self": {
          "href": "/api/resourcelink"
        }
      },
      "ipspace": {
        "name": "ipspace1"
      },
      "name": "bd1",
      "uuid": "1cd8a442-86d1-11e0-ae1c-123478563412"
    },
    "discovered_devices": {
      "capabilities": [
        "router",
        "switch"
      ],
      "ip_addresses": [
        "192.168.100.24",
        "192.168.100.26"
      ],
      "name": "ETY-R1S4-510Q13.datacenter.example.com",
      "platform": "93180YC-EX",
      "protocol": "cdp",
      "remote_port": "FastEthernet0/12",
      "version": "Cisco Nexus Operating System (NX-OS) Software, Version 8.1"
    },
    "interface_count": 0,
    "lag": {
      "active_ports": {
        "_links": {
          "self": {
            "href": "/api/resourcelink"
          }
        },
        "name": "e1b",
        "node": {
          "name": "node1"
        },
        "uuid": "1cd8a442-86d1-11e0-ae1c-123478563412"
      },
      "distribution_policy": "port",
      "member_ports": {
        "_links": {
          "self": {
            "href": "/api/resourcelink"
          }
        },
        "name": "e1b",
        "node": {
          "name": "node1"
        },
        "uuid": "1cd8a442-86d1-11e0-ae1c-123478563412"
      },
      "mode": "multimode_lacp"
    },
    "mac_address": "01:02:03:04:05:06",
    "metric": {
      "_links": {
        "self": {
          "href": "/api/resourcelink"
        }
      },
      "duration": "PT15S",
      "status": "ok",
      "throughput": {
        "read": 200,
        "total": 1000,
        "write": 100
      },
      "timestamp": "2017-01-25 06:20:13 -0500"
    },
    "mtu": 1500,
    "name": "e1b",
    "node": {
      "_links": {
        "self": {
          "href": "/api/resourcelink"
        }
      },
      "name": "node1",
      "uuid": "1cd8a442-86d1-11e0-ae1c-123478563412"
    },
    "rdma_protocols": {
    },
    "reachability": "ok",
    "reachable_broadcast_domains": {
      "_links": {
        "self": {
          "href": "/api/resourcelink"
        }
      },
      "ipspace": {
        "name": "ipspace1"
      },
      "name": "bd1",
      "uuid": "1cd8a442-86d1-11e0-ae1c-123478563412"
    },
    "speed": 1000,
    "state": "up",
    "statistics": {
      "device": {
        "link_down_count_raw": 3,
        "receive_raw": {
          "discards": 100,
          "errors": 200,
          "packets": 500
        },
        "timestamp": "2017-01-25 06:20:13 -0500",
        "transmit_raw": {
          "discards": 100,
          "errors": 200,
          "packets": 500
        }
      },
      "status": "ok",
      "throughput_raw": {
        "read": 200,
        "total": 1000,
        "write": 100
      },
      "timestamp": "2017-01-25 06:20:13 -0500"
    },
    "type": "vlan",
    "uuid": "1cd8a442-86d1-11e0-ae1c-123478563412",
    "vlan": {
      "base_port": {
        "_links": {
          "self": {
            "href": "/api/resourcelink"
          }
        },
        "name": "e1b",
        "node": {
          "name": "node1"
        },
        "uuid": "1cd8a442-86d1-11e0-ae1c-123478563412"
      },
      "tag": 100
    }
  }
}

Error

Status: Default, Error
Name Type Description

error

error

Example error
{
  "error": {
    "arguments": {
      "code": "string",
      "message": "string"
    },
    "code": "4",
    "message": "entry doesn't exist",
    "target": "uuid"
  }
}

Definitions

See Definitions

href

Name Type Description

href

string

Name Type Description

next

href

self

href

Name Type Description

self

href

ipspace

Name Type Description

name

string

Name of the broadcast domain's IPspace

broadcast_domain

Broadcast domain UUID along with a readable name. Either the UUID or both names may be provided on input.

Name Type Description

_links

_links

ipspace

ipspace

name

string

Name of the broadcast domain, scoped to its IPspace

uuid

string

Broadcast domain UUID

discovered_devices

Name Type Description

capabilities

array[string]

The list of the capabilities of the discovered device.

chassis_id

string

Identifier associated with this specific discovered device, useful for locating the device in a data center.

ip_addresses

array[string]

The IP addresses on the discovered device.

name

string

Name of the discovered device.

platform

string

Hardware platform of the discovered device.

protocol

string

The protocol used to identify the discovered device. This can have a value of CDP or LLDP.

remaining_hold_time

integer

The number of seconds until the discovered device entry expires and is removed.

remote_port

string

The name of the remote port on the discovered device. The format is dependent on the reporting device.

system_name

string

Additional name used to identify a specific piece of equipment.

version

string

The version of the software running on the discovered device.

node

Name Type Description

name

string

Name of node on which the port is located.

active_ports

Name Type Description

_links

_links

name

string

node

node

uuid

string

member_ports

Name Type Description

_links

_links

name

string

node

node

uuid

string

lag

Name Type Description

active_ports

array[active_ports]

Active ports of a LAG (ifgrp). (Some member ports may be inactive.)

distribution_policy

string

Policy for mapping flows to ports for outbound packets through a LAG (ifgrp).

member_ports

array[member_ports]

Array of ports belonging to the LAG, regardless of their state.

mode

string

Determines how the ports interact with the switch.

throughput

The rate of throughput bytes per second observed at the interface.

Name Type Description

read

integer

Performance metric for read I/O operations.

total

integer

Performance metric aggregated over all types of I/O operations.

write

integer

Peformance metric for write I/O operations.

metric

The most recent sample of I/O metrics for the port.

Name Type Description

_links

_links

duration

string

The duration over which this sample is calculated. The time durations are represented in the ISO-8601 standard format. Samples can be calculated over the following durations:

status

string

Errors associated with the sample. For example, if the aggregation of data over multiple nodes fails, then any partial errors might return "ok" on success or "error" on an internal uncategorized failure. Whenever a sample collection is missed but done at a later time, it is back filled to the previous 15 second timestamp and tagged with "backfilled_data". "inconsistent_delta_time" is encountered when the time between two collections is not the same for all nodes. Therefore, the aggregated value might be over or under inflated. "Negative_delta" is returned when an expected monotonically increasing value has decreased in value. "inconsistent_old_data" is returned when one or more nodes do not have the latest data.

throughput

throughput

The rate of throughput bytes per second observed at the interface.

timestamp

string

The timestamp of the performance data.

node

Name Type Description

_links

_links

name

string

uuid

string

reachable_broadcast_domains

Broadcast domain UUID along with a readable name. Either the UUID or both names may be provided on input.

Name Type Description

_links

_links

ipspace

ipspace

name

string

Name of the broadcast domain, scoped to its IPspace

uuid

string

Broadcast domain UUID

receive_raw

Packet receive counters for the Ethernet port.

Name Type Description

discards

integer

Total number of discarded packets.

errors

integer

Number of packet errors.

packets

integer

Total packet count.

transmit_raw

Packet transmit counters for the Ethernet port.

Name Type Description

discards

integer

Total number of discarded packets.

errors

integer

Number of packet errors.

packets

integer

Total packet count.

device

Device-related counters for the port object. These counters are applicable at the lowest layer of the networking stack. These values can be used to calculate both transmit and receive packet and error rates by comparing two samples taken at different times and calculating the increase in counter value divided by the elapsed time between the two samples.

Name Type Description

link_down_count_raw

integer

The number of link state changes from up to down seen on the device.

receive_raw

receive_raw

Packet receive counters for the Ethernet port.

timestamp

string

The timestamp when the device specific counters were collected.

transmit_raw

transmit_raw

Packet transmit counters for the Ethernet port.

throughput_raw

Throughput bytes observed at the port object. This can be used along with delta time to calculate the rate of throughput bytes per unit of time.

Name Type Description

read

integer

Performance metric for read I/O operations.

total

integer

Performance metric aggregated over all types of I/O operations.

write

integer

Peformance metric for write I/O operations.

statistics

The real time I/O statistics for the port.

Name Type Description

device

device

Device-related counters for the port object. These counters are applicable at the lowest layer of the networking stack. These values can be used to calculate both transmit and receive packet and error rates by comparing two samples taken at different times and calculating the increase in counter value divided by the elapsed time between the two samples.

status

string

Errors associated with the sample. For example, if the aggregation of data over multiple nodes fails, then any partial errors might return "ok" on success or "error" on an internal uncategorized failure. Whenever a sample collection is missed but done at a later time, it is back filled to the previous 15 second timestamp and tagged with "backfilled_data". "inconsistent_delta_time" is encountered when the time between two collections is not the same for all nodes. Therefore, the aggregated value might be over or under inflated. "Negative_delta" is returned when an expected monotonically increasing value has decreased in value. "inconsistent_old_data" is returned when one or more nodes do not have the latest data.

throughput_raw

throughput_raw

Throughput bytes observed at the port object. This can be used along with delta time to calculate the rate of throughput bytes per unit of time.

timestamp

string

The timestamp of the throughput_raw performance data.

base_port

Name Type Description

_links

_links

name

string

node

node

uuid

string

vlan

Name Type Description

base_port

base_port

tag

integer

VLAN ID

port

Name Type Description

_links

_links

broadcast_domain

broadcast_domain

Broadcast domain UUID along with a readable name. Either the UUID or both names may be provided on input.

discovered_devices

array[discovered_devices]

Discovered devices

enabled

boolean

interface_count

integer

Number of interfaces hosted. This field is only applicable for cluster administrators. No value is returned for SVM administrators. If the node hosting a port is not healthy no value will be returned.

lag

lag

mac_address

string

metric

metric

The most recent sample of I/O metrics for the port.

mtu

integer

MTU of the port in bytes. Set by broadcast domain.

name

string

Portname, such as e0a, e1b-100 (VLAN on Ethernet), a0c (LAG/ifgrp), a0d-200 (VLAN on LAG/ifgrp), e0a.pv1 (p-VLAN, in select environments only)

node

node

rdma_protocols

array[string]

Supported RDMA offload protocols

reachability

string

Reachability status of the port. Enum value "ok" is the only acceptable value for a PATCH request to repair a port.

reachable_broadcast_domains

array[reachable_broadcast_domains]

Reachable broadcast domains.

speed

integer

Link speed in Mbps

state

string

Operational state of the port. The state is set to 'down' if the operational state of the port is down. The state is set to 'up' if the link state of the port is up and the port is healthy. The state is set to 'up' if the link state of the port is up and configured to ignore health status. The state is 'degraded' if the link state of the port is up, and the port is not healthy.

statistics

statistics

The real time I/O statistics for the port.

type

string

Type of physical or virtual port

uuid

string

Port UUID

vlan

vlan

error_arguments

Name Type Description

code

string

Argument code

message

string

Message argument

error

Name Type Description

arguments

array[error_arguments]

Message arguments

code

string

Error code

message

string

Error message

target

string

The target parameter that caused the error.