OpenFlow Commands

Use these commands to configure OpenFlow, which lets an OpenFlow Controller manage the switch.

Note: OpenFlow commands are supported on the M4350 series switches but not on the M4250 series switches.

The OpenFlow feature enables the switch to be managed by a centralized OpenFlow Controller using the OpenFlow protocol.

openflow enable

M4350

This command enables the OpenFlow feature.

Default Disabled
Format openflow enable
Mode Global Config

no openflow enable

This command disables the OpenFlow feature.

Format no openflow enable
Mode Global Config

openflow static-ip

M4350

This command sets the IPv4 address that must be used for the OpenFlow feature. The static IP address is applied only when the static IP mode is enabled. The switch must have an operational IP interface with the specified address for the static IP address that must be used for the OpenFlow feature.

Default 0.0.0.0
Format openflow static-ip ip-address
Mode Global Config

no openflow static-ip

This command resets the IPv4 address for the OpenFlow feature to 0.0.0.0.

Format no openflow static-ip
Mode Global Config

openflow controller

M4350

This command sets an IP address to which the switch must establish an OpenFlow Controller connection. You can set twenty such IP addresses, but each command invocation can specify a maximum of five IP addresses and one type of connection mode (TCP or SSL). If you do not specify the IP port, the default IP port number (6633) is used. The default connection mode is SSL. The controller table that you can configure with this command is used by the switch in OpenFlow 1.0 or 1.3 modes.

Default None
Format openflow controller ip-address [ip-port] [ssl | tcp]
Mode Global Config
Parameter Description
ip-address Up to five IP addresses (separated by a space) to which the switch must establish an OpenFlow Controller connection.
ip-port The IP port that must be used for an OpenFlow Controller connection. If you do not specify the IP port, the default IP port number (6633) is used.
ssl or tcp The connection mode (TCP or SSL). The default is SSL.

no openflow controller

This command deletes a specific OpenFlow Controller IP address or all OpenFlow Controller IP addresses. If you delete a specific IP address and do not state the IP port number, all entries for the specified IP address are deleted.

Format no openflow controller {ip-address [ip-port] | all}
Mode Global Config

openflow default-table

M4350

This command configures the hardware table that is used as the target for flows installed by an OpenFlow 1.0 Controller, which is not enhanced to handle multiple hardware tables. The full-match or layer-2-match option is applicable only when the OpenFlow variant is set to OpenFlow 1.0:

  • full-match: Inserts the flow into the OpenFlow 1.0 match table, which can match all OpenFlow 1.0 fields.
  • layer-2-match: Inserts the flow into the MAC Forwarding table, which can match the MAC addresses, VLANs, and ingress ports.
Default full-match
Format openflow default-table {full-match | layer-2-match}
Mode Global Config

openflow ip-mode

M4350

This command directs the OpenFlow feature to use the configured IP address.

Default OpenFlow assigns itself an IP address
Format openflow ip-mode {auto | static | serviceport}
Mode Global Config
Parameter Description
auto The network IP address is used.
static The static IP address is used.
serviceport The service port IP address is used.

no openflow ip-mode

This command directs the OpenFlow feature to automatically assign itself an IP address.

Format no openflow ip-mode
Mode Global Config

openflow passive-mode

M4350

This command enables OpenFlow passive mode.

Default Disabled
Format openflow passive-mode
Mode Global Config

no openflow passive-mode

This command disables OpenFlow passive mode.

Format no openflow passive-mode
Mode Global Config

openflow variant

M4350

This command sets the OpenFlow version (variant): OpenFlow 1.0 or OpenFlow 1.3.

Default OpenFlow 1.3
Format openflow variant {openflow10 | openflow13}
Mode Global Config

clear openflow ca-cert

M4350

This command clears the Certificate Authority certificates that are used for validating the OpenFlow controllers from the switch. This command automatically disables and reenables the OpenFlow feature. The new SSL certificates are reloaded from the OpenFlow controller on the first connection to the controller, or you can manually load them with a copy command.

Format clear openflow ca-cert
Mode Privileged EXEC

show openflow

M4350

This command displays the status and configuration information of OpenFlow.

Format show openflow
Mode Privileged EXEC
Term Definition
Administrative Mode The OpenFlow administrative mode that is specified by the openflow enable command.
Administrative Status The operational status of OpenFlow. Although OpenFlow can be administratively enabled, it could be operationally disabled.
Disable Reason If OpenFlow is operationally disabled, the reason why OpenFlow is disabled.
IP Address The IPv4 address that is assigned to OpenFlow. If no IP address is assigned, the status is None.
IP Mode The IP mode that is specified by the openflow ip-mode command. The IP mode can be Auto, Static, or ServicePort IP.
Static IP Address The static IP address that is specified by the openflow static-ip command.
OpenFlow Variant The OpenFlow protocol variant (mode). The OpenFlow variant can be OpenFlow 1.0 or OpenFlow 1.3.
Default Table The hardware table that is used as the target for flows that are installed by an OpenFlow 1.0 controller that is not enhanced to handle multiple hardware tables.
Passive Mode The OpenFlow passive mode that is specified by the openflow passive-mode command.

Command example:

CODE
(NETGEAR Switch) #show openflow

Administrative Mode............................ Enable
Administrative Status.......................... Disabled
Disable Reason................................. No-Suitable-IP-Interface
IP Address..................................... None
IP Mode................................. Auto
Static IP Address.............................. 10.1.1.1
OpenFlow Variant............................... OpenFlow 1.0
Default Table.................................. layer-2-match
Passive Mode................................... Enable

Command example:

CODE
(NETGEAR Switch) #show openflow

Administrative Mode............................ Enable
Administrative Status.......................... Enabled
Disable Reason................................. None
IP Address..................................... 10.27.65.64
IP Mode................................. Auto
Static IP Address.............................. 10.1.1.1
OpenFlow Variant............................... OpenFlow 1.0
Passive Mode................................... Enable

show openflow configured controller

M4350

This command displays a list of configured OpenFlow controllers. The switch communicates with these controllers only when the OpenFlow variant (mode) is 1.0 or 1.3.

Format show openflow configured controller
Mode Privileged EXEC
Term Definition
IP Address The IPv4 address of the controller.
IP Port The IPv4 port number on the switch for the controller connection.
Connection Mode The SSL or TCP Controller Connection mode.
Role The role of the controller: Initiator, Equal, Responder.

Command example:

CODE
(NETGEAR Switch) #show openflow configured controller

IP Address    IP Port  Connection Mode  Role
------------  -------  ---------------  ----
172.21.4.217  6633     SSL              Master

show openflow installed flows

M4350

This command displays the list of configured flows on the switch.

Format show openflow installed flows [dest_ip ip-address | dest_ip_port 1–65535 | dest_mac macaddr | dscp 0–63 | ether_type 0–0xFFFF | ingress_port slot/port | ip_proto 0–255 | priority 1–65535 | source_ip ip-address | source_ip_port 1–65535 | source_mac macaddr | table {4 | 24 | 25 | 60} | vlan 1–4093 | vlan_prio 0–7]
Mode Privileged EXEC
Parameter Definition
dest_ip The IP address of the destination.
dest_ip_port The port number of the destination in the range 1–65535.
dest_mac The MAC address of the destination.
dscp The DSCP value in the range 0–63.
ether_type The EtherType value in the range 0–0xFFFF.
ingress_port The slot and port for the incoming traffic.
ip_proto The IP protocol in the range 0–255.
priority The priority of the flow. This is a value in the range 1–65535.
source_ip The IP address of the source.
source_ip_port The port number of the source in the range 1–65535.
source_mac The MAC address of the source.
table The table number, which can be 4, 24, 25, or 60.
vlan The VLAN in the range 1–4093.
vlan_prio The VLAN priority in the range 0–7.

The following table describes the terms in the command output.

Term Definition
Flow Type The type of flow. For example, 1.0 or Layer 2 match.
Flow Table The hardware table in which the flow is installed.
Flow Priority The priority of the flow in relation to other flows.
Match Criteria The match criteria that are specified by the flow.
Ingress Port The port on which the flow is active.
Action The action that is specified by the flow.
Idle The time since the flow was active.
Installed in hardware Whether the flow is installed in the hardware.

Command example:

CODE
(NETGEAR Switch) #show openflow installed flows

Flow 00000000 type "1DOT0"

Match criteria:
Flow table              24 : Priority                 1
Ingress port           0/0
Actions:
Action:               Drop
Status:
Duration                 2 : Idle                     0 : installed in hardware    1

Flow 00000000 type "1DOT0"

Match criteria:
Flow table              24 : Priority               102
Ingress port           0/0 : Ether type            88CC
Actions:Status:
Duration                55 : Idle                    45 : installed in hardware    1

Command example:

CODE
(NETGEAR Switch) # show openflow installed flows

Flow 000000E1 type "1DOT3"

Match criteria:
Flow table         60 : Priority           10
Ingress port      0/1 : Src MAC  00:00:02:37:38:01 : Dst MAC  00:00:18:37:22:01
VLAN                1 : VLAN prio           1 : Ether type          0x0800
IP proto           17 : Src IP     100.0.0.225 : Dst IP        192.0.0.225
Src IP port         1 : Dst IP port         1 : TOS                32(DSCP: 8)

Actions:
New Src IP         3.3.3.3 : New SrcIP Mask 255.255.255.255 : New Dst IP         4.4.4.4
New DstIP Mask 255.255.255.255 : Egress port       0/1
Status:
Duration            5 : Idle                2 : installed in hardware  1

Flow 000001F9 type "1DOT3"

Match criteria:
Flow table         60 : Priority           10
Ingress port      0/1 : Src MAC  00:00:1A:38:38:01 : Dst MAC  00:00:30:38:22:01
VLAN                1 : VLAN prio           1 : Ether type          0x0800
IP proto           17 : Src IP     100.0.1.249 : Dst IP        192.0.1.249
Src IP port         1 : Dst IP port         1 : TOS                32(DSCP: 8)

Actions:
Egress port       0/1
Status:
Duration            2 : Idle                0 : installed in hardware  1

show openflow installed groups

M4350

This command displays the list of configured groups on the switch.

Format show openflow installed groups
Mode Privileged EXEC

The following table displays the most significant fields in the command output.

Term Definition
Group Type The type of group. For example, “Indirect,” “All,” “Select,” or another type of group.
Group Id The unique ID of the group.
Reference Count The group reference count is used only for “Indirect” groups. This count indicates how many “Select” groups are referring to the current “Indirect” group.
Duration The time since the group was created.
Bucket Count The number of buckets in the group.
Reference Group Id References the “Indirect” group ID. This field is used for a “Select” group only.

Command example:

CODE
(NETGEAR Switch) # show openflow installed groups

Max Indirect Group Entries.........................................  1234
Current Indirect Group Entries in database.........................  123

Max All Group Entries..............................................  1234
Current All Group Entries in database..............................  123

Max Select Group Entries...........................................  1234
Current Select Group Entries in database...........................  123

Group Id 12345678 type "Indirect"
=================================

Ref Count              1 : Duration            8 : Bucket Count     1

Bucket Entry List:
------------------

Bucket Index         25 : Output Port            1
Src MAC  00:00:00:00:00:AB : Dst MAC  00:00:00:00:00:CD
VLAN              101 : Reference Group Id      NA

Group Id 23456789 type "All"
============================
Ref Count              NA : Duration            10 : Bucket Count     2

Bucket Entry List:
------------------
Bucket Index         26 : Output Port            2
Src MAC              NA : Dst MAC               NA
VLAN                102 : Reference Group Id    NA

Bucket Index         27 : Output Port            3
Src MAC              NA : Dst MAC               NA
VLAN                103 : Reference Group Id    NA

Group Id 34567890 type "Select"
===============================
Ref Count              NA : Duration            10 : Bucket Count     3

Bucket Entry List:
------------------

Bucket Index         28 : Output Port           NA
Src MAC              NA : Dst MAC               NA
VLAN                 NA : Reference Group Id    12345678

Bucket Index         29 : Output Port           NA
Src MAC              NA : Dst MAC               NA
VLAN                 NA : Reference Group Id    12345678

Bucket Index         30 : Output Port           NA
Src MAC              NA : Dst MAC               NA
VLAN                 NA : Reference Group Id    12345678

show openflow table-status

M4350

This command displays the supported OpenFlow tables and reports usage information for the tables.

Format show openflow table-status {openflow10 | openflow13}
Mode Privileged EXEC
Term Definition
Flow Table The OpenFlow table identifier. The range is 0–255.
Flow Table Name The name of the table.
Flow Table Description The description of the table.
Maximum Size The platform-dependent maximum size for the flow table.
Number of Entries The total number of entries in the table, including the entries that are pending to be deleted.
Hardware Entries The number of entries that are currently inserted into the hardware.
Software-Only Entries The number of entries that are not installed in the hardware. This number includes entries that are pending to be inserted, entries that cannot be inserted because of a missing interface, and entries that cannot be inserted because the table is full.
Waiting for Space Entries The number of entries that are not in the hardware because the attempt to insert them failed.
Flow Insertion Count The total number of flows that were added to the table since the switch powered up.
Flow Deletion Count The total number of flows that were deleted from the table since the switch powered up.
Insertion Failure Count The total number of hardware insertion attempts that were rejected because of lack of space since the switch powered up.

Command example:

CODE
(NETGEAR Switch) #show openflow table-status openflow10

Flow Table...............................1
Flow Table Name.......................... Forwarding Database
Maximum Size.............................64
Number of Entries........................8
Hardware Entries.........................7
Software-Only Entries....................1
Waiting for Space Entries................0
Flow Insertion Count.....................1
Flow Deletion Count......................0
Insertion Failure Count..................0
Flow Table Description:
The forwarding database maps non-multicast MAC addresses and the ports on which these
addresses are located.

Command example:

CODE
(NETGEAR Switch) #show openflow table-status openflow13

Flow Table..................................... 60
Flow Table Name................................ Openflow 1.3
Maximum Size................................... 1920
Number of  Entries............................. 0
Hardware Entries............................... 0
Software-Only Entries.......................... 0
Waiting for Space Entries...................... 0
Flow Insertion Count........................... 0
Flow Deletion Count............................ 0
Insertion Failure Count........................ 0
Flow Table Description......................... The Openflow 1.3 table matches on the
packet layer-2 header, including DA-MAC, SA-MAC, VLAN, Vlan priority ether type; layer-3
header, including SRC-IP, DST-IP, IP protocol, IP-TOS; layer-4 header, including UDP/TCP
source and dest port, ICMP type, and code; SRC-IPv6, DST_IPv6, IPv6 Flow Label,ECN,
ICMPv6 type and code, source L4 Port for TCP / UDP / SCTP and input port including
physical port and LAG port.