Skip to content

Frequently Asked Questions

Eder Leão Fernandes edited this page Sep 12, 2018 · 14 revisions

F.A.Q


1. How do I change the number of tables?
2. How do I change the maximum number of flow entries in a Flow Table?
3. Does the switch supports in-band connections?
4. Why I cannot compile for OpenWRT?
5. Why I cannot use queues with Mininet?
6. How do I connect the switch to a physical interface?
7. What is the difference between punix/unix and tcp/ptcp for the ofdatapath and ofprotocol commands?

N+1. Wait, BOFUSS? The repository name says ofsofswitch13...

1. How do I change the number of tables?

The current number of tables is 64. If you need more change the definition of PIPELINE_TABLES in openflow.h Example:

#define PIPELINE_TABLES <your magic number>

2. How do I change the maximum number of flow entries in a Flow Table?

The current defined number is 4096. If you need more change the definition of FLOW_TABLE_MAX_ENTRIES in flow_table.h

#define FLOW_TABLE_MAX_ENTRIES <your magic number>

3. Does the switch supports in-band connections?

The switch currently does not have working support for in-band connections. The code needs to be updated to reflect OpenFlow 1.3 changes.


4. Why I cannot compile for OpenWRT?

A recurrent topic, specially for newer versions. The support for OpenWRT is outdated and was only tested in a single wifi router (TP-LINK TL-WR1043ND) with an specific OpenWRT version (Backfire)

You may find online resources for newer OpenWRT versions. I will list some here. I never tried any of them (I do not even own an OpenWRT router at the moment...) Use for your own account and risk. Links in chronological order:


5. Why I cannot use queues with Mininet?

By default, Mininet starts the switch with the option --no-slicing. A way to change it is to remove the switch options when adding a new switch on Mininet. Example:

self.addSwitch( 's3', cls=UserSwitch, dpopts='')

6. How do I connect the switch to a physical interface?

Simply add the interfaces you would like to the --interfaces argument from ofdatapath command.

sudo ofdatapath --datapath-id=000000000001--interfaces=real_if1,real_if2 punix:/tmp/s1

7. What is the difference between punix/unix and tcp/ptcp for the ofdatapath and ofprotocol commands?

The "p" stands for passive. It means the switch/secure channel will listen instead of actively trying to connect to a controller. The ofdatapath has only punix and ptcp as options. It means it will always listen for a connection.

In the case of the secure channel, it can actively start a connection with a controller, using unix and tcp sockets. Let's clarify with two examples:

Connect the switch to the secure channel using linux sockets

$sudo ofdatapath --datapath-id=0x0000000000000001--interfaces=eth1 punix:/tmp/s1
$sudo ofprotocol unix:/tmp/s1 tcp:127.0.01:6653 

In the example above /tmp/s1 is the Unix domain socket file name. The ofprotocol connects to the switch through the unix socket and to the controller listening in the localhost port 6653.

Connect the switch to the secure channel using TCP sockets

If for some reason the control channel needs to run in a machine different than the datapath, you can use TCP sockets. Suppose the switch is running in a machine with IP 192.168.0.1.

ofdapath --datapath-id=0x0000000000000001--interfaces=eth1 ptcp:6654
ofprotocol tcp:192.168.0.1:6654 tcp:127.0.0.1:6653 

In the example, the switch listens in the TCP port 6654. The secure channel will then actively connect to the ofdapath at tcp:192.168.0.1:6654. Again, it connect to a controller running locally at port 6653.


N+1. Wait, BOFUSS? The repository name says ofsofswitch13...

The switch was never called ofsofswitch13. By a lack of imagination, first thing I did when porting OF 1.2 to 1.3 was to create a new repository and that was the quick name I came up. As ofsoftswitch13 is not the nicest name, the switch is commonly called CPqD switch.

The problem to only refer to it as CPqD switch, it is not fair to the other entities that have developed the base of the code. As it is true that version 1.2 and 1.3 of OpenFLow were implemented by me during my time at CPqD, the switch started in Stanford as the OpenFlow reference switch. Later it was upgraded by the work of Zoltán, from Ericsson's Traffic Lab, to support OpenFlow 1.1.

So, after talking to Zoltán and other collaborators we came up with the name BOFUSS which stands for:

Basic OpenFlow User Space Software Switch.