Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Datapath ID is not set correctly at LincSwitch when used with mininet API #11

Open
jalilm opened this issue Aug 25, 2014 · 5 comments
Open

Comments

@jalilm
Copy link

jalilm commented Aug 25, 2014

Each Switch object have a field denoted by dpid (datapath_id) that should be sent at FeaturesResponse message by the switch throughout the handshake.

By default, the Switch class generates different dpid according to the switch name. However this dpid is not reflected at FeaturesResponse message sent by linc. What is more, all linc switches send the same dpid (most controllers have no other way to distinguish which switch have sent the OpenFlow messages)!

To verify this behavior, just examine a handshake with 2 switches via Wireshark.

A suggested fix is to take advantage of the "-s" argument to linc_config_gen (already used from some reason with 0) by changing line 944 at node.py from:
configArgs = self.formConfigGenLogicalSwitchIdArg(0)
to:
configArgs = self.formConfigGenLogicalSwitchIdArg(self.dpid) \

@jalilm
Copy link
Author

jalilm commented Aug 27, 2014

or even better:
int_dpid = int(self.dpid, 16)
configArgs = self.formConfigGenLogicalSwitchIdArg(int_dpid) \

to allow more than '0xa' switches, since otherwise you encounter the following error:
escript: exception error: bad argument
in function list_to_integer/1
called as list_to_integer("000000000000000a")

@dcc6fvo
Copy link

dcc6fvo commented Mar 12, 2017

This is a good point @jalilm ...

It's impossible to work with Floodlight Controller for example... Since in Floodlight it needs a differente DPID for each switch.

Thank you very much for your suggestion

@dcc6fvo
Copy link

dcc6fvo commented Mar 12, 2017

Do you have the modified mininet linc script @jalilm ?

@jalilm
Copy link
Author

jalilm commented Mar 13, 2017

@dcc6fvo,

Sorry, I do not have the modified files anymore. It should be a simple fix as I suggested, it worked for me back then.

Anyhow, the project seems discontinued and inactive so you probably better look somewhere else.

@dcc6fvo
Copy link

dcc6fvo commented Mar 13, 2017

Ok @jalilm .. my final goal is using OF-CONFIG's native support. But first, I need to get LINC working with the Floodlight Controller.

Thank you very much.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants