Configure Switch


Use Linux command ps -A to show the running processes. The ovsdb-server and ovs-vswitchd are there to indicate the ovs switch is ready for operation. Next, print the content of the switch database by using the ovs-vsctl show command to dump the switch configuration. It shows the database id, a bridge named br0 with four 1GbE ports, and an internal port.

In most start up cases, a new database name of administrator's choice will be entered. As a result, an empty database is created. The show command will just show the database id. If a new database is created, the next step should be skipped, so move on to the add-br command. The following example will demonstrate how to delete the old bridge by utilizing the ovs-vsctl  del-br br0 command. Check the database content by using the show command which should just show the database id.The following example shows how to create a bridge and add ports for the bridge.

root@PicOS-OVS$
root@PicOS-OVS$ovs-vsctl add-br br0 -- set bridge br0 datapath_type=pica8                                
device br0 entered promiscuous mode
root@PicOS-OVS$ovs-vsctl add-port br0 te-1/1/1 vlan_mode=trunk tag=1 -- set interface te-1/1/1 type=pica8    
root@PicOS-OVS$ovs-vsctl add-port br0 te-1/1/2 vlan_mode=trunk tag=1 -- set interface te-1/1/2 type=pica8  
root@PicOS-OVS$ovs-vsctl add-port br0 te-1/1/3 vlan_mode=trunk tag=1 -- set interface te-1/1/3 type=pica8  
root@PicOS-OVS$ovs-vsctl add-port br0 te-1/1/4 vlan_mode=trunk tag=1 -- set interface te-1/1/4 type=pica8  
root@PicOS-OVS$
root@PicOS-OVS$ovs-vsctl show 
d4d12890-c07a-4303-80cc-c6f79cf3afd7
    Bridge "br0"
        Port "te-1/1/3"
            tag: 1
            Interface "te-1/1/3"
                type: "pica8"
        Port "te-1/1/4"
            tag: 1
            Interface "te-1/1/4"
                type: "pica8"
        Port "br0"
            Interface "br0"
                type: internal
        Port "te-1/1/2"
            tag: 1
            Interface "te-1/1/2"
                type: "pica8"
        Port "te-1/1/1"
            tag: 1
            Interface "te-1/1/1"
                type: "pica8"
root@PicOS-OVS$

Copyright © 2024 Pica8 Inc. All Rights Reserved.