Hi,

You do not need buffer_id but what you really need is the Datapath ID ( or
pi.datapath_id as you will see it the switch example ) of each switch to
correctly identify all the switches currently connected to the Controller.
You should look into Datapath join event (the event caused by a switch
joining the controller) to get the datapath ids required.

Regards,
Khan

2011/10/5 Sergio Jiménez Feijóo <sergio.j...@gmail.com>

> Hi,
>
> I'm developping an Openflow app which calculates the optimal path between
> two Openflow switches. Once my app knows the path to use it needs to set up
> a flowmod in all the switches involved in the path. The code of my app is
> triggered everytime a Packet_in_event happens.
>
> I've been taking a look at the learning switch example code in coreapps and
> seems that in order to create a fowmod you need acces to the buffer of the
> switch which triggered the event.
>
> If you are setting a flowmod in the switch which triggered the event that's
> not a problem because you can get the buffer from the Packet_in_event.
>
> const Packet_in_event& pi = assert_cast<const Packet_in_event&>(e);
> uint32_t buffer_id = pi.buffer_id;
>
> ofm->buffer_id = htonl(buffer_id);
>
> But my problem is that I also need to set flowmods in the other switches
> which haven't received a Packet_in_event (therefore I can't acces their
> buffers).
>
> The acces to the buffer is really necesary to set up a flowmod in a switch?
> Is there any way to do this?
>
> Thank you.
> ______________________________**_________________
> nox-dev mailing list
> nox-dev@noxrepo.org
> http://noxrepo.org/mailman/**listinfo/nox-dev<http://noxrepo.org/mailman/listinfo/nox-dev>
>
_______________________________________________
nox-dev mailing list
nox-dev@noxrepo.org
http://noxrepo.org/mailman/listinfo/nox-dev

Reply via email to