Programmable Internetworking & Communication Operating System Docs ... Click Spaces -> Space Directory to see docs for all releases ...
Page tree
Skip to end of metadata
Go to start of metadata

User can switch between L2/L3 and OVS modes using the picos_boot script already included in PicOS. User can run the script from the Linux shell on user's PicOS switch. The script will modify the PicOS configuration file /etc/picos/picos_start.conf automatically, without user having to edit the file manually.

  • The Linux shell prompt looks like username@hostname$, which may also give a hint about which PicOS mode is active. However, the sudo picos-status command at the Linux shell should be used to establish the current PicOS mode, as detailed in Checking PicOS Mode.
  • On N3048EP-ON, N3048ET-ON, N1148T-ON and N3132PX switches, run "save_config" command when perform picos_boot. Otherwise, the picos_boot configuration will be lost after PicOS reboot. For detail, please refer to Configuration Saving Guide.

Switching from L2/L3 Mode to OVS Mode

This section describes the procedure to switch from the L2/L3 mode to OVS mode on a PicOS switch named LEAF-A. The switch name is arbitrary.

  1. Login with username admin to arrive at the Linux shell prompt.

    Username: admin
    Password: 
    admin@LEAF-A$
  2. Check the current PicOS mode using the sudo picos-status command at the Linux shell.

    admin@LEAF-A:~$ sudo picos-status
    **********************************************************************
          The setting of PICOS mode in picos_start.conf is Xorplus.
    **********************************************************************
    PICOS is Running!
    Xorplus is Running!
    OVS is NOT Running!
    **********************************************************************
  3. Run the picos_boot script located in /usr/bin directory. The full path does not need to be used because the /usr/bin directory is on the system PATH by default.
  4. Enter option 2 to select OVS mode.
  5. Choose how the IP address of the management interface should be configured: DHCP or static IP. If Static IP is chosen, values for static IP address, subnet mask, and default gateway must be provided. If DHCP is chosen, no more questions are asked.

    admin@LEAF-A$sudo picos_boot
    Configure the default system start-up options:
     (Select key 3 if no change)
        [1]  PICOS L2/L3   * default
        [2]  PICOS Open vSwitch/OpenFlow
        [3]  No start-up change
    Enter your choice (1,2,3):2
    PICOS Open vSwitch/OpenFlow is selected.
    Configure the IP of management interface:
        [1] DHCP
        [2] Static IP
    Enter your choice(1,2):2
      Note: The OVS server, by default, uses static local management IP and port 6640.
            vSwitch, by default, connects to the server via PTCP.
    Set a static IP and netmask for the switch (128.0.0.10/24):192.168.42.120/24
    Set the gateway IP (172.168.1.2):192.168.42.1
    Please restart the PICOS service
  6. Restart the picos service to activate PicOS OVS mode.

    admin@LEAF-A$sudo systemctl restart picos
    ...............
    admin@LEAF-A$
  7. Verify that PicOS is now running in OVS mode.

    admin@LEAF-A:~$ sudo picos-status
    **********************************************************************
          The setting of PICOS mode in picos_start.conf is OVS.
    **********************************************************************
    PICOS is Running!
    Xorplus is NOT Running!
    OVS is Running!
    **********************************************************************

As an alternative to restarting the picos service, user can just reboot the switch to bring the PicOS mode change into effect.

admin@LEAF-A$sudo reboot
Broadcast message from root@PicOS-OVS (pts/0) (Sun Aug 16 21:18:48 2015):
The system is going down for reboot NOW!
 
Username: admin
Password: 
admin@PicOS-OVS$

The picos_boot script has the following options:

Option 1 selects the PICOS L2/L3 (Layer 2 / Layer 3) mode. When user chooses option 1, PICOS will load in L2/L3 mode after a reboot.

Option 2 selects the PICOS OVS (Open vSwitch) mode. When user chooses option 2, PICOS will load in OVS mode after a reboot.

Option 3 does not modify the present PICOS mode.

Switching from OVS Mode to L2/L3 Mode

 This section describes the procedure used to switch from OVS mode to L2/L3 mode on a PicOS switch named LEAF-A. The switch name is arbitrary.

  1. Log in with username admin to arrive at the Linux shell prompt.

    Username: admin
    Password: 
    admin@PicOS-OVS$
  2. Check the current PicOS mode using the sudo picos-status command at the Linux shell.

    admin@LEAF-A:~$ sudo picos-status
    **********************************************************************
          The setting of PICOS mode in picos_start.conf is OVS.
    **********************************************************************
    PICOS is Running!
    Xorplus is NOT Running!
    OVS is Running!
    **********************************************************************

    The above output shows that PicOS is running in OVS mode. Please refer to Checking PicOS Mode for details.

  3. Run the picos_boot script located in /usr/bin directory. The full path does not need to be used because the /usr/bin directory is on the system PATH by default.

  4. Enter option 1 to select L2/L3 mode.

    admin@PicOS-OVS$sudo picos_boot
    Configure the default system start-up options:
     (Select key 3 if no change)
        [1]  PICOS L2/L3
        [2]  PICOS Open vSwitch/OpenFlow   * default
        [3]  No start-up change
    Enter your choice (1,2,3):1
    PICOS L2/L3 switch system is selected.
    Please restart the PICOS service
  5. Restart the picos service to activate PicOS L2/L3 mode.

    admin@PicOS-OVS$sudo systemctl restart picos
    ..........................
    admin@PicOS-OVS$
  6. Verify that the switch is running in PicOS L2/L3 mode.

    admin@LEAF-A:~$ sudo picos-status
    **********************************************************************
          The setting of PICOS mode in picos_start.conf is Xorplus.
    **********************************************************************
    PICOS is Running!
    Xorplus is Running!
    OVS is NOT Running!
    **********************************************************************
  7. Optionally, user can run the cli command at the Linux shell to enter the PicOS L2/L3 operation mode.

    admin@PicOS-OVS$cli
    Synchronizing configuration...OK.
    Pica8 PicOS Version 3.1.0
    Welcome to PicOS L2/L3 on LEAF-A
    admin@LEAF-A>

As an alternative to restarting the picos service, user can just reboot the switch to bring the PicOS mode change into effect.

Enabling CrossFlow in L2/L3 Mode

This section describes the procedure to enable CrossFlow in L2/L3 mode.

  1. Enter L2/L3 operation mode, using the cli command at the Linux shell.

    admin@LEAF-A$ cli
    Synchronizing configuration...OK.
    Pica8 PicOS Version 2.6
    Welcome to PicOS L2/L3 on LEAF-A
    admin@LEAF-A>
  2. Enter configuration mode, using the configure command in the operation mode.

    admin@LEAF-A> configure
    Entering configuration mode.
    There are no other users in configuration mode.
    admin@LEAF-A#
  3. Enable CrossFlow mode, using the set xovs enable true command in configuration mode. Commit the changes, and exit the configuration mode. Then, exit the operation mode.

    admin@LEAF-A# set xovs enable true
    admin@LEAF-A# commit
    Commit OK.
    Save done.
    admin@LEAF-A# exit
    admin@LEAF-A> exit
    admin@LEAF-A$
  4. Verify that both L2/L3 and OVS modes are active using the sudo picos-status command at the Linux shell.

    admin@LEAF-A:~$ sudo picos-status
    **********************************************************************
          The setting of PICOS mode in picos_start.conf is Crossflow.
    **********************************************************************
    PICOS is Running!
    Xorplus is Running!
    OVS is Running!
    **********************************************************************
  5. User can now run the OVS mode commands from the Linux shell.

    admin@LEAF-A$ovs-vsctl show
    e8e63632-d96b-409a-89c3-95bb4ef61f46
        Bridge "ECODE3"
            Controller "tcp:65.19.141.118:6633"
                is_connected: true
            Port "ge-1/1/1"
                Interface "ge-1/1/1"
                    type: "pica8"
            Port "ECODE3"
                Interface "ECODE3"
                    type: internal
            Port "ge-1/1/47"
                Interface "ge-1/1/47"
                    type: "pica8"
            Port "ge-1/1/48"
                Interface "ge-1/1/48"
                    type: "pica8"
            Port "ge-1/1/2"
                Interface "ge-1/1/2"
                    type: "pica8"
  • No labels