Hi Allan,

So you're getting the ports by

def on_datapath_up(event):
    topology = core.components['topology']
    dp_id = event.dpid

    ports = topology.getEntityByID(dp_id).ports

Is topology a part of pox or where does it come from? I just wonder
whether I could use that piece of code as it is or I have to do
further modifications.



Regards,

Julius



On Tue, Jan 8, 2013 at 12:21 PM, Allan Vidal <[email protected]> wrote:

> Hi Julius,
>
> We perform a similar task on RouteFlow.
> Here's the code:
> https://github.com/CPqD/RouteFlow/blob/master/pox/ext/rfproxy.py#L145
>
> I guess you can also do it through a packet-in event by using the datapath
> id.
>
>
> Allan
>
>
> On Tue, Jan 8, 2013 at 9:17 AM, Julius Bachnick <[email protected]
> > wrote:
>
>> Hi all,
>>
>> I need to know the tital number of ports of a switch for different
>> reasons. I was hoping to retrieve that message via ofp_packet_in but it
>> does not seem to be the case.
>>
>> Whant I want to do is handling ConnectionUp Events with the additional
>> information of how many ports a switch has.
>>
>> Any suggestions or ideas are welcome!
>>
>>
>> Regards,
>>
>> Julius
>>
>
>

Reply via email to