Mellanox eSwitchd Installation for OpenFlow and OpenStack

Version 27

    eSwitchD Installation

     

    1. Obtain the following RPM: (click here)

     

    2.  Install the PRM package:

     

    #yum install eswitchd

     

    3. Configure eswitchd configuration file /etc/eswitchd/eswitchd.conf


    An example of eswitchd.conf

     

    [DEFAULT]

    default_log_levels="eswitchd=DEBUG"

    verbose=False

    debug=False

    log_file=/var/log/eswitchd.log

    [DAEMON]

    fabrics='default:autoeth'

    default_timeout=4000

    socket_os_port=60001

    socket_of_port=60000

    [OF]

    of_agent_mappings=default:127.0.0.1:auto

    start_of_agent=no

     

         
    The most important line is fabrics='<fabric_name>:<PF Name>' which should hold the fabric name and the Physical Function (PF) attached to it.

    In the example above, one fabric, named 'default', is configured and is associated with the first Ethernet PF found.

     

    Note: if you use OpenStack the configuration of the fabrics will be taken from /etc/quantum/plugins/mlnx/mlnx_conf.ini and not from the eswitchd configuraiton file  /etc/eswitchd/eswitchd.conf

     

    Note: if you use 'autoeth' as parameter for the 'fabrics' you need to make sure that there is only one Ethernet port configured (the second one is InfiniBand). if you want to work with two Ethernet ports, you need to specify exactly which PF you wish to configure.  This is similar for 'autoib' value for the fabrics.

    The names of the PFs for Ethernet should be 'eth* ' (e.g. eth2), and for InfiniBand it should be 'ib*' (e.g. ib2). this is similar also for the names of the VF for Ethernet.

     

     

    Enable OpenFlow agent:

    To enable the OpenFlow agent (based on Indigo2 open-source project), change the 'OF' section as follows:


    start_of_agent=yes

    of_agent_mapping=<fabric>:<controller_ip>:<dpid>


    of_agent_mapping value is consist of the following parameters:

    - 'fabric': it is the name of the fabric. Note that it should be the same as the eswitchd fabric name specified in [DAEMON] section

    - 'controller_ip': is the IP address of the OpenFlow Controller

    - 'dpid': is the OF agent unique identifier, it is a string of 8 hexadecimal numbers. Use 'auto' to automatically generate a DPID based on the local NIC MAC

     

    For example, in case the OpenFlow controller is installed on the same machine:

    of_agent_mappings=default:127.0.0.1:auto

     

    4. Start eswitchd daemon:   

    #/etc/init.d/eswitchd start

     

    OpenFlow Controller Installation Flow

     

    To interact with the OpenFlow agent, any 1.0 certified OpenFlow controller can be used (e.g. floodlight, http://www.projectfloodlight.org/download/)

     

    1. To install floodlight

    #yum localinstall floodlight-0.01_1-1.x86_64.rpm

     


    2. To start the OpenFlow controller

    #/etc/init.d/floodlight start

     

    ----

    If you run the eswitchd outside of OpenStack solution you should make sure the following is set in /etc/sysconfig/eswitchd:

    OPENSTACK=no

     

     

    ----

    To make OpenFlow controller started on boot:

    #/sbin/chkconfig floodlight on