Re: [pox-dev] L2 and L3 calling from another

2013-11-20 Thread Amer
Thank you I did it in other way around I created new dictionary. swdpid ={} and I put the switch MAC as keys and dpids are values :) Best regards, Amer Sent from my iPhone On ١٩‏/١١‏/٢٠١٣, at ١٠:٣٨ م, Murphy McCauley wrote: > On Nov 19, 2013, at 4:01 AM, Amer wrote: > >> Thank you Murphy >>

Re: [pox-dev] L2 and L3 calling from another

2013-11-19 Thread Murphy McCauley
On Nov 19, 2013, at 4:01 AM, Amer wrote: > Thank you Murphy > > I have another question: > I have got the switch MAC address, i.e., 00-00-00-00-0x, how can I convert it > to dpid. > I am working in l2_multi, while the switches array has something like [1: > 00-00-00-00-01, 2: 00-00-00-00-02 ]

Re: [pox-dev] L2 and L3 calling from another

2013-11-19 Thread Amer
Thank you Murphy I have another question: I have got the switch MAC address, i.e., 00-00-00-00-0x, how can I convert it to dpid. I am working in l2_multi, while the switches array has something like [1: 00-00-00-00-01, 2: 00-00-00-00-02 ] is there a way to get the dpid number from switches array

Re: [pox-dev] L2 and L3 calling from another

2013-11-18 Thread Murphy McCauley
I think you may have to modify l2_multi a bit to get this to work with it -- it was designed with the assumption that it's in control of all the switches, and I think that will cause problems. l2_learning, on the other hand, should be easy to run on individual switches. And l2_pairs should be

Re: [pox-dev] L2 and L3 calling from another

2013-11-15 Thread Amer
Thank you Durga I tried it with what you have said and I received same errors :( It is event.dpid from pox.forwarding.l2_multi import * I want to know how to do this if statement and it body, i.e., l2 and l3 classes calls. Should l write them in pox.py statement Ok if that, how is it switch f

Re: [pox-dev] L2 and L3 calling from another

2013-11-15 Thread durga
hello, is it really from pox.*forearding*.l2_multi import * and not 'from pox.forwarding.l2_multi import * also, dpid is an attribute of event, I think you can use event.dpid ==1, not sure if parsed packet has an attribute of dpid . Please use a debug / print to check value of p.dpid Cheers! Du

[pox-dev] L2 and L3 calling from another

2013-11-15 Thread Amer
Hello, I want to create a handle packetin method, if the incoming packet is from specific switch run l2 if it from another run l3 What I did from pox.forearding.l2_multi import * def H_P (event): p = event.parsed If (p.dpid == "1"): sw= Switch() sw._handle_PacketIn(event) El