networking - Representation of Network topology in python -


this code class switches https://github.com/osrg/ryu/blob/master/ryu/topology/switches.py#l429

the member variables of particular interest me in class switches following.

    self.dps = {}                 # datapath_id => datapath class     self.port_state = {}          # datapath_id => ports     self.ports = portdatastate()  # port class -> portdata class     self.links = linkstate()      # link class -> timestamp     self.is_active = true 

these member variables ryu uses cache topology details.i trying figure out how topology can represented using following variables.

1) dps dictionary maps datapath_id datapath class?

- can explain me datapath_id , datapath class? 

2) port_state dictionary maps datapath id ports

- per understanding on switch without vlan ports belong           same datapath id? in case of switch vlan ports on switch can have multiple datapath id's. understanding correct? 

3) ports again dictionary maps port class portdata class?

- mean? 

4) links again dictionary maps link class timestamp

- again mean? 

i trying head around how ryu controller stores topology information using above structures.any in understanding or explanation appreciated.

generically , each openflow switch connects controller on specific port each such connection between switch , controller seen individual 'datapath' , referred dpid (datapath id).

a link perceived connection between ports belonging 2 dpids, hence dpid 1 (port1) <—> (port2)dpid2 link between sw1 p1 , sw2 p1.

i use pox controller, not across ryu, think can make sense of it.


Comments

Popular posts from this blog

jQuery Mobile app not scrolling in Firefox -

c++ - How to add Crypto++ library to Qt project -

php array slice every 2th rule -