Configuration Example1 in Crossflow Mode


Configure the OpenFlow Port in CrossFlow Mode

Commands:

admin@XorPlus# set xovs enable true
admin@XorPlus# commit
admin@XorPlus# set interface gigabit-ethernet ge-1/1/1 crossflow enable true
admin@XorPlus# set interface gigabit-ethernet ge-1/1/1 crossflow local-control false
admin@XorPlus# set vlans vlan-id 2,2000,4094
admin@XorPlus# commit
admin@XorPlus# set interface gigabit-ethernet ge-1/1/1 family ethernet-switching port-mode trunk 
admin@XorPlus# set interface gigabit-ethernet ge-1/1/1 family ethernet-switching vlan members 2
admin@XorPlus# set interface gigabit-ethernet ge-1/1/1 family ethernet-switching vlan members 2000
admin@XorPlus# set interface gigabit-ethernet ge-1/1/1 family ethernet-switching vlan members 4094
admin@XorPlus# commit

Commands in Linux:

admin@XorPlus$ovs-vsctl list pica8
admin@XorPlus$ovs-vsctl add-br br0 -- set bridge br0 datapath_type=pica8
admin@XorPlus$ovs-vsctl add-port br0 ge-1/1/1 -- set Interface ge-1/1/1 type=pica8

Configure the Hybrid Port in CrossFlow Mode 

Commands:

admin@XorPlus# set xovs enable true
admin@XorPlus# commit
admin@XorPlus# set interface gigabit-ethernet ge-1/1/2 crossflow enable true
admin@XorPlus# set vlans vlan-id 2,2000,4094
admin@XorPlus# commit
admin@XorPlus# set interface gigabit-ethernet ge-1/1/2 family ethernet-switching port-mode trunk 
admin@XorPlus# set interface gigabit-ethernet ge-1/1/2 family ethernet-switching vlan members 2
admin@XorPlus# set interface gigabit-ethernet ge-1/1/2 family ethernet-switching vlan members 2000
admin@XorPlus# set interface gigabit-ethernet ge-1/1/2 family ethernet-switching vlan members 4094
admin@XorPlus# commit

Commands in Linux:

admin@XorPlus$ovs-vsctl list pica8
admin@XorPlus$ovs-vsctl add-br br0 -- set bridge br0 datapath_type=pica8
admin@XorPlus$ovs-vsctl add-port br0 ge-1/1/2 -- set Interface ge-1/1/2 type=crossflow

Examples

Basic Configurations

topology

 

Step 1: Configure port te-1/1/1 as OpenFlow port and te-1/1/2 as CrossFlow port

admin@XorPlus# set xovs enable true
admin@XorPlus# commit
admin@XorPlus# set interface gigabit-ethernet te-1/1/1 crossflow enable true
admin@XorPlus# set interface gigabit-ethernet te-1/1/1 crossflow local-control false
admin@XorPlus# set interface gigabit-ethernet te-1/1/2 crossflow enable true
admin@XorPlus# set vlans vlan-id 2,10,20
admin@XorPlus# commit
admin@XorPlus# set interface gigabit-ethernet te-1/1/1 family ethernet-switching port-mode trunk
admin@XorPlus# set interface gigabit-ethernet te-1/1/1 family ethernet-switching vlan members 2,10,20
admin@XorPlus# set interface gigabit-ethernet te-1/1/2 family ethernet-switching port-mode trunk 
admin@XorPlus# set interface gigabit-ethernet te-1/1/2 family ethernet-switching vlan members 2,10,20
admin@XorPlus# commit 
admin@XorPlus# set interface gigabit-ethernet te-1/1/1 speed 1000
admin@XorPlus# set interface gigabit-ethernet te-1/1/2 speed 1000
admin@XorPlus# commit

Step 2: Exit the Xorplus system, then enter Linux system

admin@XorPlus#exit 
admin@XorPlus>exit
admin@XorPlus$

Step 3: Create a new bridge named br0

admin@XorPlus$ovs-vsctl add-br br0 -- set bridge br0 datapath_type=pica8

Step 4: Add ports to br0

admin@XorPlus$ovs-vsctl add-port br0 te-1/1/1 -- set Interface te-1/1/1 type=pica8
admin@XorPlus$ovs-vsctl add-port br0 te-1/1/2 -- set Interface te-1/1/2 type=crossflow

Step 5: Add a flow

admin@XorPlus$ovs-ofctl  add-flow br0 in_port=1,actions=output:2

Step 6: Send packets to te-1/1/1

Send untagged packets to te-1/1/1 that match this flow. Then, te-1/1/2 will forward the packets (with no vlan). Send packets with vlan 2 to te-1/1/1. Then, te-1/1/2 will forward the packets (with vlan 2).


Lag Configurations

Step 1: Set lag interface (Only Openflow ports can be added to an openflow lag as members, and only Crossflow ports can be added to a Crossflow lag as members.)

admin@XorPlus# set xovs enable true
admin@XorPlus# commit
admin@XorPlus# set interface gigabit-ethernet te-1/1/1 crossflow enable true
admin@XorPlus# set interface gigabit-ethernet te-1/1/1 crossflow local-control false
admin@XorPlus# set interface gigabit-ethernet te-1/1/2 crossflow enable true
admin@XorPlus# commit
admin@XorPlus#set interface aggregate-ethernet ae1 crossflow enable true   
admin@XorPlus#set interface aggregate-ethernet ae1 crossflow local-control false
admin@XorPlus#set interface aggregate-ethernet ae2 crossflow enable true
admin@XorPlus# commit
admin@XorPlus# set interface gigabit-ethernet te-1/1/1 speed 1000
admin@XorPlus# set interface gigabit-ethernet te-1/1/2 speed 1000
admin@XorPlus# commit 
admin@XorPlus# set interface gigabit-ethernet te-1/1/1 ether-options 802.3ad ae1 
admin@XorPlus# set interface gigabit-ethernet te-1/1/2 ether-options 802.3ad ae2 
admin@XorPlus# commit 
admin@XorPlus#set vlans vlan-id 2,10,20
admin@XorPlus# commit
admin@XorPlus# set interface aggregate-ethernet ae1 family ethernet-switching port-mode trunk
admin@XorPlus# set interface aggregate-ethernet ae1 family ethernet-switching vlan members 2,10,20
admin@XorPlus# set interface aggregate-ethernet ae2 family ethernet-switching port-mode trunk 
admin@XorPlus# set interface aggregate-ethernet ae2 family ethernet-switching vlan members 2,10,20
admin@XorPlus# commit 

Step 2: Exit the Xorplus system, then enter Linux system

admin@XorPlus#exit 
admin@XorPlus>exit
admin@XorPlus$

Step 3: Create a new bridge named br0.

admin@XorPlus$ovs-vsctl add-br br0 -- set bridge br0 datapath_type=pica8

Step 4: Add ports to br0.

admin@XorPlus$ovs-vsctl add-port br0 ae1 -- set Interface ae1 type=pica8_lag
admin@XorPlus$ovs-vsctl add-port br0 ae2 -- set Interface ae2 type=pica8_lag


Flow Priority Configurations

topology

Step 1: Configure two ports as Openflow ports

admin@XorPlus# set xovs enable true
admin@XorPlus# commit
admin@XorPlus# set interface gigabit-ethernet te-1/1/1 crossflow enable true
admin@XorPlus# set interface gigabit-ethernet te-1/1/1 crossflow local-control false
admin@XorPlus# set interface gigabit-ethernet te-1/1/2 crossflow enable true
admin@XorPlus# set interface gigabit-ethernet te-1/1/2 crossflow local-control false
admin@XorPlus# set vlans vlan-id 2,10,20
admin@XorPlus# commit
admin@XorPlus# set interface gigabit-ethernet te-1/1/1 family ethernet-switching port-mode trunk
admin@XorPlus# set interface gigabit-ethernet te-1/1/1 family ethernet-switching vlan members 2,10,20
admin@XorPlus# commit
admin@XorPlus# set interface gigabit-ethernet te-1/1/2 family ethernet-switching port-mode trunk
admin@XorPlus# set interface gigabit-ethernet te-1/1/2 family ethernet-switching vlan members 2,10,20
admin@XorPlus# commit

Step 2: Exit the Xorplus system, then enter Linux system

admin@XorPlus#exit 
admin@XorPlus>exit
admin@XorPlus$

Step 3: Create a new bridge named br0.

admin@XorPlus$ovs-vsctl add-br br0 -- set bridge br0 datapath_type=pica8

Step 4: Add ports to br0.

admin@XorPlus$ovs-vsctl add-port br0 te-1/1/1 -- set Interface te-1/1/1 type=pica8
admin@XorPlus$ovs-vsctl add-port br0 te-1/1/2 -- set Interface te-1/1/2 type=pica8

Step 5: Add two flows

admin@XorPlus$ovs-ofctl  add-flow br0 in_port=1,dl_src=22:11:11:11:11:11,actions=output:2
admin@XorPlus$ovs-ofctl  add-flow br0 in_port=1,priority=50000,dl_src=22:11:11:11:11:11,actions=mod_dl_src:22:22:22:22:22:22,output:2

Step 6: Send packets to te-1/1/1

Send untagged packets to te-1/1/1 that match this flow, then te-1/1/2 will forward the packets (with no vlan), and the packets’ source mac address is modified to 22:22:22:22:22:22, because the priority of the second flow is higher than that of the first flow.

Send packets with vlan 2 to te-1/1/1, then te-1/1/2 will forward the packets with vlan 2 and the packets’ source mac address is modified to 22:22:22:22:22:22.


FDB Configurations

topology

Step 1: Configure two ports as Openflow ports

Step 2: Exit the Xorplus system, then enter Linux system

admin@XorPlus# set xovs enable true
admin@XorPlus# commit
admin@XorPlus# set interface gigabit-ethernet te-1/1/1 crossflow enable true
admin@XorPlus# set interface gigabit-ethernet te-1/1/1 crossflow local-control false
admin@XorPlus# set interface gigabit-ethernet te-1/1/2 crossflow enable true
admin@XorPlus# set interface gigabit-ethernet te-1/1/2 crossflow local-control false
admin@XorPlus#set vlans vlan-id 2,10,20
admin@XorPlus# commit
admin@XorPlus# set interface gigabit-ethernet te-1/1/1 family ethernet-switching port-mode trunk
admin@XorPlus# set interface gigabit-ethernet te-1/1/1 family ethernet-switching vlan members 2,10,20
admin@XorPlus# commit
admin@XorPlus# set interface gigabit-ethernet te-1/1/2 family ethernet-switching port-mode trunk
admin@XorPlus# set interface gigabit-ethernet te-1/1/2 family ethernet-switching vlan members 2,10,20
admin@XorPlus# commit
admin@XorPlus#exit 
admin@XorPlus>exit
admin@XorPlus$

Step 3: Create a new bridge named br0.

admin@XorPlus$ovs-vsctl add-br br0 -- set bridge br0 datapath_type=pica8

Step 4: Add ports to br0.

admin@XorPlus$ovs-vsctl add-port br0 te-1/1/1 -- set Interface te-1/1/1 type=pica8
admin@XorPlus$ovs-vsctl add-port br0 te-1/1/2 -- set Interface te-1/1/2 type=pica8

Step 5: Set table 1 to FDB table

admin@XorPlus$ovs-vsctl set-l2-mode true 1

Step 6: Add a flow

admin@XorPlus$ovs-ofctl  add-flow br0 table=1,dl_dst=22:22:22:22:22:22,dl_vlan=10,actions=output:2

Flows must match dl_dst,dl_vlan and output port if they want to be stored in FDB table. Table number of FDB table is 251 by default. User can specify another table as the FDB table instead of the 251 by using this command: ovs-vsctl set-l2-mode true [table number].


If you want flows to be stored in ROUTE table, flows must match dl_dst,dl_vlan,dl_type,nw_dst, and mod_dl_dst in action, and the default table number of ROUTE is 252. Use command ovs-vsctl set-l3-mode true [table number] to set route table.

Route Configurations

topology

Step 1: Configure two ports as Openflow ports

Step 2: Exit the Xorplus system, then enter Linux system

admin@XorPlus# set xovs enable true
admin@XorPlus# commit
admin@XorPlus# set interface gigabit-ethernet te-1/1/1 crossflow enable true
admin@XorPlus# set interface gigabit-ethernet te-1/1/1 crossflow local-control false
admin@XorPlus# set interface gigabit-ethernet te-1/1/2 crossflow enable true
admin@XorPlus# set interface gigabit-ethernet te-1/1/2 crossflow local-control false
admin@XorPlus#set vlans vlan-id 2,10,20
admin@XorPlus# commit
admin@XorPlus# set interface gigabit-ethernet te-1/1/1 family ethernet-switching port-mode trunk
admin@XorPlus# set interface gigabit-ethernet te-1/1/1 family ethernet-switching vlan members 2,10,20
admin@XorPlus# commit
admin@XorPlus# set interface gigabit-ethernet te-1/1/2 family ethernet-switching port-mode trunk
admin@XorPlus# set interface gigabit-ethernet te-1/1/2 family ethernet-switching vlan members 2,10,20
admin@XorPlus# commit
admin@XorPlus#exit 
admin@XorPlus>exit
admin@XorPlus$

Step 3: Create a new bridge named br0.

admin@XorPlus$ovs-vsctl add-br br0 -- set bridge br0 datapath_type=pica8

Step 4: Add ports to br0.

admin@XorPlus$ovs-vsctl add-port br0 te-1/1/1 -- set Interface te-1/1/1 type=pica8
admin@XorPlus$ovs-vsctl add-port br0 te-1/1/2 -- set Interface te-1/1/2 type=pica8

Step 5: enable L3-mode and the default table is 252

admin@XorPlus$ovs-vsctl set-l3-mode true

Step 6: Add a route flow

admin@XorPlus$ovs-ofctl add-flow br0 table=252,dl_vlan=1,dl_dst=22:00:00:00:00:00,ip,nw_dst=1.1.1.100/24,actions=set_field:2-\>vlan_vid,set_field:22:22:22:22:22:22-\>eth_dst,output:2











Copyright © 2024 Pica8 Inc. All Rights Reserved.