Cisco Plug-in for OpenFlow Commands

activate

To activate an application installed in a virtual services container, use the activate command in virtual services configuration mode. To deactivate the application, use the no form of this command.

activate

no activate

Syntax Description

This command has no arguments or keywords.

Command Default

The application installed in the virtual services container is not activated.

Command Modes

Virtual services configuration (config-virt-serv)

Command History

Release Modification

Cisco Plug-in for OpenFlow Release 1.0

This command was introduced.

Examples

The following example shows how an application installed in a virtual services container is activated .

Device# virtual-service install name openflow_agent package bootflash:/ofa-1.0.0-n3000-SPA-k9.ova

Note: Installing package 'bootflash:/ofa-1.0.0-n3000-SPA-k9.ova' for virtual service 'openflow_agent'. Once the install has finished, the VM may be activated. Use 'show virtual-service list' for progress.
Device# 2013 Mar  8 20:35:23 n3k-202-194-2 %$ VDC-1 %$ %VMAN-2-INSTALL_STATE: Successfully installed virtual service 'openflow_agent'
Device# configure terminal
Device(config)# virtual-service openflow_agent
Device(config-virt-serv)# activate


Related Commands

Command

Description

hardware profile openflow

Enables support and allocates resources for Cisco Plug-in for OpenFlow VLAN tagging actions on the device hardware.

show virtual-service list

Displays the status of installation of all applications on the virtual service container.

show virtual-service version

Displays the version of an application installed in the virtual service container of a device.

show virtual-service version installed

Displays the version of OpenFlow Agent application installed on the virtual services container of device.

virtual-service

Provisions an application installed in the virtual services container of a device.

virtual-service install

Installs an application on the virtual services container of a device.

controller

To configure a controller for a Cisco Plug-in for OpenFlow logical switch, use the controller command in logical switch configuration mode. To remove the controller definitions for the logical switch, use the no form of this command.

controller ipv4 ipv4-address [ port port-number ] [ vrf vrf-name ] security { none | tls } no-tls

no controller ipv4 ipv4-address [ portport-number ] [ vrf vrf-name ] security { none | tls }

Syntax Description

ipv4 ipv4-address

Specifies the IPv4 address of the controller.

port port-number

(Optional) Specifies the port through which the device must connect to the controller.

The default value is 6533.

vrf vrf-name

(Optional) Specifies the virtual routing and forwarding (VRF) instance defined for the controller.

The default value is default.

security none

(Optional) Disables Transport Layer Security (TLS) for the controller connection.

security tls

(Optional) Enables Transport Layer Security (TLS) for the controller connection.

Command Default

No controllers are defined for Cisco Plug-in for OpenFlow. If the security none keyword is not used, TLS has to be configured using the security tls command.

Command Modes

Logical switch configuration (config-ofa-switch)

Command History

Release Modification

Cisco Plug-in for OpenFlow Release 1.0

This command was introduced.

Cisco Plug-in for OpenFlow Release 1.1

This command was modified. The no-tls keyword was added.

Examples

The following example shows how the controller command is used to configure a controller for an Cisco Plug-in for OpenFlowt logical switch.

Device> enable
Device# configure terminal
Device(config)# openflow
Device(config-ofa)# switch 1
Device(config-ofa-switch)# pipeline 201

Device(config-ofa-switch)# controller ipv4 10.1.0.6 port 6666 security none
Device(config-ofa-switch)# of-port interface ethernet1/1
Device(config-ofa-switch)# end
Device# copy running-config startup-config

Related Commands

Command

Description

of-port interface (OpenFlow)

Configures an interface as a port of an Cisco Plug-in for OpenFlow logical switch

openflow

Configures Cisco Plug-in for OpenFlow.

switch (OpenFlow)

Configures Cisco Plug-in for OpenFlow logical switch used for Layer 2 switching and enter logical switch configuration mode

show openflow hardware capabilities

Displays the match and action capabilities of a device.

hardware profile openflow

To enable support and allocates resources for Cisco Plug-in for OpenFlow VLAN tagging actions on the device hardware, use the hardware profile openflow command in global configuration mode. To disable VLAN tagging actions, use the no form of this command.

hardware profile openflow

no hardware profile openflow

Syntax Description

This command has no keywords or arguments.

Command Default

VLAN tagging actions for Cisco Plug-in for OpenFlow are disabled.

Command Modes

Global configuration (config)

Command History

Release Modification

6.0(2)U1(1)

This command was introduced.

Usage Guidelines

The hardware profile openflow command must be entered before an application is installed on the virtual services container of a device.

Examples

Device# configure terminal
Device(config)# hardware profile openflow 
Device(config)# exit
Device# copy running-config startup-config
Device# reload

Related Commands

Command

Description

virtual-service install

Installs an application on the virtual services container of a device.

of-port interface (OpenFlow)

To configure an interface as a port of an Cisco Plug-in for OpenFlow logical switch, use the of-port interface command in logical switch configuration mode. To remove port configurations for an interface on an Cisco Plug-in for OpenFlow logical switch, use the no form of this command.

of-port interface interface-name

no of-port interface interface-name

Syntax Description

interface-name

Name of interface to be configured.

Command Default

No ports are configured for the Cisco Plug-in for OpenFlow logical switch.

Command Modes

Logical switch configuration (config-ofa-switch)

Command History

Release Modification

Cisco Plug-in for OpenFlow Release 1.0

This command was introduced.

Usage Guidelines

Do not abbreviate the interface type. Ensure that interface types used are spelled out clearly and typed in lowercase, as shown in the examples. For example, ethernet and port-channel. If the keyword is abbreviated or not in lowercase, the interface is not configured. Ensure that the interface name does not have a space between the interface type and number.

The Ethernet interface configured can be a member interface of a port channel.

You must configure an interface as a port of Cisco Plug-in for OpenFlow only when Cisco Plug-in for OpenFlow is active and running. When an interface is configured as a port of Cisco Plug-in for OpenFlow, the mode openflow configuration is added to the interface. This configuration is removed when the no form of of-port interface is used only if the Cisco Plug-in for OpenFlow is running and active.

Examples

The following example shows how the interface command is used to configure an interface to be a port of an Cisco Plug-in for OpenFlow logical switch.

Device> enable
Device# configure terminal
Device(config)# openflow
Device(config-ofa)# switch 1
Device(config-ofa-switch)# of-port interface ethernet1/1
Device(config-ofa-switch)# of-port interface port-channel1
Device(config-ofa-switch)# end
Device# copy running-config startup-config

Related Commands

Command

Description

controller

Configure a controller for an Cisco Plug-in for OpenFlow.

switch (OpenFlow)

Configures Cisco Plug-in for OpenFlow logical switch used for Layer 2 switching and enter logical switch configuration mode

max-backoff

To configure the maximum TCP triggered backoff interval for which Cisco Plug-in for OpenFlow can wait before retrying a connection to the controller, use the max-backoff command in logical switch configuration mode. To restore the default backoff interval, use the no form of this command.

max-backoff backoff-timer

nomax-backoff backoff-timer

Syntax Description

backoff-timer

Interval, in seconds, for which a device can wait before retrying a connection to the controller.

  • Range is from 1 to 65535.
  • Default value is 8 seconds.

Command Default

A maximum backoff of 8 seconds is configured.

Command Modes

Logical switch configuration (config-ofa-switch)

Command History

Release Modification

Cisco Plug-in for OpenFlow 1.1

This command was introduced.

Examples

The following example shows how the max-backoff command is used to configure a controller for an OpenFlow Agent logical switch.

Device> enable
Device# configure terminal
Device(config)# openflow
Device(config-ofa)# switch 1
Device(config-ofa-switch)# max-backoff 3
Device(config-ofa-switch)# end
Device# copy running-config startup-config

openflow

To configure Cisco Plug-in for OpenFlow and enter Cisco Plug-in for OpenFlow Release configuration mode, use the openflow command in global configuration mode. To remove all configurations made forCisco Plug-in for OpenFlow and exit Cisco Plug-in for OpenFlow Release configuration mode, use the no form of this command.

openflow

no openflow

Command Default

The Cisco Plug-in for OpenFlow is not configured.

Command Modes

Global configuration (config)

Command History

Release Modification

Cisco Plug-in for OpenFlow Release 1.0

This command was introduced.

Examples

The following example shows how the openflow command is used to configure the Cisco Plug-in for OpenFlow.

Device> enable
Device(config)# openflow
Device(config-ofa)# switch 1
Device(config-ofa-switch)# controller ipv4 10.1.0.6
Device(config-ofa-switch)# interface ethernet1/1
Device(config-ofa-switch)# end
Device# copy running-config startup-config

Related Commands
Related Information

Command

Description

controller

Configure a controller for an Cisco Plug-in for OpenFlow.

of-port interface (OpenFlow)

Configures an interface as a port of an Cisco Plug-in for OpenFlow logical switch

openflow

Configures Cisco Plug-in for OpenFlow.

switch (OpenFlow)

Configures Cisco Plug-in for OpenFlow logical switch used for Layer 2 switching and enter logical switch configuration mode

max-backoff

Configures an interval for which Cisco Plug-in for OpenFlow logical switch must wait before retrying a connection to the controller.

tls trust-point

Configures local and remote trust points needed for a Transport Layer Security (TLS) connection to the controller

probe-interval

Configures an interval that Cisco Plug-in for OpenFlow logical switch waits before sending a probe to query an idle connection to controller.

pipeline

Configures a pipeline.

rate-limit

Configures the rate at which packets are sent to a controller by Cisco Plug-in for OpenFlow logical switch.

pipeline

To configure a pipeline for a Cisco Plug-in for OpenFlow logical switch, use the pipeline command in logical switch configuration mode. To remove the pipeline configurations, use the no form of this command.

pipeline pipeline-id

no pipeline

Syntax Description

pipeline-id

Configures pipeline number. This value must be taken from the output of the show openflow hardware capabilities

Command Default

A pipeline is not configured.

Command Modes

Logical switch configuration (config-ofa-switch)

Command History

Release Modification

Cisco Plug-in for OpenFlow Release 1.1

This command was introduced.

Usage Guidelines

This command specifies the forwarding table used by Cisco Plug-in for OpenFlow logical switch. You can use the show openflow hardware capabilities command to view supported pipelines for a device.

Examples

The following example shows how to configure a pipeline for an Cisco Plug-in for OpenFlow logical switch for a Nexus 3000 Series device.


Device(config)# openflow
Device(config-ofa)# switch 1
! Specifies the pipeline that enables the L3 ACL Forwarding Table.
Device(config-ofa)# pipeline 201

Related Commands

Command

Description

show openflow hardware capabilities

Displays the match and action capabilities of a device.

probe-interval

To configure an interval that Cisco Plug-in for OpenFlow logical switch waits before sending a probe to query an idle connection to controller, use the probe-interval command in logical switch configuration mode. To restore the default probe interval, use the no form of this command.

probe-interval probe-interval

no probe-interval probe-interval

Syntax Description

probe-interval

Interval, in seconds, at which an idle controller connection is probed.

  • Default value is 5 seconds.
  • Range is from 5 to 65535.

Command Default

The idle controller connection is probed every 5 seconds.

Command Modes

Logical switch configuration (config-ofa-switch)

Command History

Release Modification

Cisco Plug-in for OpenFlow Release 1.1

This command was introduced.

Examples

The following example shows how the probe-interval command is used to configure a probe interval for an idle controller connection.

Device> enable
Device# configure terminal
Device(config)# openflow
Device(config-ofa)# switch 1
Device(config-ofa)# probe-interval 6
Device(config-ofa)# end
Device# copy running-config startup-config

rate-limit

To configure the rate at which packets are sent to the controller by Cisco Plug-in for OpenFlow logical switch, use the rate-limit command in the logical switch configuration mode. To remove the rate limit configurations, use the no form of this command.

rate-limit packet_in packet-rate burst number-of-packets

no rate-limit packet_in packet-rate burst number-of-packets

Syntax Description

packet_in packet-rate

Configures, in packets per seconds, the maximum rate at which packets are sent to controller.

  • Range is from 1 to 65535.
  • Default value is 0. This indicates that rate limit is disabled and that packets are sent at the maximum possible rate.
burst number-of-packets

Configures the maximum supported bursts or number of packets destined for the controller that can be stored by the logical switch at any time.

  • Range is from 1 to 65535.

Command Default

Rate limit is not configured for Cisco Plug-in for OpenFlow logical switch.

Command Modes

Logical switch configuration (config-ofa-switch)

Command History

Release Modification

Cisco Plug-in for OpenFlow Release 1.1

This command was introduced.

Examples

The following example shows how the rate-limit command is used to configure the rate limit for Cisco Plug-in for OpenFlow logical switch.

Device> enable
Device# configure terminal
Device(config)# openflow
Device(config-ofa)# switch 1
Device(config-ofa-switch)# rate-limit packet_in 30 burst 50
Device(config-ofa-switch)# end
Device# copy running-config startup-config

show openflow copyright

To display copyright and open-source information related to Cisco Plug-in for OpenFlow, use the show openflow copyright command in privileged EXEC mode.

show openflow copyright

Command Modes

Privileged EXEC (#)

Command History

Release Modification

Cisco Plug-in for OpenFlow Version 1.0

This command was introduced.

Examples

The following is sample output of the show openflow copyright command:

Device# show openflow copyright 

Cisco Nexus Operating System (NX-OS) Software
TAC support: http://www.cisco.com/tac
Copyright (c) 2002-2013, Cisco Systems, Inc. All rights reserved.
The copyrights to certain works contained in this software are
owned by other third parties and used and distributed under
license. Certain components of this software are licensed under
the GNU General Public License (GPL) version 2.0 or the GNU
Lesser General Public License (LGPL) Version 2.1. A copy of each
such license is available at
http://www.opensource.org/licenses/gpl-2.0.php and
http://www.opensource.org/licenses/lgpl-2.1.php

    

Related Commands

Command

Description

openflow

Configures Cisco Plug-in for OpenFlow.

show openflow interface

To display a list of Cisco Plug-in for OpenFlow logical switch ports, use the show openflow interface switch command in privileged EXEC mode.

show openflow interface [ interface-name ] [ switch switch-id ]

Syntax Description

interface-name

(Optional) Name of the interface. See Usage Guidelines for more details.

switch-id

(Optional) Unique switch identifier. 1 is the only permitted value.

Command Default

Displays a list of all interfaces associated with the Cisco Plug-in for OpenFlow logical switch.

Command Modes

Privileged EXEC (#)

Command History

Release Modification

Cisco Plug-in for OpenFlow Version 1.0

This command was introduced.

Usage Guidelines

Do not abbreviate the interface. Ensure that the ethernet or port-channel keywords are spelled out completely and are typed in lowercase. For example, ethernet1/1 or port-channel2. If the keyword is abbreviated or not in lowercase, the interface is not configured.

Only interfaces specified by the interface (OpenFlow) command can display an output.

Examples

The following is sample output of the show openflow interface command:

Device# show openflow interface 

Logical Switch Id: 1
  Interfaces:
    Ethernet1/11
    Ethernet1/12
    Ethernet1/13
    Ethernet1/2
    Ethernet1/24
    Ethernet1/25
    Ethernet1/3
    Ethernet1/4
    port-channel2
 
Device# show openflow interface ethernet1/2 switch 1 

Logical Switch Id: 1
  Interface: ethernet1/2
Device# show openflow interface switch 1 

  Interfaces:
    Ethernet1/11
    Ethernet1/12
    Ethernet1/13
    Ethernet1/2
    Ethernet1/24
    Ethernet1/25
    Ethernet1/3
    Ethernet1/4
    port-channel2

Related Commands

Command

Description

of-port interface (OpenFlow)

Configures an interface as a port of an Cisco Plug-in for OpenFlow logical switch

switch (OpenFlow)

Configures Cisco Plug-in for OpenFlow logical switch used for Layer 2 switching and enter logical switch configuration mode

show openflow switch

To display information related to an Cisco Plug-in for OpenFlow logical switch, use the show openflow switch command in privileged EXEC mode.

show openflow switch [ switch-id ]

Syntax Description

switch-id

(Optional) Cisco Plug-in for OpenFlow logical switch ID. Only the value 1 is permitted.

Command Modes

Privileged EXEC (#)

Command History

Release Modification

Cisco Plug-in for OpenFlow Release 1.0

This command was introduced.

Examples

The following is sample output of the show openflow switch command on Nexus 3000 Series Device.

Device# show openflow switch 1

Logical Switch Context
  Id: 1
  Switch type: Forwarding
  Pipeline id: 201
  Signal version: Openflow 1.0
  Data plane: secure
  Table-Miss default: NONE
  Config state: no-shutdown
  Working state: enabled
  Rate limit (packet per second): 0
  Burst limit: 0
  Max backoff (sec): 8
  Probe interval (sec): 5
  TLS local trustpoint name: not configured
  TLS remote trustpoint name: not configured
  Stats coll. period (sec): 5
  Logging flow changes: Disabled
  OFA Description:
    Manufacturer: Cisco Systems, Inc.
    Hardware: N3K-C3064PQ V01
    Software: 6.0(2)U2(1) of_agent 1.1.0_fc1
    Serial Num: SSI15200QD8
    DP Description: n3k-200-141-3:sw1
  OF Features:
    DPID:0001547fee00c2a0
    Number of tables:1
    Number of buffers:256
    Capabilities: FLOW_STATS TABLE_STATS PORT_STATS
    Actions: OUTPUT SET_VLAN_VID STRIP_VLAN SET_DL_SRC SET_DL_DST
  Controllers:
    1.1.1.1:6653, Protocol: TLS, VRF: s
  Interfaces:
    Ethernet1/1
    Ethernet1/7
Table 1 show openflow switch Field Descriptions

Field

Description

Id

Cisco Plug-in for OpenFlow logical switch identifier.

Switch type

Type of switch. The possible values are as follows:

  • Forwarding—Forwards packets to controller.

Pipeline ID

Identifier used for pipeline.

Layer

Network layer on which the switch operates.

Data plane: secure

Security levels of the data plane.

Table-Miss default:

Fallback state of switch.

Signal version

OpenFlow version.

Config state:

The switch is in a configuration state of no shutdown.

Working state:

The switch is in a working state.

TLS

Transport Layer Security (TLS) capability and trust points.

Rate Limit

Rate limit.

Burst Limit

Burst limit.

Maximum Backoff

Maximum backoff.

Probe interval

Probe interval.

Stats coll. period (sec):

Time period at which stats are collected.

Logging Flow changes

Manufacturer: Cisco Systems, Inc.

Manufacturer of the Cisco Plug-in for OpenFlow software.

Hardware

Device on which the Cisco Plug-in for OpenFlow is installed.

Software:

Operating system running on the device.

Serial Num:

Serial Number of the device.

DP Description

Data Path description used by the controller to identify the device.

DPID

Data Path identifier used by the controller to identify the device.

Number of tables

Number of flows defined for the device on the controller.

Number of buffers

Number of buffers allocated to the device.

Capabilites:

Match capabilities available on this device.

Actions:

Actions available on this device.

Controllers:

192.168.1.31:8005, Protocol: TCP, VRF: default

192.168.94.173:6633, Protocol: TCP, VRF: management

Controllers connected to this device, port number used, protocol used for between the controller and the device, and the VRF on which the controller is defined.

Interfaces:

List of interfaces defined for the device.

show openflow switch controller

To display information about controllers connected to an Cisco Plug-in for OpenFlow switch, use the show openflow switch controller command in privileged EXEC mode.

show openflow switch [ switch-id | [ controllers [ stats ] ] ]

Syntax Description

switch-id

(Optional) Cisco Plug-in for OpenFlow logical switch identifier.

stats

(Optional) Cisco Plug-in for OpenFlow Displays controller based statistics.

Command Modes

Privileged EXEC (#)

Command History

Release Modification

Cisco Plug-in for OpenFlow Version 1.0

This command was introduced.

Usage Guidelines

A device can connect to up to eight controllers.

Examples

The following is sample output of the show openflow switch 1 controllers command:

Device# show openflow switch 1 controllers 

Logical Switch Id: 1
Total Controllers: 1
  Controller: 1
    10.168.1.31:7777
    Protocol: tcp
    VRF: default
    Connected: Yes
    Role: Other
    state:ACTIVE
    sec_since_connect:31474

The following is sample output of the show openflow switch 1 controllers command:

Device# show openflow switch 1 controllers 

Logical Switch Id: 1
Total Controllers: 1
  Controller: 1
    10.86.201.162:8050
    Protocol: tcp
    VRF: management
    Local Trustpoint: disabled
    Remote Trustpoint: disabled
    Connected: Yes
    Role: Master
    state:ACTIVE
    sec_since_connect:36844
Table 2 show openflow switch controllers Field Description

Field

Descriptions

Logical Switch Id: 1

Indicates the unique switch identifier.

Total Controllers: 1

Indicates the total number of controllers connected to this device.

Controller: 1

Indicates the controller identifier.

192.168.1.31:7777

Indicates the IP address of the controller and the controller port used for the connection.

Protocol: TCP

Indicates the protocol used for controller-device communication.

VRF: default

Indicates the virtual routing and forwarding (VRF) instance of which the controller is part of.

Local Trustpoint

Status of local trustpoint

Remote Trustpoint

Status of remote trustpoint

Connected: Yes

Indicates whether the switch is connected to the controller.

Role: Other

Indicates the role of the controller.

  • Master—Full access, at most one
  • Slave - Read-only access
  • Other— Default role, full access

state:ACTIVE

Indicates the state of the controller. Possible values are given below:

  • ACTIVE—The controller is active.
  • BACKOFF—The controller is in a state of backoff.

sec_since_connect

Indicates the number of seconds that have elapsed since the connector connected to the device.


Related Commands

Command

Description

controller

Configure a controller for an Cisco Plug-in for OpenFlow.

switch (OpenFlow)

Configures Cisco Plug-in for OpenFlow logical switch used for Layer 2 switching and enter logical switch configuration mode

show openflow switch flows

To display a list of flows defined for Cisco Plug-in for OpenFlow logical switch and related information, use the show openflow switch flows command in privileged EXEC mode.

show openflow switch switch-id flows [ configured | controller | default | fixed | pending | pending-del ] [ brief | summary ]

Syntax Description

switch-id

(Optional) Cisco Plug-in for OpenFlow logical switch identifier.

configured

(Optional) Displays information related to configured flows.

controller

(Optional) Displays flow information related to controllers.

default

(Optional) Displays default information related to flows.

fixed

(Optional) Displays information related to fixed flows.

fixed

(Optional) Displays information related to fixed flows.

pending

(Optional) Displays information related to pending flows.

pending-del

(Optional) Displays brief information related to flows pending deletion.

summary

(Optional) Displays a summary of information related to flows.

Command Modes

Privileged EXEC (#)

Command History

Release Modification

Cisco Plug-in for OpenFlow Version 1.0

This command was introduced.

Usage Guidelines

The flows displayed are configured by the controller that is connected to Cisco Plug-in for OpenFlow logical switch on the device.

Examples

The following is sample output of the show openflow switch 1 flows command:

Device# show openflow switch 1 flows

Logical Switch Id: 1

Total flows: 1
 1
  Rule:              ip,dl_vlan=99 
  Actions:           strip_vlan,output:1
  Priority:          0x8000
  Table:             0
  Cookie:            0x466c6f7732
  Duration:          176.383s
  Number of packets: 0
  Number of bytes:   0

Device# show openflow switch 1 flows

Total flows: 2
Flow: 1
  Rule:              ip,dl_vlan=99 
  Actions:           strip_vlan,output:1
  Priority:          0x8000
  Table:             0
  Cookie:            0x466c6f7732
  Duration:          96.359s
  Number of packets: 0
  Number of bytes:   0

Flow: 2
  Rule:              ip,in_port=2,dl_vlan=50 
  Actions:           output:1
  Priority:          0x8000
  Table:             0
  Cookie:            0x1
  Duration:          95.504s
  Number of packets: 0
  Number of bytes:   

Table 3 show openflow switch flows Field Descriptions

Field

Descriptions

Rule

List of rules defined for the flow. This is related to the match capabilities of the device. The possible rules are listed below:

  • dl_vlan=vlan-id—Packet has the given VLAN ID.
  • in_port—Packet has arrived on the given input port.
  • ip—Packet uses the IP protocol.
  • nw_dst—Packet is destined for a given destination address prefix.
  • nw_src—Packet is from a given source address prefix.
  • nw_tos—Packet has the given IP ToS bits set.
  • tp_dst—Packet is destined for the given TCP/UDP destination port.
  • tp_src—Packet is from for the given TCP/UDP source port.

Actions

List of actions to be defined if a packet matches the flow (abides by the rules defined in the flow). The possible actions are:

  • drop—Drop.
  • mod_vlan_vid—Rewrite VLAN ID.
  • output:number—Output to one or more physical ports.
  • output:6533—Output to the controller.
  • strip_vlan—Strip the VLAN ID.
  • mod_dl_src—Modify the source MAC address.
  • mod_dl_dst—Modify the destination MAC address.

If multiple actions are associated with a flow, they are processed in the order specified. The output action should be the last action in the action list. Any action after the output action is not supported.

Priority

Priority of the flow.

Table

Table number.

Cookies

Cookies defined for the flow.

Duration

Duration, in seconds, for which the flow was executed.

Number of packets: 0

Number of packets/bytes that matched the flow.

Number of bytes: 0

Number of bytes exchanged for the flow.


Related Commands

Command

Description

controller

Configure a controller for an Cisco Plug-in for OpenFlow.

switch (OpenFlow)

Configures Cisco Plug-in for OpenFlow logical switch used for Layer 2 switching and enter logical switch configuration mode

show openflow switch ports

To display the mapping between the Cisco Plug-in for OpenFlow logical switch ports and the device’s physical interfaces, use the show openflow switch ports command in privileged EXEC mode.

showopenflow switch [ switch-id [ ports ] ]

Syntax Description

switch-id

(Optional) Cisco Plug-in for OpenFlow logical switch identifier.

ports

(Optional) Displays send and receive statistics for each port defined for an Cisco Plug-in for OpenFlow logical switch.

Command Modes

Privileged EXEC (#)

Command History

Release Modification

Cisco Plug-in for OpenFlow Version 1.0

This command was introduced.

Examples

The following is sample output of the show openflow switch 1 ports command:

Device# show openflow switch 1 ports

Logical Switch Id: 1
Port  Interface Name    Config-State   Link-State     Features
   2  Ethernet1/2       PORT_UP        LINK_UP        10MB-FD
   3  Ethernet1/3       PORT_UP        LINK_DOWN      100MB-HD AUTO_NEG
   4  Ethernet1/4       PORT_UP        LINK_UP        10MB-FD
  11  Ethernet1/11      PORT_UP        LINK_UP        1GB-FD
  12  Ethernet1/12      PORT_UP        LINK_UP        1GB-FD
  13  Ethernet1/13      PORT_UP        LINK_UP        1GB-FD
  24  Ethernet1/24      PORT_UP        LINK_DOWN      1GB-HD AUTO_NEG
  25  Ethernet1/25      PORT_UP        LINK_DOWN      1GB-HD AUTO_NEG
 321  port-channel2     PORT_UP        LINK_DOWN      100MB-HD AUTO_NEG
Table 4 show openflow switch 1 ports Field Description table

Field

Descriptions

Logical Switch Id: 1

Indicates the unique switch identifier.

Port

Indicates port numbers assigned for an interface by Cisco Plug-in for OpenFlow logical switch.

Interface Name

Indicates the name of the physical interface.

Config-State

Indicates the configured state of a port or interface.

Link-State

Indicates the physical link state of a port or interface.

Features

Indicates the configured speed or duplex settings. The values of the output are read as follows:

  • 10MB-FD— Displays that the port has been set to 10–Mbps speed and full duplex.
  • 10MB-HD—Displays that the port has been set to 10–Mbps speed and half duplex.
  • 100MB-HD AUTO_NEG— Displays that the port has been auto-negotiated to 100–Mbps speed and half duplex.
  • 1GB-FD— Displays that the port has been set to 1–Gbps speed and full duplex.
  • 1GB-HD AUTO_NEG—Displays that the port has been auto-negotiated to 1–Gbps speed and half duplex.

Related Commands

Command

Description

of-port interface (OpenFlow)

Configures an interface as a port of an Cisco Plug-in for OpenFlow logical switch

switch (OpenFlow)

Configures Cisco Plug-in for OpenFlow logical switch used for Layer 2 switching and enter logical switch configuration mode

show openflow switch stats

To display send and receive statistics for each port defined for the Cisco Plug-in for OpenFlow logical switch, use the show openflow switch stats command in privileged EXEC mode.

show openflow switch switch-id stats

Syntax Description

switch-id

(Optional) Cisco Plug-in for OpenFlow logical switch identifier.

Command Modes

Privileged EXEC (#)

Command History

Release Modification

Cisco Plug-in for OpenFlow Version 1.0

This command was introduced.

Examples

The following is sample output of the show openflow switch 1 stats command:

Device# show openflow switch 1 stats 

Logical Switch Id: 1

Total ports 9 

  Port 4: rx pkts=8570, bytes=2459590, drop=0, errs=0,
tx pkts=8585, bytes=2461949, drop=0, errs=0,

  Port 2: rx pkts=0, bytes=0, drop=0, errs=0,
tx pkts=0, bytes=0, drop=0, errs=0, 
  
Total tables 1
  Table 0: classifier
  Wildcards = 0x3fffff
  Max entries = 1000000
  Active entries = 0
  Number of lookups = 0
  Number of matches = 0

The following is sample output of the show openflow switch 1 stats command:

Device# show openflow switch 1 stats 

Logical Switch Id: 1

Total ports: 1

 Port 4: rx pkts=8570, bytes=2459590, drop=0, errs=0,
tx pkts=8585, bytes=2461949, drop=0, errs=0,

 Port 2: rx pkts=0, bytes=0, drop=0, errs=0,
tx pkts=0, bytes=0, drop=0, errs=0, 
Total tables: 1
  Table 0: classifier
  Wildcards = 0x3fffff
  Max entries =   1500
  Active entries = 0
  Number of lookups = 0
  Number of matches = 0

Table 5 Field Description table for show openflow openflow_agent switch 1 stats

Field

Descriptions

Logical Switch Id: 1

Indicates the unique switch identifier.

Total ports: 1

Indicates the total number of ports defined for the switch.

Port: N

Indicates the port number.

rx pkts=0, bytes=0, errs=0

Indicates the number of packets and bytes received by the port and the number of errors generated while receiving data.

tx pkts=0, bytes=376480

Indicates number of packets and bytes sent by the port.

Total tables

Indicates the total number of tables defined for the device on the controller.

Table 0: classifier

Indicates the name of the table.

Wildcards

Indicates the wildcard character.

Max entries

Indicates the maximum number of flow entries defined in the table.

Active entries

Indicates the number of active flow entries in the table.

Number of lookups

Indicates the number of table lookups that have occurred.

Number of matches

Indicates the number of matches that have occurred for the flow entries in the table.


Related Commands

Command

Description

controller

Configure a controller for an Cisco Plug-in for OpenFlow.

switch (OpenFlow)

Configures Cisco Plug-in for OpenFlow logical switch used for Layer 2 switching and enter logical switch configuration mode

show openflow hardware capabilities

To display the match and action capabilities of a device, use the show openflow hardware capabilities command in privileged EXEC mode.

show openflow hardware capabilities

Syntax Description

This command has no arguments or keywords.

Command Modes

Privileged EXEC (#)

Command History

Release Modification

Cisco Plug-in for OpenFlow Release 1.0

This command was introduced.

Usage Guidelines

This command displays the list of match and action capabilities supported on this device. The controller connected to this device can define flows using this match criteria and can associate actions to be executed when packets match the flow criteria. The match and action criteria supported for various devices are given below.

Examples

The following is sample output for the show openflow hardware capabilities command.

The following is sample output for Nexus 3000 Series device.

Device# show openflow hardware capabilities

     Pipeline ID: 201

    Flow table ID: 0

    Match Capabilities                  Match Types
    ------------------                  -----------
    ethernet type                       mandatory
    VLAN ID                             optional
    VLAN priority code point            optional
    IP DSCP                             optional
    IP protocol                         optional
    IPv4 source address                 lengthmask
    IPv4 destination address            lengthmask
    source port                         optional
    destination port                    optional
    in port (virtual or physical)       optional

    Actions:
        output to: specified interface, use normal forwading, controller
        set: set eth source mac, set eth destination mac, set vlan id
        pop: pop vlan tag
        other actions: drop packet



  Pipeline ID: 202

    Flow table ID: 0

    Match Capabilities                  Match Types
    ------------------                  -----------
    ethernet type                       mandatory
    VLAN ID                             optional
    VLAN priority code point            optional
    IP DSCP                             optional
    IP protocol                         optional
    IPv4 source address                 lengthmask
    IPv4 destination address            lengthmask
    source port                         optional
    destination port                    optional
    in port (virtual or physical)       optional

    Actions:
        output to: specified interface, use normal forwading, controller
        set: set eth source mac, set eth destination mac, set vlan id
        pop: pop vlan tag
        other actions: drop packet



    Flow table ID: 1

    Match Capabilities                  Match Types
    ------------------                  -----------
    ethernet mac destination            mandatory
    VLAN ID                             mandatory

    Actions:
        output to: specified interface
        other actions: drop packet

Table 6 show openflow hardware capabilities Field Descriptions

Command

Description

Pipeline ID

Pipeline to be configured for using the table.

Flow table ID

Table number in a logical switch.

Min Timer

Minimum time at which polling for statistics occurs.

Max Timer

Maximum time at which polling for statistics occurs.

Match Capabilities

Displays a list of match capabilities that can be defined for this device. The definitions of the different match criteria can be found in the OpenFlow 1.0 specification.

Match Types

Displays the type of match criteria. The match types and their meaning are as followed:

  • required—This criteria must be defined for a flow.
  • optional—This criteria may be defined for a flow. It is optional.
  • prefix—This criteria is an IP prefix.

Actions

Displays a list of actions that can be defined for this device, if a packet matches the flow criteria. The actions can be as follows:

  • output to—Output the packet to the specified location.
  • set—Set the specified parameter for a packet.
  • pop—Remove the specified parameter for a packet.
  • other actions—Execute the specified action. The actions can be as follows:
    • drop—Drop the packet.

Stats

Displays a list of parameters for which statistics are collected.

Others: packet out

Sending of packets to an output location (packet out) is supported by this Cisco Plug-in for OpenFlow.


Related Commands
Related Information

Command

Description

hardware profile openflow

Enables support and allocates resources for Cisco Plug-in for OpenFlow VLAN tagging actions on the device hardware.

switch (OpenFlow)

To configure Cisco Plug-in for OpenFlow logical switch used for Layer 2 switching and enter logical switch configuration mode, use the switch command in Cisco Plug-in for OpenFlow Release configuration mode. To remove the Cisco Plug-in for OpenFlow logical switch configurations, use the no form of this command.

switch logical-switch-id

no switch logical-switch-id

Syntax Description

logical-switch-id

Specifies a numerical ID for the logical switch.

  • Only logical switch ID 1 is supported.

Command Default

Cisco Plug-in for OpenFlow logical switch is not defined.

Command Modes

Cisco Plug-in for OpenFlow Release configuration (config-ofa)

Command History

Release Modification

Cisco Plug-in for OpenFlow Version 1.0

This command was introduced.

Examples

The following example describes how the switch command is used in configuring Cisco Plug-in for OpenFlow logical switch.

Device> enable
Device# configure terminal
Device(config)# openflow
Device(config-ofa)# switch 1
Device(config-ofa-switch)# controller ipv4 10.1.0.6
Device(config-ofa-switch)# interface ethernet1/1
Device(config-ofa-switch)# end
Device# copy running-config startup-config

Related Commands
Related Information

Command

Description

controller

Configure a controller for an Cisco Plug-in for OpenFlow.

of-port interface (OpenFlow)

Configures an interface as a port of an Cisco Plug-in for OpenFlow logical switch

openflow

Configures Cisco Plug-in for OpenFlow.

switch (OpenFlow)

Configures Cisco Plug-in for OpenFlow logical switch used for Layer 2 switching and enter logical switch configuration mode

max-backoff

Configures an interval for which Cisco Plug-in for OpenFlow logical switch must wait before retrying a connection to the controller.

tls trust-point

Configures local and remote trust points needed for a Transport Layer Security (TLS) connection to the controller

probe-interval

Configures an interval that Cisco Plug-in for OpenFlow logical switch waits before sending a probe to query an idle connection to controller.

pipeline

Configures a pipeline.

rate-limit

Configures the rate at which packets are sent to a controller by Cisco Plug-in for OpenFlow logical switch.

shutdown (OpenFlow)

To disable an Cisco Plug-in for OpenFlow logical switch, use the shutdown command in logical switch configuration mode. To re-enable the Cisco Plug-in for OpenFlow logical switch, use the no form of this command.

shutdown

no shutdown

Syntax Description

This command has no arguments or keywords.

Command Default

The Cisco Plug-in for OpenFlow logical switch is enabled.

Command Modes

Logical switch configuration (config-ofa-switch)

Command History

Release Modification

Cisco Plug-in for OpenFlow Version 1.0

This command was introduced.

Examples

The following example describes how the shutdown command is used to disable an Cisco Plug-in for OpenFlow logical switch.

Device> enable
Device# configure terminal
Device(config)# openflow
Device(config-ofa)# switch 1
Device(config-ofa-switch)# shutdown
Device(config-ofa-switch)# end
Device# copy running-config startup-config

tls trust-point

To configure local and remote trust points needed for a Transport Layer Security (TLS) connection to the controller, use the tls trust-point command in logical switch configuration mode.

tls trust-point local local-trust-point-name remote remote-trust-point-name

no tls trust-point local local-trust-point-name remote remote-trust-point-name

Syntax Description

local local-trust-point-name

Configures the local trust point.

remote remote-trust-point-name

Configures the remote trust point.

Command Default

TLS is enabled for controller connections, but TLS trust points are not configured.

Command Modes

Logical switch configuration (config-ofa-switch)

Command History

Release Modification

Cisco Plug-in for OpenFlow Release 1.1

This command was introduced.

Usage Guidelines

This command does not set up the TLS connection and only configures the trust points.

If this command is not configured, TLS must be disabled in order for the controller connection to work using the no-tls keyword of the controller command. Otherwise the controller connection fails.

Examples

The following example shows how the tls trust-point command is used to configure a TLS connection to a controller.

Device> enable
Device# configure terminal
Device(config)# openflow
Device(config-ofa)# switch 1
Device(config-ofa-switch)# controller ipv4 10.1.1.1
Device(config-ofa-switch)# tls trust-point local XXX remote YYY
Device(config-ofa-switch)# end
Device# copy running-config startup-config

The following example shows how TLS must be disabled if the tls trust-point command is not used.

Device> enable
Device# configure terminal
Device(config)# openflow
Device(config-ofa)# switch 1
Device(config-ofa-switch)# controller ipv4 10.1.1.1 security none
Device(config-ofa-switch)# end
Device# copy running-config startup-config

Related Commands

Command

Description

controller

Configure a controller for an Cisco Plug-in for OpenFlow.