Re: [pox-dev] Get IP Protocol field from Flow Table

2013-04-13 Thread Sayed Qaiser Ali Shah Shah
Thanks Murphy McCauley I will try this. :) On Sun, Apr 14, 2013 at 4:28 AM, Murphy McCauley wrote: > Queue configuration is external to OpenFlow, so it seems to me that you > can't expect the controller to magically know which queues to use for what > on which switches. > > The first thing that s

Re: [pox-dev] Get IP Protocol field from Flow Table

2013-04-13 Thread Murphy McCauley
Queue configuration is external to OpenFlow, so it seems to me that you can't expect the controller to magically know which queues to use for what on which switches. The first thing that seems reasonable to me is to set the DPIDs for the switches to known values when configuring them -- at the

Re: [pox-dev] Get IP Protocol field from Flow Table

2013-04-13 Thread Sayed Qaiser Ali Shah Shah
Thanks for your reply. Is there anyway that dpid is taken automatically not to be entered manually?? On Sun, Apr 14, 2013 at 4:00 AM, Murphy McCauley wrote: > The event object also has a .dpid attribute which you can use to > distinguish between switches -- each switch has a different DPID. > > S

Re: [pox-dev] Get IP Protocol field from Flow Table

2013-04-13 Thread Murphy McCauley
The event object also has a .dpid attribute which you can use to distinguish between switches -- each switch has a different DPID. So you'll want to do something along the lines of... if event.dpid == : if packet.find('tcp'): action = of.ofp_action_enqueue(port = port, queue_id = 3) ...

Re: [pox-dev] Get IP Protocol field from Flow Table

2013-04-13 Thread Sayed Qaiser Ali Shah Shah
First of all I created two queues i.e. queue-0 and queue-1 on PORT Eth-1 of OVS. I use the code below on cotroller if packet.find('tcp'): queue=1 elif packet.find('arp'): queue=0 else: queue=1 msg = of.ofp_flow_mod() msg.match = of.ofp_match.from_packet(p

Re: [pox-dev] Get IP Protocol field from Flow Table

2013-04-05 Thread Sayed Qaiser Ali Shah Shah
Thanks a lot. In fact I want the same thing which you mentioned and I was after this since last one month. I am using OVS switch. I will try this. This is of great help for me. On Fri, Apr 5, 2013 at 1:18 PM, Murphy McCauley wrote: > Yes, you can do this if what you want can be accomplished using

Re: [pox-dev] Get IP Protocol field from Flow Table

2013-04-05 Thread Murphy McCauley
Yes, you can do this if what you want can be accomplished using the queue types available in your switch. If that condition is true, then there are several ways to do it with different tradeoffs. I'd suggest that you start off by modifying the l2_learning component to assign each new flow to t

Re: [pox-dev] Get IP Protocol field from Flow Table

2013-04-05 Thread Sayed Qaiser Ali Shah Shah
I think you mean that I want to achieve from this. I want to get IP protocol number from packet and then on the basis of that protocol number I want to assign bandwidth to flows/hosts on the basis of their needs. Like the protocol number which needs high bandwidth should be allocated high bandwidth

Re: [pox-dev] Get IP Protocol field from Flow Table

2013-04-04 Thread Murphy McCauley
On Apr 4, 2013, at 4:08 PM, Sayed Qaiser Ali Shah Shah wrote: > The link which you provide was very helpful and I found match class in that > and I use this code > > import pox.openflow.libopenflow_01 as of # POX convention > import pox.lib.packet as pkt # POX convention > my_match = of.ofp_match

Re: [pox-dev] Get IP Protocol field from Flow Table

2013-04-04 Thread Sayed Qaiser Ali Shah Shah
Dear Marphy McCauley The link which you provide was very helpful and I found match class in that and I use this code import pox.openflow.libopenflow_01 as of # POX convention import pox.lib.packet as pkt # POX convention my_match = of.ofp_match(dl_type = pkt.ethernet.IP_TYPE, nw_proto = pkt.ipv4.

Re: [pox-dev] Get IP Protocol field from Flow Table

2013-04-04 Thread Sayed Qaiser Ali Shah Shah
Thanks for your reply. For now, I am just using simple hub code. I just want to get Protocol number from Protocol field. I tried match class to get it but I think I use wrong approach. If there is any other method please let me know that how to get protocol number from flow entry or if it can be do

Re: [pox-dev] Get IP Protocol field from Flow Table

2013-04-04 Thread Murphy McCauley
On Apr 4, 2013, at 1:14 PM, Sayed Qaiser Ali Shah Shah wrote: > I am using Mininet 2.0 and POX controller. I am writing a script and I need > to get data from Protocol field i.e. which protocol number is being used so > that on the basis of that protocol number I can take some decision. > I trie

[pox-dev] Get IP Protocol field from Flow Table

2013-04-04 Thread Sayed Qaiser Ali Shah Shah
Hello everybody I am using Mininet 2.0 and POX controller. I am writing a script and I need to get data from Protocol field i.e. which protocol number is being used so that on the basis of that protocol number I can take some decision. I tried of.ofp_match() class but didn't get what I want. It ma