21-OpenFlow Command Reference

HomeSupportReference GuidesCommand ReferencesH3C S9825 & S9855 Switch Series Command References-R932x-6W10021-OpenFlow Command Reference
Table of Contents
Related Documents
01-OpenFlow commands
Title Size Download
01-OpenFlow commands 214.41 KB

OpenFlow commands

active instance

Use active instance to activate an OpenFlow instance.

Use undo active instance to deactivate an OpenFlow instance.

Syntax

active instance

undo active instance

Default

An OpenFlow instance is not activated.

Views

OpenFlow instance view

Predefined user roles

network-admin

Usage guidelines

After an OpenFlow instance is created or modified, use this command to activate or reactivate the instance to make the instance take effect. After an OpenFlow instance is reactivated, it disconnects from all controllers, clears the deployed flow tables, updates the capability set, and then reconnects to controllers.

Examples

# Activate OpenFlow instance 1.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] active instance

classification

Use classification to configure the OpenFlow instance mode.

Use undo classification to restore the default.

Syntax

classification { global | vlan vlan-id [ mask vlan-mask ] [ loosen ] }

undo classification

Default

The OpenFlow instance mode is not configured.

Views

OpenFlow instance view

Predefined user roles

network-admin

Parameters

global: Specifies the global mode.

vlan: Specifies the VLAN mode.

vlan-id: Specifies a VLAN ID in the range of 1 to 4094.

vlan-mask: Specifies a VLAN mask in the range of 0 to 4095. The default value is 4095.

loosen: Specifies the loosen mode. If the loosen mode is used, a port belongs to the OpenFlow instance when VLANs associated with the OpenFlow instance overlap with the port's allowed VLANs. If you do not specify the loosen mode, a port belongs to an OpenFlow instance only when VLANs associated with the OpenFlow instance are within the port's allowed VLAN list.

Usage guidelines

The VLANs to be associated are calculated by a bitwise AND operation on the specified VLAN ID and mask. The VLAN mask supports non-contiguous 1s and ignores all 0 bits. To view the associated VLANs, use the display openflow instance command.

If you execute this command multiple times, the most recent configuration takes effect.

Examples

# Enable the VLAN mode for OpenFlow instance 1 and associate OpenFlow instance 1 with VLANs determined by VLAN ID 255 and VLAN mask 7.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] classification vlan 255 mask 7

Related commands

display openflow instance

controller address

Use controller address to specify a controller for an OpenFlow switch and configure the main connection to the controller.

Use undo controller address to delete the main connection to the specified controller.

Syntax

controller controller-id address { ip ipv4-address | ipv6 ipv6-address } [ port port-number ] [ local address { ip local-ipv4-address | ipv6 local-ipv6-address } [ port local-port-number ] ] [ vrf vrf-name ]

undo controller controller-id address

Default

An OpenFlow instance does not have a main connection to a controller.

Views

OpenFlow instance view

Predefined user roles

network-admin

Parameters

controller-id: Specifies a controller by its ID in the range of 0 to 63.

ip ipv4-address: Specifies the IPv4 address of the controller.

ipv6 ipv6-address: Specifies the IPv6 address of the controller.

port port-number: Sets the port number used by the controller to establish TCP connections to the OpenFlow switch. The value range for the port number is 1 to 65535. The default value is 6633.

local address: Specifies the source IP address used to establish TCP connections to the controller. When multiple routes are available between a controller and a switch, you can use this keyword to configure a source IP address for the switch. When the switch restarts or an active/standby switchover occurs, the switch can use the original route to reconnect to the controller without selecting a new route.

ip local-ipv4-address: Specifies the source IPv4 address.

ipv6 local-ipv6-address: Specifies the source IPv6 address.

port local-port-number: Specifies the source port number in the range of 1 to 65535. If you do not specify this option, the system automatically assigns a source port number for establishing the main connection to the controller.

vrf vrf-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. If you do not specify a VRF name, the controller is in the public network.

Usage guidelines

You can specify multiple controllers for an OpenFlow switch. The OpenFlow channel between the OpenFlow switch and each controller can have only one main connection.

The OpenFlow switch uses the main connection to a controller to exchange control messages with the controller to perform the following operations:

·     Receive flow table entries or data from the controller.

·     Report information to the controller.

As a best practice, configure a unicast IP address for a controller. An OpenFlow switch might fail to establish a connection with the controller that does not use a unicast IP address.

The main connection must be a reliable TCP connection. The OpenFlow switch uses the main connection to a controller to exchange control messages with the controller to perform the following operations:

·     Receive flow table entries or data from the controller.

·     Report information to the controller.

Examples

# Specify controller 1 for OpenFlow instance 1. The controller's IP address is 1.1.1.1 and the port number is 6666.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] controller 1 address ip 1.1.1.1 port 6666

controller connect interval

Use controller connect interval to set the reconnection interval.

Use undo controller connect interval to restore the default.

Syntax

controller connect interval interval

undo controller connect interval

Default

The reconnection interval is 60 seconds.

Views

OpenFlow instance view

Predefined user roles

network-admin

Parameters

interval: Specifies the reconnection interval in the range of 10 to 120 seconds.

Examples

# Set the reconnection interval to 10 seconds for OpenFlow instance 1.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] controller connect interval 10

controller echo-request interval

Use controller echo-request interval to set the connection detection interval for an OpenFlow switch.

Use undo controller echo-request interval to restore the default.

Syntax

controller echo-request interval interval

undo controller echo-request interval

Default

The connection detection interval is 5 seconds for an OpenFlow switch.

Views

OpenFlow instance view

Predefined user roles

network-admin

Parameters

interval: Specifies the connection detection interval in the range of 1 to 10 seconds.

Examples

# Set the connection detection interval to 10 seconds for OpenFlow instance 1.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] controller echo-request interval 10

controller mode

Use controller mode to set the controller connection mode for an OpenFlow instance.

Use undo controller mode to restore the default.

Syntax

controller mode { multiple | single }

undo controller mode

Default

The controller connection mode is multiple.

Views

OpenFlow instance view

Predefined user roles

network-admin

Parameters

multiple: Specifies the multiple mode. In multiple mode, the OpenFlow switch simultaneously connects to all controllers. If one or more controllers become invalid or disconnected, the OpenFlow switch continues to exchange messages with the rest of the controllers.

single: Specifies the single mode. In single mode, the OpenFlow switch connects to only one controller at a time. When communication with the current controller fails, the OpenFlow instance connects to the controller with the lowest ID among the rest controllers.

Examples

# Set all controllers of OpenFlow instance 1 to operate in single mode.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] controller mode single

datapath-id

Use datapath-id to set the datapath ID for an OpenFlow instance.

Use undo datapath-id to restore the default.

Syntax

datapath-id id

undo datapath-id

Default

The datapath ID of an OpenFlow instance contains the instance ID and the bridge MAC address of the device. The lower 16 bits are the instance ID and the upper 48 bits are the bridge MAC address of the device.

Views

OpenFlow instance view

Predefined user roles

network-admin

Parameters

id: Specifies the datapath ID for the OpenFlow instance, in the range of 1 to ffffffffffffffff in hexadecimal format.

Usage guidelines

The datapath ID uniquely identifies an OpenFlow instance.

Examples

# Set the datapath ID to 123456 for OpenFlow instance 1.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] datapath-id 123456

data-plane enable

Use data-plane enable to enable the OpenFlow data plane forwarding feature.

Use undo data-plane enable to disable the OpenFlow data plane forwarding feature.

Syntax

data-plane enable

undo data-plane enable

Default

The OpenFlow data plane forwarding feature is disabled.

Views

OpenFlow instance view

Predefined user roles

network-admin

Usage guidelines

In a forwarding-control separated network, you must enable this feature to deliver the following mappings to the controller:

·     Site-facing interface (where an Ethernet service instance is created) to VXLAN mappings.

·     VXLAN-DCI tunnel to VXLAN mappings.

Based on these mappings, the controller generates flow entries and then deploys the flow entries to the switch.

You can execute this command only on an OpenFlow instance that is not activated.

Examples

# Enable the OpenFlow data plane forwarding feature.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] data-plane enable

default table-miss permit

Use default table-miss permit to configure the default action of table-miss flow entries to forward packets to the normal pipeline.

Use undo default table-miss permit to restore the default.

Syntax

default table-miss permit

undo default table-miss permit

Default

The default action of a table-miss flow entry is to drop packets.

Views

OpenFlow instance view

Predefined user roles

network-admin

Examples

# Configure the default action of table-miss flow entries to forward packets to the normal pipeline.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] default table-miss permit

description

Use description to configure a description for an OpenFlow instance.

Use undo description to restore the default.

Syntax

description text

undo description

Default

An OpenFlow instance does not have a description.

Views

OpenFlow instance view

Predefined user roles

network-admin

Parameters

text: Specifies a description, a case-sensitive string of 1 to 255 characters.

Examples

# Configure the description as test-desc for OpenFlow instance 1.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] description test-desc

display openflow

Use display openflow to display controller information for an OpenFlow instance.

Syntax

display openflow instance instance-id controller [ controller-id ]

Views

Any view

Predefined user roles

network-admin

network-operator

Parameters

instance-id: Specifies an OpenFlow instance by its ID in the range of 1 to 4094.

controller-id: Specifies a controller by its ID in the range of 0 to 63. If you do not specify a controller ID, this command displays information about all controllers for an OpenFlow instance.

Examples

# Display controller information for OpenFlow instance 100.

<Sysname> display openflow instance 100 controller

Instance 1 controller information:

 Reconnect interval : 60 (s)

 Echo interval      : 5  (s)

 

 Controller ID           : 1

 Controller IP address   : 192.168.49.49

 Controller port         : 6633

 Local IP address        : 192.0.0.1

 Local port              : 5566

 Controller role         : Equal

 Connect type            : TCP

 Connect state           : Established

 Packets sent            : 9

 Packets received        : 9

 SSL policy              : --

 VRF name                : --

Table 1 Command output

Field

Description

Reconnect interval

Reconnection interval (in seconds) for an OpenFlow instance to reconnect to all controllers.

Echo interval

Connection detection interval (in seconds) at which an OpenFlow instance sends an echo request message to all controllers.

Controller IP address

IP address of the controller.

Controller port

TCP port number of the controller.

Local IP address

Source IP address of the controller that is connected to the OpenFlow instance.

Local port

Source TCP port number of the current controller.

Controller role

Role of the controller:

·     Equal—The controller has the same mode as other controllers that are specified for the OpenFlow instance.

·     Master—The controller is the master controller for the OpenFlow instance.

·     Slave—The controller is a subordinate controller for the OpenFlow instance.

If the controller is not configured with any role, this field displays two hyphens (--).

Connect type

Type of the connection between the OpenFlow instance and the controller: TCP.

Connect state

State of the connection between the OpenFlow instance and the controller: Idle or Established.

Packets sent

Number of packets that have been sent to the controller.

Packets received

Number of packets that have been received from the controller.

SSL policy

This field is not supported in the current software version.

Name of the SSL client policy used for SSL connections.

If no SSL client policy is configured, this field displays two hyphens (--).

VRF name

Name of the MPLS L3VPN to which the controller belongs.

If no MPLS L3VPN instance is configured, this field displays two hyphens (--).

display openflow flow-table

Use display openflow flow-table to display flow table information for an OpenFlow instance.

Syntax

display openflow instance instance-id flow-table [ table-id ]

Views

Any view

Predefined user roles

network-admin

network-operator

Parameters

instance-id: Specifies an OpenFlow instance by its ID in the range of 1 to 4094.

table-id: Specifies a flow table by its ID in the range of 0 to 254. If you do not specify a flow table ID, the command displays information about all flow tables for the specified OpenFlow instance.

Examples

# Display information about all flow tables for OpenFlow instance 100.

<Sysname> display openflow instance 100 flow-table

Instance 100 flow table information:

 

Table 0 information:

 Table type: MAC-IP, flow entry count: 1, total flow entry count: 2

 

MissRule (default) flow entry information:

 cookie: 0x0, priority: 0, hard time: 0, idle time: 0, flags: reset_counts

 |no_pkt_counts|no_byte_counts, byte count: --, packet count: --

Match information: any

Instruction information:

 Write actions:

  Drop

 

Flow entry 1 information:

 cookie: 0x0, priority: 1, hard time: 0, idle time: 0, flags: none,

 byte count: --, packet count: --

Match information:

 Ethernet destination MAC address: 0000-0000-0001

 Ethernet destination MAC address mask: ffff-ffff-ffff

 VLAN ID: 100, mask: 0xfff

Instruction information:

 Write actions:

  Output interface: HGE1/0/4

 Write metadata/mask: 0x0000000000000001/0xffffffffffffffff

 Goto table: 1

 

Table 1 information:

 Table type: Extensibility, flow entry count: 1, total flow entry count: 2

 

MissRule (default) flow entry information:

 cookie: 0x0, priority: 0, hard time: 0, idle time: 0, flags: none,

 byte count: 300, packet count: 60

Match information: any

Instruction information:

 Write actions:

  Drop

 

Flow entry 1 information: (Not effective)

 cookie: 0x0, priority: 0, hard time: 0, idle time: 0, flags: flow_send_rem

 |check_overlap, byte count: 8, packet count: 1

Match information:

 Input interface: HGE1/0/3

 Ethernet source MAC address: 0000-0000-0001

 Ethernet source MAC address mask: ffff-ffff-ffff

Instruction information:

 Set meter: 100

 Apply actions:

  Output interface: HGE1/0/4

 Write actions:

  Output interface: Controller, send length: 128 bytes

Table 2 Command output

Field

Description

Table information

Information about the flow table.

Table type

Type of the flow table: MAC-IP or Extensibility.

flow entry count

Number of flow entries deployed by the controller.

total flow entry count

Total number of flow entries in the table.

MissRule (default) Flow entry information

Information about the table-miss flow entry. default indicates that the entry is issued by the system by default.

Flow entry information

Information about the flow entry. If the flow entry does not take effect, this field displays Not effective.

cookie

Cookie ID of the flow entry.

priority

Priority of the flow entry. The larger the value, the higher the priority.

hard time

Hard timeout of the flow entry, in seconds. The flow entry is removed when the timer times out, whether or not the flow entry matches any data stream.

If the flow entry has no hard timeout, the field displays 0.

idle time

Idle timeout of the flow entry, in seconds. The flow entry is removed if the flow entry does not match any data stream during the idle time.

If the flow entry has no idle timeout, the field displays 0.

flags

Flags that the flow entry includes:

·     flow_send_rem—Sends a flow removed message when the flow entry is removed or expires.

·     check_overlap—Checks for overlapping flow entries.

·     reset_counts—Resets flow table counters.

·     no_pkt_counts—Does not count packets.

·     no_byte_counts—Does not count bytes.

If the flow entry does not include any flags, this field displays none.

byte count

Number of bytes that have matched the flow entry.

packet count

Number of packets that have matched the flow entry.

Last modified time

Time when the flow entry was modified for the last time.

Match information

Contents of the match field of the flow entry (see Table 3).

Instruction information

Contents of the instruction set of the flow entry:

·     Clear actions—Immediately clears all actions in the action set.

·     Apply actions—Immediately applies specified actions in the action set.

·     Write actions—Writes specified actions into the current action set.

For more information about actions, see Table 4.

Table 3 Match field types

Field

Mask field

Description

Input interface

N/A

Ingress port (see Table 5).

Physical input interface

N/A

Ingress physical port.

Ethernet destination MAC address

Ethernet destination MAC address mask

Ethernet destination MAC address and mask.

Ethernet source MAC address

Ethernet source MAC address mask

Ethernet source MAC address and mask.

Ethernet type

N/A

Ethernet type of the OpenFlow packet payload.

VLAN ID

Mask

VLAN ID and mask.

IP protocol

N/A

IPv4 or IPv6 protocol number.

IPv4 source address

Mask

IPv4 source address and mask.

IPv4 destination address

Mask

IPv4 destination address and mask.

TCP source port

Mask

TCP source port and mask.

TCP destination port

Mask

TCP destination port and mask.

UDP source port

Mask

UDP source port and mask.

UDP destination port

Mask

UDP destination port and mask.

IPv6 source address

IPv6 source address mask

Source IPv6 address and mask.

IPv6 destination address

IPv6 destination address mask

Destination IPv6 address and mask.

ICMPv6 type

N/A

ICMPv6 type.

ICMPv6 code

N/A

ICMPv6 code.

Tunnel ID

Mask

This field is not supported on the S9855 switches.

Metadata and mask that are associated with a logical port.

Output interface

N/A

Output port.

Table 4 Actions

Field

Description

Drop

Drops the matched packet. This action is not defined in the OpenFlow specifications.

Output interface

Sends the packet through a specific port. For more information about ports, see Table 5.

Set field

Modifies a field of the packet.

Table 5 Ports

Port name

Ingress port

Output port

Description

Normal

Not supported.

Supported.

Processing the packet by using the normal forwarding process.

Flood

Not supported.

Supported.

This field is not supported on the S9855 switches.

Flooding the packet.

All

Not supported.

Supported.

This field is not supported on the S9855 switches.

Forwarding the packet out of all ports.

Controller

Supported.

Supported.

Sending the packet to the controller.

Local

Supported.

Supported.

Sending the packet to the local CPU.

port name

Supported.

Supported.

Valid physical or logical port on the switch. The S9855 and S9825 switch series does not support VXLAN tunnel interfaces in the current software version, and the S9855 switch series does not support aggregate interfaces.

display openflow instance

Use display openflow instance to display detailed information about an OpenFlow instance.

Syntax

display openflow instance [ instance-id ]

Views

Any view

Predefined user roles

network-admin

network-operator

Parameters

instance-id: Specifies an OpenFlow instance by its ID in the range of 1 to 4094. If you do not specify an instance ID, this command displays detailed information about all OpenFlow instances.

Examples

# Display detailed information about all OpenFlow instances.

<Sysname> display openflow instance

Instance 100 information:

 

Configuration information:

 Description   : test-desc

 Active status : Active

 Inactive configuration:

  None

 Active configuration:

  Classification: VLAN, loosen mode, total VLANs(1)

   2

  In-band management VLAN, total VLANs(0)

   Empty VLAN

  Connect mode: Multiple

  MAC address learning: Disabled

  TCP DSCP value: 10

  Flow table:

   Table ID(type): 0(MAC-IP), count: 0

  Flow-entry max-limit: 65535

  Datapath ID: 0x0000001234567891

  Default table-miss: Drop

  Forbidden port: None

  Qinq Network: Disabled

  TCP connection backup: Enabled

  Data-plane: Disabled

Port information:

 HundredGigE1/0/3

Active channel information:

 Controller 1 IP address: 192.168.49.49  port: 6633

 Controller 2 IP address: 192.168.43.49  port: 6633

Table 6 Command output

Field

Description

Configuration information

Information about the configuration.

Description

Description of the OpenFlow instance.

Active status

OpenFlow instance status: Active or Inactive.

Inactive configuration

Inactive configuration for the OpenFlow instance.

Active configuration

Active configuration for the OpenFlow instance.

Classification: VLAN, total VLANs

VLANs that are associated with the OpenFlow instance and the total number of these VLANs.

Classification: Port

The port mode is enabled.

loose mode

The loose mode is used.

In-band management VLAN, total VLANs

Inband management VLANs and the total number of them.

Connect mode

Connection mode of the controller:

·     Single—The OpenFlow instance connects to only one controller at a time.

·     Multiple—The OpenFlow instance can simultaneously connect to multiple controllers.

MAC address learning

Whether MAC address learning is disabled: Enabled or Disabled.

TCP DSCP value

DSCP value for OpenFlow packets.

Flow table

Flow table information for the OpenFlow instance.

Table ID(type)

Type of the flow table: MAC-IP or Extensibility.

count

Total number of flow entries included in the current flow table.

Flow-entry max-limit

Maximum number of flow entries allowed in the extensibility flow table.

Datapath ID

Datapath ID of the OpenFlow instance.

Default table-miss

Default action of the table-miss flow entry: Permit or Drop.

Forbidden port

Type of interfaces that are forbidden to be reported to the controller:

·     L3 Physical Interface—Layer 3 Ethernet interfaces and Layer 3 aggregate interfaces.

·     VLAN interface.

·     Virtual Switch Interface.

Qinq Network

This field is not supported in the current software version.

Whether the OpenFlow instance is enabled to perform QinQ tagging for double-tagged packets passing an extensibility flow table:

·     Disabled.

·     Enabled.

TCP connection backup

Whether OpenFlow connection backup is enabled:

·     Disabled.

·     Enabled.

Data-plane

Whether the OpenFlow data plane forwarding feature is enabled:

·     Disabled.

·     Enabled.

Port information

Ports that have been added to the OpenFlow instance.

Active channel information

Information about active channels.

IP address

IP address of the controller configured for the OpenFlow instance.

Port

TCP port number that is used to connect to the controller.

Failopen mode

Connection interruption mode for the OpenFlow instance:

·     Standalone.

·     Secure.

display openflow summary

Use display openflow summary to display brief OpenFlow instance information.

Syntax

display openflow instance summary

Views

Any view

Predefined user roles

network-admin

network-operator

Examples

# Display brief OpenFlow instance information.

<Sysname> display openflow summary

Fail-open mode: Se - Secure mode, Sa - Standalone mode, Sm - Smart mode

 

ID    Status    Datapath-ID         Channel    Table-num  Port-num  Reactivate

1     Active    0x0000000100001221  Connected  2          8         N

10    Inactive  -                   -          -          -         -

4094  Active    0x00000ffe00001221  Failed(Sa) 2          0         N

Table 7 Command output

Field

Description

ID

OpenFlow instance ID.

Status

Activation status of the OpenFlow instance:

·     Active—The OpenFlow instance has been activated.

·     Inactive—The OpenFlow instance has not been activated.

Datapath-ID

Datapath ID of the OpenFlow instance.

If the OpenFlow instance is not activated, this field displays a hyphen (-).

Channel

Status of the OpenFlow channel to the controller:

·     Connected—An OpenFlow channel has been established.

·     Failed(Se)—The OpenFlow channel is disconnected from the controller, and the OpenFlow instance uses the secure connection interruption mode.

·     Failed(Sm)—The OpenFlow channel is disconnected from the controller, and the OpenFlow instance uses the smart connection interruption mode.This field is not supported in the current software version.

·     Failed(Sa)—The OpenFlow channel is disconnected from the controller, and the OpenFlow instance uses the standalone connection interruption mode.

If the OpenFlow instance is not activated, this field displays a hyphen (-).

Table num

Number of flow tables that the OpenFlow instance has.

If the OpenFlow instance is not activated, this field displays a hyphen (-).

Port num

Number of ports that belong to the OpenFlow instance.

If the OpenFlow instance is not activated, this field displays a hyphen (-).

Reactivate

Whether the OpenFlow instance is required to be reactivated. N indicates the configuration is unchanged and the OpenFlow instance is not required to be reactivated.

If the OpenFlow instance is not activated, this field displays a hyphen (-).

fail-open mode

Use fail-open mode to set the connection interruption mode for an OpenFlow switch.

Use undo fail-open mode to restore the default.

Syntax

fail-open mode { secure | standalone }

undo fail-open mode

Default

The connection interruption mode is secure.

Views

OpenFlow instance view

Predefined user roles

network-admin

Parameters

secure: Configures the OpenFlow switch to use flow tables for traffic forwarding after it is disconnected from all controllers. The OpenFlow switch does not remove unexpired flow entries.

standalone: Configures the OpenFlow switch to use the normal forwarding process after it is disconnected from all controllers.

Examples

# Set the connection interruption mode to standalone for OpenFlow instance 1.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] fail-open mode standalone

flow-entry max-limit

Use flow-entry max-limit to set the maximum number of entries for an extensibility flow table on an OpenFlow switch.

Use undo flow-entry max-limit to restore the default.

Syntax

flow-entry max-limit limit-value

undo flow-entry max-limit

Default

The device supports a maximum of 65535 flow entries in each extensibility flow table.

Views

OpenFlow instance view

Predefined user roles

network-admin

Parameters

limit-value: Specifies the maximum number of flow entries for an extensibility flow table. The value range is 1 to 65535.

Usage guidelines

If the number of extensibility flow table entries deployed from a controller to an OpenFlow switch exceeds the maximum, the switch returns a failure message to the controller.

Examples

# Configure OpenFlow instance 1 to have a maximum of 256 entries in each extensibility flow table.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] flow-entry max-limit 256

flow-log disable

Use flow-log disable to disable logging for successful flow table modifications.

Use undo flow-log disable to restore the default.

Syntax

flow-log disable

undo flow-log disable

Default

Logging for successful flow table modifications is enabled.

Views

OpenFlow instance view

Predefined user roles

network-admin

Examples

# Disable logging for successful flow table modifications for OpenFlow instance 1.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] flow-log disable

flow-table

Use flow-table to configure the flow table type and the flow table ID for an OpenFlow instance.

Use undo flow-table to restore the default.

Syntax

flow-table { mac-ip mac-ip-table-id | extensibility extensibility-table-id }*

undo flow-table

Default

An OpenFlow instance has an extensibility flow table with ID 0.

Views

OpenFlow instance view

Predefined user roles

network-admin

Parameters

mac-ip mac-ip-table-id: Specifies a MAC-IP flow table by its ID in the range of 0 to 254.

extensibility extensibility-table-id: Specifies an extensibility flow table by its ID in the range of 0 to 254.

Usage guidelines

If you execute this command multiple times, the most recent configuration takes effect.

The ID you enter for an extensibility flow table must be larger than the ID for an MAC-IP flow table.

In the current software version, the device does not support matching and processing IPv6 packets by using MAC-IP flow entries.

Examples

# Create a MAC-IP flow table with ID 0 and an extensibility flow table with ID 1 for OpenFlow instance 1.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] flow-table mac-ip 0 extensibility 1

forbidden packet-in arp controller

Use forbidden packet-in arp controller to configure controllers to which ARP packets are forbidden to be reported.

Use undo forbidden packet-in arp controller to restore the default.

Syntax

forbidden packet-in arp controller controller-id-list

undo forbidden packet-in arp controller [ controller-id-list ]

Default

No controllers to which ARP packets are forbidden to be reported are configured.

Views

OpenFlow instance view

Predefined user roles

network-admin

Parameters

controller-id-list: Specifies a space-separated list of a maximum of 10 controller items. Each item specifies a controller ID or a range of controller IDs in the form of controller-id1 to controller-id2. The value range for controller IDs is 0 to 63. The value for the controller-id2 argument must be equal to or greater than the value for the controller-id1 argument. If you do not specify the controller-id-list argument, the undo form of this command restores all configuration of this feature to the default.

Examples

# Forbid the device not to report ARP packets to controller 0.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] forbidden packet-in arp controller 0

forbidden port

Use forbidden port to forbid an OpenFlow instance from reporting ports of the specified types to controllers.

Use undo forbidden port to restore the default.

Syntax

forbidden port { l3-physical-interface | vlan-interface | vsi-interface } *

undo forbidden port

Default

No port types are prevented from being reported to the controllers. All ports that belong to an OpenFlow instance are reported to the controllers.

Views

OpenFlow instance view

Predefined user roles

network-admin

Parameters

l3-physical-interface: Specifies Layer 3 Ethernet interfaces and Layer 3 aggregate interfaces that belong to an OpenFlow instance.

vlan-interface: Specifies VLAN interfaces that belong to an OpenFlow instance.

vsi-interface: Specifies virtual switch instance (VSI) interfaces that belong to an OpenFlow instance.

Examples

# Forbid OpenFlow instance 1 from reporting VLAN interfaces that belong to the OpenFlow instance to controllers.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] forbidden port vlan-interface

in-band management vlan

Use in-band management vlan to configure inband management VLANs for an OpenFlow instance.

Use undo in-band management vlan to restore the default.

Syntax

in-band management vlan vlan-id-list

undo in-band management vlan

Default

No inband management VLANs are configured for an OpenFlow instance.

Views

OpenFlow instance view

Predefined user roles

network-admin

Parameters

vlan-id-list: Specifies a space-separated list of up to 10 VLAN items. Each item specifies a VLAN by its ID or a range of VLANs in the form of start-vlan-id to end-vlan-id. The VLAN ID is in the range of 1 to 4094.

Usage guidelines

Traffic in inband management VLANs is forwarded in the normal forwarding process for an OpenFlow instance to establish secure connections to controllers.

Examples

# Configure VLAN 10 as the inband management VLAN for OpenFlow instance 1.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] in-band management vlan 10

mac-ip dynamic-mac aware

Use mac-ip dynamic-mac aware to configure an OpenFlow instance to support matching the dynamic MAC addresses in the query and deletion flow entry instructions sent from controllers.

Use undo mac-ip dynamic-mac aware to restore the default.

Syntax

mac-ip dynamic-mac aware

undo mac-ip dynamic-mac aware

Default

An OpenFlow instance ignores the dynamic MAC addresses in the query and deletion flow entry instructions sent from controllers.

Views

OpenFlow instance view

Predefined user roles

network-admin

Usage guidelines

This command takes effect only on MAC-IP flow tables.

Examples

# Configure OpenFlow instance 1 to support matching the dynamic MAC addresses in the query and deletion flow entry instructions sent from controllers.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] mac-ip dynamic-mac aware

openflow instance

Use openflow instance to create an OpenFlow instance and enter its view, or enter the view of an existing OpenFlow instance.

Use undo openflow instance to remove an OpenFlow instance.

Syntax

openflow instance instance-id

undo openflow instance instance-id

Default

No OpenFlow instances exist.

Views

System view

Predefined user roles

network-admin

Parameters

instance-id: Specifies an OpenFlow instance by its ID in the range of 1 to 4094.

Examples

# Create OpenFlow instance 1 and enter OpenFlow instance view.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1]

openflow shutdown

Use openflow shutdown to shut down an interface by OpenFlow.

Use undo openflow shutdown to restore the default.

Syntax

openflow shutdown

undo openflow shutdown

Default

An interface is not shut down by OpenFlow.

Views

Interface view

Predefined user roles

network-admin

Usage guidelines

After an interface is shut down by OpenFlow, the Current state field displays OFP DOWN in the display interface command output.

To bring up an interface shut down by OpenFlow, use either of the following methods:

·     Use the undo openflow shutdown command on the interface.

·     Use the controller to send port modification messages to the interface.

Examples

# Shut down HundredGigE 1/0/1 by OpenFlow.

<Sysname> system-view

[Sysname] interface hundredgige 1/0/1

[Sysname-HundredGigE1/0/1] openflow shutdown

permit-port-type member-port

Use permit-port-type member-port to allow link aggregation member ports to be in the deployed flow tables.

Use undo permit-port-type to restore the default.

Syntax

permit-port-type member-port

undo permit-port-type

Default

Link aggregation member ports cannot be in the deployed flow tables.

Views

OpenFlow instance view

Predefined user roles

network-admin

Examples

# Configure OpenFlow instance 1 to allow link aggregation member ports to be in the deployed flow tables.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] permit-port-type member-port

precedence dynamic arp

Use precedence dynamic arp to allow dynamic ARP entries to overwrite OpenFlow ARP entries.

Use undo precedence dynamic to restore the default.

Syntax

precedence dynamic arp

undo precedence dynamic arp

Default

An OpenFlow instance does not allow dynamic ARP entries to overwrite OpenFlow ARP entries.

Views

OpenFlow instance view

Predefined user roles

network-admin

Usage guidelines

This command takes effect only on the MAC-IP flow table of an OpenFlow instance.

Examples

# Configure OpenFlow instance 1 to allow dynamic ARP entries to overwrite OpenFlow ARP entries.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] precedence dynamic arp

protocol-packet filter slow

Use protocol-packet filter slow to configure an OpenFlow instance to drop slow protocol packets.

Use undo protocol-packet filter to restore the default.

Syntax

protocol-packet filter slow

undo protocol-packet filter

Default

An OpenFlow instance is not configured to drop slow protocol packets.

Views

OpenFlow instance view

Predefined user roles

network-admin

Usage guidelines

The slow protocols include LACP and OAM.

Examples

# Configure OpenFlow instance 1 to drop slow protocol packets.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] protocol-packet filter slow

refresh ip-flow

Use refresh ip-flow to refresh all Layer 3 flow entries in the MAC-IP flow tables for an OpenFlow instance.

Syntax

refresh ip-flow

Views

OpenFlow instance view

Predefined user roles

network-admin

Usage guidelines

Layer 3 flow entries in the MAC-IP flow tables might be overwritten. In such cases, you can use this command to obtain all Layer 3 flow entries in the MAC-IP flow tables from the controller again.

Examples

# Refresh all Layer 3 flow entries in the MAC-IP flow tables for OpenFlow instance 1.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] refresh ip-flow

reset openflow instance statistics

Use reset openflow instance statistics to clear statistics on packets that a controller sends and receives for an OpenFlow instance.

Syntax

reset openflow instance instance-id controller [ controller-id ]  statistics

Views

User view

Predefined user roles

network-admin

Parameters

instance-id: Specifies an OpenFlow instance by its ID in the range of 1 to 4094.

controller-id: Specifies a controller by its ID in the range of 0 to 63. If you do not specify a controller ID, this command clears statistics on packets that all controllers send and receive for an OpenFlow instance.

Examples

# Clear statistics on packets that all controllers send and receive for OpenFlow instance 1.

<Sysname> reset openflow instance 1 controller statistics

snmp-agent trap enable openflow

Use snmp-agent trap enable openflow to enable SNMP notifications for OpenFlow.

Use undo snmp-agent trap enable openflow to disable SNMP notifications for OpenFlow.

Syntax

snmp-agent trap enable openflow [ connect-state ]

undo snmp-agent trap enable openflow [ connect-state ]

Default

SNMP notifications are enabled for OpenFlow.

Views

System view

Predefined user roles

network-admin

Parameters

connect-state: Specifies notifications about status changes of the connections between OpenFlow switches and controllers. If you do not specify this keyword, the command enables all notifications for OpenFlow.

Usage guidelines

This command enables OpenFlow to generate SNMP notifications for important OpenFlow events. For the notifications to be sent correctly, you must also configure SNMP on the device. For more information about SNMP configuration, see SNMP configuration in Network Management and Monitoring Configuration Guide.

Examples

# Enable SNMP notifications for OpenFlow.

<Sysname> system-view

[Sysname] snmp-agent trap enable openflow

tcp dscp

Use tcp dscp to set a DSCP value for OpenFlow packets.

Use undo tcp dscp to restore the default.

Syntax

tcp dscp dscp-value

undo tcp dscp

Default

The DSCP value for OpenFlow packets is not set.

Views

OpenFlow instance view

Predefined user roles

network-admin

Parameters

dscp-value: Specifies a DSCP value for OpenFlow packets, in the range of 0 to 63.

Examples

# Set the DSCP value to 63 for OpenFlow packets.

<Sysname> system-view

[Sysname] openflow instance 1

[Sysname-of-inst-1] tcp dscp 63

 

  • Cloud & AI
  • InterConnect
  • Intelligent Computing
  • Intelligent Storage
  • Security
  • SMB Products
  • Intelligent Terminal Products
  • Product Support Services
  • Technical Service Solutions
All Services
  • Resource Center
  • Policy
  • Online Help
  • Technical Blogs
All Support
  • Become A Partner
  • Partner Policy & Program
  • Global Learning
  • Partner Sales Resources
  • Partner Business Management
  • Service Business
All Partners
  • Profile
  • News & Events
  • Online Exhibition Center
  • Contact Us
All About Us