<div dir="ltr">How do I do that?? Do I have to write any other code for that??<br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Wed, Apr 23, 2014 at 10:04 AM, <span dir="ltr"><<a href="mailto:pox-dev-request@lists.noxrepo.org" target="_blank">pox-dev-request@lists.noxrepo.org</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Send pox-dev mailing list submissions to<br>
<a href="mailto:pox-dev@lists.noxrepo.org">pox-dev@lists.noxrepo.org</a><br>
<br>
To subscribe or unsubscribe via the World Wide Web, visit<br>
<a href="http://lists.noxrepo.org/listinfo.cgi/pox-dev-noxrepo.org" target="_blank">http://lists.noxrepo.org/listinfo.cgi/pox-dev-noxrepo.org</a><br>
or, via email, send a message with subject or body 'help' to<br>
<a href="mailto:pox-dev-request@lists.noxrepo.org">pox-dev-request@lists.noxrepo.org</a><br>
<br>
You can reach the person managing the list at<br>
<a href="mailto:pox-dev-owner@lists.noxrepo.org">pox-dev-owner@lists.noxrepo.org</a><br>
<br>
When replying, please edit your Subject line so it is more specific<br>
than "Re: Contents of pox-dev digest..."<br>
<br>
<br>
Today's Topics:<br>
<br>
1. Re: Send packet back to input port of switch (Chanthan Hel)<br>
2. Re: pox-dev Digest, Vol 25, Issue 17 (shads s)<br>
3. Re: Prioritized servers in ip_loadbalancer (Murphy McCauley)<br>
<br>
<br>
----------------------------------------------------------------------<br>
<br>
Message: 1<br>
Date: Wed, 23 Apr 2014 10:50:02 +0700<br>
From: Chanthan Hel <<a href="mailto:hel.chanthan65@gmail.com">hel.chanthan65@gmail.com</a>><br>
To: Peter Peresini <<a href="mailto:peter.peresini@epfl.ch">peter.peresini@epfl.ch</a>><br>
Cc: pox-dev <<a href="mailto:pox-dev@lists.noxrepo.org">pox-dev@lists.noxrepo.org</a>><br>
Subject: Re: [pox-dev] Send packet back to input port of switch<br>
Message-ID:<br>
<<a href="mailto:CAA5EFMAJoOP0P_LCxRtJK-stigjC2myYVnEYzwFNmrH4REqESg@mail.gmail.com">CAA5EFMAJoOP0P_LCxRtJK-stigjC2myYVnEYzwFNmrH4REqESg@mail.gmail.com</a>><br>
Content-Type: text/plain; charset="iso-2022-jp"<br>
<br>
Dear all,<br>
I use this code<br>
msg = of.ofp_packet_out(data = event.ofp) # send packet out by packetIn<br>
event<br>
msg.actions.append(of.ofp_action_output(port = of.OFPP_IN_PORT)<br>
event.connection.send(msg)<br>
It works,<br>
Thanks so much<br>
<br>
<br>
<br>
On Wed, Apr 23, 2014 at 12:46 AM, Peter Peresini <<a href="mailto:peter.peresini@epfl.ch">peter.peresini@epfl.ch</a>>wrote:<br>
<br>
> Open flow requires you to use special ofpp_inport port number to send<br>
> traffic back!<br>
><br>
> Peter<br>
> (sent from android device)<br>
> On Apr 22, 2014 6:19 PM, "Chanthan Hel" <<a href="mailto:hel.chanthan65@gmail.com">hel.chanthan65@gmail.com</a>> wrote:<br>
><br>
>> Let me try,<br>
>> Thx so much.<br>
>><br>
>> On Tuesday, April 22, 2014, Shiyao Ma <<a href="mailto:i@introo.me">i@introo.me</a>> wrote:<br>
>><br>
>>> You may pastebin your sample code, or? an ofp_packet_out should do it.<br>
>>><br>
>>><br>
>>> 2014-04-22 23:40 GMT+08:00 Chanthan Hel <<a href="mailto:hel.chanthan65@gmail.com">hel.chanthan65@gmail.com</a>>:<br>
>>><br>
>>>> Dear all,<br>
>>>> As I know and according to my testing, when the ofswitch receive packet<br>
>>>> then controller does action on that packet and want to send it back to the<br>
>>>> incoming port, it always fails, we can not send packet back.<br>
>>>> So, if i want to send that packet back to the incoming port, how can we<br>
>>>> do??<br>
>>>> Chanthan<br>
>>>><br>
>>>> --<br>
>>>> Mr. Chanthan Hel<br>
>>>> Electrical engineering, Faculty of Engineering,<br>
>>>> Chulalongkorn University (CU)<br>
>>>><br>
>>>> *Phone: +66 81 456 84 27*<br>
>>>><br>
>>>><br>
>>><br>
>>><br>
>>> --<br>
>>><br>
>>> ????????????????<a href="http://introo.me" target="_blank">http://introo.me</a>?<br>
>>><br>
>><br>
>><br>
>> --<br>
>> Mr. Chanthan Hel<br>
>> Electrical engineering, Faculty of Engineering,<br>
>> Chulalongkorn University (CU)<br>
>><br>
>> *Phone: +66 81 456 84 27*<br>
>><br>
>><br>
>><br>
<br>
<br>
--<br>
Mr. Chanthan Hel<br>
Electrical engineering, Faculty of Engineering,<br>
Chulalongkorn University (CU)<br>
<br>
*Phone: +66 81 456 84 27*<br>
-------------- next part --------------<br>
An HTML attachment was scrubbed...<br>
URL: <<a href="http://lists.noxrepo.org/pipermail/pox-dev-noxrepo.org/attachments/20140423/3163a796/attachment-0001.htm" target="_blank">http://lists.noxrepo.org/pipermail/pox-dev-noxrepo.org/attachments/20140423/3163a796/attachment-0001.htm</a>><br>
<br>
------------------------------<br>
<br>
Message: 2<br>
Date: Wed, 23 Apr 2014 09:56:24 +0530<br>
From: shads s <<a href="mailto:shasi0625@gmail.com">shasi0625@gmail.com</a>><br>
To: pox-dev <<a href="mailto:pox-dev@lists.noxrepo.org">pox-dev@lists.noxrepo.org</a>>, Murphy McCauley<br>
<<a href="mailto:murphy.mccauley@gmail.com">murphy.mccauley@gmail.com</a>><br>
Subject: Re: [pox-dev] pox-dev Digest, Vol 25, Issue 17<br>
Message-ID:<br>
<<a href="mailto:CAJ11o6ph_WTGgWdc2%2BBKcyw2_rUubKTXrx2D7Omiaie5XLm6Rg@mail.gmail.com">CAJ11o6ph_WTGgWdc2+BKcyw2_rUubKTXrx2D7Omiaie5XLm6Rg@mail.gmail.com</a>><br>
Content-Type: text/plain; charset="utf-8"<br>
<br>
Hey all<br>
<br>
Is it possible to configure the servers in the ip_loadbalancer?<br>
For example, suppose I have 2 servers wherein server 1 has a larger<br>
capacity than server 2 and hence can handle increased traffic coming from<br>
the clients compared to server 2.<br>
I need to make this functionality work. Can anyone guide me?<br>
<br>
<br>
On Fri, Apr 18, 2014 at 1:38 AM, <<a href="mailto:pox-dev-request@lists.noxrepo.org">pox-dev-request@lists.noxrepo.org</a>> wrote:<br>
<br>
> Send pox-dev mailing list submissions to<br>
> <a href="mailto:pox-dev@lists.noxrepo.org">pox-dev@lists.noxrepo.org</a><br>
><br>
> To subscribe or unsubscribe via the World Wide Web, visit<br>
> <a href="http://lists.noxrepo.org/listinfo.cgi/pox-dev-noxrepo.org" target="_blank">http://lists.noxrepo.org/listinfo.cgi/pox-dev-noxrepo.org</a><br>
> or, via email, send a message with subject or body 'help' to<br>
> <a href="mailto:pox-dev-request@lists.noxrepo.org">pox-dev-request@lists.noxrepo.org</a><br>
><br>
> You can reach the person managing the list at<br>
> <a href="mailto:pox-dev-owner@lists.noxrepo.org">pox-dev-owner@lists.noxrepo.org</a><br>
><br>
> When replying, please edit your Subject line so it is more specific<br>
> than "Re: Contents of pox-dev digest..."<br>
><br>
><br>
> Today's Topics:<br>
><br>
> 1. Re: Where is the corresponding source code for the following<br>
> Object. (Murphy McCauley)<br>
> 2. Re: Where is the corresponding source code for the following<br>
> Object. (Shiyao Ma)<br>
><br>
><br>
> ----------------------------------------------------------------------<br>
><br>
> Message: 1<br>
> Date: Wed, 16 Apr 2014 13:50:28 -0700<br>
> From: Murphy McCauley <<a href="mailto:murphy.mccauley@gmail.com">murphy.mccauley@gmail.com</a>><br>
> To: Shiyao Ma <<a href="mailto:i@introo.me">i@introo.me</a>><br>
> Cc: <a href="mailto:pox-dev@lists.noxrepo.org">pox-dev@lists.noxrepo.org</a><br>
> Subject: Re: [pox-dev] Where is the corresponding source code for the<br>
> following Object.<br>
> Message-ID: <<a href="mailto:778446FC-347A-4BC8-BB5D-E5EE3F5E2DA0@gmail.com">778446FC-347A-4BC8-BB5D-E5EE3F5E2DA0@gmail.com</a>><br>
> Content-Type: text/plain; charset="iso-2022-jp"<br>
><br>
> On Apr 16, 2014, at 3:27 AM, Shiyao Ma <<a href="mailto:i@introo.me">i@introo.me</a>> wrote:<br>
><br>
> > Hi.<br>
> ><br>
> > I am following<br>
> <a href="https://github.com/noxrepo/pox/blob/carp/pox/forwarding/l2_learning.py#L121" target="_blank">https://github.com/noxrepo/pox/blob/carp/pox/forwarding/l2_learning.py#L121</a><br>
> > I wonder where is the corresponding source for that event obj (The<br>
> relevant class definition), so I can know what the event.attr stands for<br>
> and how many attrs the event has.<br>
><br>
> This is a PacketIn event handler, so the event object is a PacketIn. You<br>
> can either grep the codebase for "class PacketIn", or you can look up the<br>
> PacketIn event in the POX manual. It's in a subsection called "PacketIn"<br>
> under "OpenFlow Events: Responding to Switches".<br>
><br>
> > Also, I'd like to know the relevant class for the connection object.<br>
> <a href="https://github.com/noxrepo/pox/blob/carp/pox/forwarding/l2_learning.py#L86" target="_blank">https://github.com/noxrepo/pox/blob/carp/pox/forwarding/l2_learning.py#L86</a><br>
><br>
> The connection object is from a class called Connection. You can search<br>
> the codebase for "class Connection", or you can look it up in the manual.<br>
> It's in a subsection called "Connection Objects".<br>
><br>
><br>
> For either or both of these, you could also use Python to find the answers<br>
> for you. For example, to find the class of the connection, object, insert<br>
> the following near line 86 of l2_learning:<br>
> import inspect<br>
> print inspect.getsourcefile(type(connection)),<br>
> inspect.getsourcelines(type(connection))[1]<br>
><br>
> Et voila, it'll print out the file and line number of the class. Or<br>
> simply insert "help(connection)" to get the whole pydoc for it. Or save it<br>
> to a global variable, run the POX "py" module, and then do "help(<global<br>
> variable name>)" from the commandline.<br>
><br>
><br>
> Hope that helps.<br>
><br>
> -- Murphy<br>
><br>
> > Thanks and regards.<br>
> > --<br>
> ><br>
> > ????????????????<a href="http://introo.me" target="_blank">http://introo.me</a>?<br>
><br>
> -------------- next part --------------<br>
> An HTML attachment was scrubbed...<br>
> URL: <<br>
> <a href="http://lists.noxrepo.org/pipermail/pox-dev-noxrepo.org/attachments/20140416/8b20c55c/attachment.html" target="_blank">http://lists.noxrepo.org/pipermail/pox-dev-noxrepo.org/attachments/20140416/8b20c55c/attachment.html</a><br>
> ><br>
><br>
> ------------------------------<br>
><br>
> Message: 2<br>
> Date: Thu, 17 Apr 2014 10:35:22 +0800<br>
> From: Shiyao Ma <<a href="mailto:i@introo.me">i@introo.me</a>><br>
> To: Murphy McCauley <<a href="mailto:murphy.mccauley@gmail.com">murphy.mccauley@gmail.com</a>><br>
> Cc: <a href="mailto:pox-dev@lists.noxrepo.org">pox-dev@lists.noxrepo.org</a><br>
> Subject: Re: [pox-dev] Where is the corresponding source code for the<br>
> following Object.<br>
> Message-ID:<br>
> <CAJQX3Dzvp-ccBVpySqEsx=<br>
> <a href="mailto:19EcAAqAyoNfb0QQ4AzxV2xbN-Jg@mail.gmail.com">19EcAAqAyoNfb0QQ4AzxV2xbN-Jg@mail.gmail.com</a>><br>
> Content-Type: text/plain; charset="iso-2022-jp"<br>
><br>
> Thanks and especially for the three methods.<br>
><br>
><br>
> Regards.<br>
><br>
><br>
> 2014-04-17 4:50 GMT+08:00 Murphy McCauley <<a href="mailto:murphy.mccauley@gmail.com">murphy.mccauley@gmail.com</a>>:<br>
><br>
> > On Apr 16, 2014, at 3:27 AM, Shiyao Ma <<a href="mailto:i@introo.me">i@introo.me</a>> wrote:<br>
> ><br>
> > Hi.<br>
> ><br>
> > I am following<br>
> ><br>
> <a href="https://github.com/noxrepo/pox/blob/carp/pox/forwarding/l2_learning.py#L121" target="_blank">https://github.com/noxrepo/pox/blob/carp/pox/forwarding/l2_learning.py#L121</a><br>
> > I wonder where is the corresponding source for that event obj (The<br>
> > relevant class definition), so I can know what the event.attr stands for<br>
> > and how many attrs the event has.<br>
> ><br>
> ><br>
> > This is a PacketIn event handler, so the event object is a PacketIn. You<br>
> > can either grep the codebase for "class PacketIn", or you can look up the<br>
> > PacketIn event in the POX manual. It's in a subsection called "PacketIn"<br>
> > under "OpenFlow Events: Responding to Switches".<br>
> ><br>
> > Also, I'd like to know the relevant class for the connection object.<br>
> ><br>
> <a href="https://github.com/noxrepo/pox/blob/carp/pox/forwarding/l2_learning.py#L86" target="_blank">https://github.com/noxrepo/pox/blob/carp/pox/forwarding/l2_learning.py#L86</a><br>
> ><br>
> ><br>
> > The connection object is from a class called Connection. You can search<br>
> > the codebase for "class Connection", or you can look it up in the manual.<br>
> > It's in a subsection called "Connection Objects".<br>
> ><br>
> ><br>
> > For either or both of these, you could also use Python to find the<br>
> answers<br>
> > for you. For example, to find the class of the connection, object,<br>
> insert<br>
> > the following near line 86 of l2_learning:<br>
> > import inspect<br>
> > print inspect.getsourcefile(type(connection)),<br>
> > inspect.getsourcelines(type(connection))[1]<br>
> ><br>
> > Et voila, it'll print out the file and line number of the class. Or<br>
> > simply insert "help(connection)" to get the whole pydoc for it. Or save<br>
> it<br>
> > to a global variable, run the POX "py" module, and then do "help(<global<br>
> > variable name>)" from the commandline.<br>
> ><br>
> ><br>
> > Hope that helps.<br>
> ><br>
> > -- Murphy<br>
> ><br>
> > Thanks and regards.<br>
> > --<br>
> ><br>
> > ????????????????<a href="http://introo.me" target="_blank">http://introo.me</a>?<br>
> ><br>
> ><br>
> ><br>
><br>
><br>
> --<br>
><br>
> ????????????????<a href="http://introo.me" target="_blank">http://introo.me</a>?<br>
> -------------- next part --------------<br>
> An HTML attachment was scrubbed...<br>
> URL: <<br>
> <a href="http://lists.noxrepo.org/pipermail/pox-dev-noxrepo.org/attachments/20140417/0b6d4011/attachment-0001.htm" target="_blank">http://lists.noxrepo.org/pipermail/pox-dev-noxrepo.org/attachments/20140417/0b6d4011/attachment-0001.htm</a><br>
> ><br>
><br>
> ------------------------------<br>
><br>
> _______________________________________________<br>
> pox-dev mailing list<br>
> <a href="mailto:pox-dev@lists.noxrepo.org">pox-dev@lists.noxrepo.org</a><br>
> <a href="http://lists.noxrepo.org/listinfo.cgi/pox-dev-noxrepo.org" target="_blank">http://lists.noxrepo.org/listinfo.cgi/pox-dev-noxrepo.org</a><br>
><br>
><br>
> End of pox-dev Digest, Vol 25, Issue 17<br>
> ***************************************<br>
><br>
-------------- next part --------------<br>
An HTML attachment was scrubbed...<br>
URL: <<a href="http://lists.noxrepo.org/pipermail/pox-dev-noxrepo.org/attachments/20140423/05c88ad6/attachment-0001.htm" target="_blank">http://lists.noxrepo.org/pipermail/pox-dev-noxrepo.org/attachments/20140423/05c88ad6/attachment-0001.htm</a>><br>
<br>
------------------------------<br>
<br>
Message: 3<br>
Date: Tue, 22 Apr 2014 21:34:01 -0700<br>
From: Murphy McCauley <<a href="mailto:murphy.mccauley@gmail.com">murphy.mccauley@gmail.com</a>><br>
To: shads s <<a href="mailto:shasi0625@gmail.com">shasi0625@gmail.com</a>><br>
Cc: pox-dev <<a href="mailto:pox-dev@lists.noxrepo.org">pox-dev@lists.noxrepo.org</a>><br>
Subject: Re: [pox-dev] Prioritized servers in ip_loadbalancer<br>
Message-ID: <<a href="mailto:482D16FA-713A-4A70-A6C1-025F104CBE2C@gmail.com">482D16FA-713A-4A70-A6C1-025F104CBE2C@gmail.com</a>><br>
Content-Type: text/plain; charset="us-ascii"<br>
<br>
Override _pick_server() in the iplb class to not do it at random.<br>
<br>
-- Murphy<br>
<br>
On Apr 22, 2014, at 9:26 PM, shads s <<a href="mailto:shasi0625@gmail.com">shasi0625@gmail.com</a>> wrote:<br>
<br>
> Hey all<br>
><br>
> Is it possible to configure the servers in the ip_loadbalancer?<br>
> For example, suppose I have 2 servers wherein server 1 has a larger capacity than server 2 and hence can handle increased traffic coming from the clients compared to server 2.<br>
> I need to make this functionality work. Can anyone guide me?<br>
><br>
><br>
> On Fri, Apr 18, 2014 at 1:38 AM, <<a href="mailto:pox-dev-request@lists.noxrepo.org">pox-dev-request@lists.noxrepo.org</a>> wrote:<br>
> Send pox-dev mailing list submissions to<br>
> <a href="mailto:pox-dev@lists.noxrepo.org">pox-dev@lists.noxrepo.org</a><br>
><br>
> To subscribe or unsubscribe via the World Wide Web, visit<br>
> <a href="http://lists.noxrepo.org/listinfo.cgi/pox-dev-noxrepo.org" target="_blank">http://lists.noxrepo.org/listinfo.cgi/pox-dev-noxrepo.org</a><br>
> or, via email, send a message with subject or body 'help' to<br>
> <a href="mailto:pox-dev-request@lists.noxrepo.org">pox-dev-request@lists.noxrepo.org</a><br>
><br>
> You can reach the person managing the list at<br>
> <a href="mailto:pox-dev-owner@lists.noxrepo.org">pox-dev-owner@lists.noxrepo.org</a><br>
><br>
> When replying, please edit your Subject line so it is more specific<br>
> than "Re: Contents of pox-dev digest..."<br>
><br>
><br>
> Today's Topics:<br>
><br>
> 1. Re: Where is the corresponding source code for the following<br>
> Object. (Murphy McCauley)<br>
> 2. Re: Where is the corresponding source code for the following<br>
> Object. (Shiyao Ma)<br>
><br>
><br>
> ----------------------------------------------------------------------<br>
><br>
> Message: 1<br>
> Date: Wed, 16 Apr 2014 13:50:28 -0700<br>
> From: Murphy McCauley <<a href="mailto:murphy.mccauley@gmail.com">murphy.mccauley@gmail.com</a>><br>
> To: Shiyao Ma <<a href="mailto:i@introo.me">i@introo.me</a>><br>
> Cc: <a href="mailto:pox-dev@lists.noxrepo.org">pox-dev@lists.noxrepo.org</a><br>
> Subject: Re: [pox-dev] Where is the corresponding source code for the<br>
> following Object.<br>
> Message-ID: <<a href="mailto:778446FC-347A-4BC8-BB5D-E5EE3F5E2DA0@gmail.com">778446FC-347A-4BC8-BB5D-E5EE3F5E2DA0@gmail.com</a>><br>
> Content-Type: text/plain; charset="iso-2022-jp"<br>
><br>
> On Apr 16, 2014, at 3:27 AM, Shiyao Ma <<a href="mailto:i@introo.me">i@introo.me</a>> wrote:<br>
><br>
> > Hi.<br>
> ><br>
> > I am following <a href="https://github.com/noxrepo/pox/blob/carp/pox/forwarding/l2_learning.py#L121" target="_blank">https://github.com/noxrepo/pox/blob/carp/pox/forwarding/l2_learning.py#L121</a><br>
> > I wonder where is the corresponding source for that event obj (The relevant class definition), so I can know what the event.attr stands for and how many attrs the event has.<br>
><br>
> This is a PacketIn event handler, so the event object is a PacketIn. You can either grep the codebase for "class PacketIn", or you can look up the PacketIn event in the POX manual. It's in a subsection called "PacketIn" under "OpenFlow Events: Responding to Switches".<br>
><br>
> > Also, I'd like to know the relevant class for the connection object. <a href="https://github.com/noxrepo/pox/blob/carp/pox/forwarding/l2_learning.py#L86" target="_blank">https://github.com/noxrepo/pox/blob/carp/pox/forwarding/l2_learning.py#L86</a><br>
><br>
> The connection object is from a class called Connection. You can search the codebase for "class Connection", or you can look it up in the manual. It's in a subsection called "Connection Objects".<br>
><br>
><br>
> For either or both of these, you could also use Python to find the answers for you. For example, to find the class of the connection, object, insert the following near line 86 of l2_learning:<br>
> import inspect<br>
> print inspect.getsourcefile(type(connection)), inspect.getsourcelines(type(connection))[1]<br>
><br>
> Et voila, it'll print out the file and line number of the class. Or simply insert "help(connection)" to get the whole pydoc for it. Or save it to a global variable, run the POX "py" module, and then do "help(<global variable name>)" from the commandline.<br>
><br>
><br>
> Hope that helps.<br>
><br>
> -- Murphy<br>
><br>
> > Thanks and regards.<br>
> > --<br>
> ><br>
> > ????????????????<a href="http://introo.me" target="_blank">http://introo.me</a>?<br>
><br>
> -------------- next part --------------<br>
> An HTML attachment was scrubbed...<br>
> URL: <<a href="http://lists.noxrepo.org/pipermail/pox-dev-noxrepo.org/attachments/20140416/8b20c55c/attachment.html" target="_blank">http://lists.noxrepo.org/pipermail/pox-dev-noxrepo.org/attachments/20140416/8b20c55c/attachment.html</a>><br>
><br>
> ------------------------------<br>
><br>
> Message: 2<br>
> Date: Thu, 17 Apr 2014 10:35:22 +0800<br>
> From: Shiyao Ma <<a href="mailto:i@introo.me">i@introo.me</a>><br>
> To: Murphy McCauley <<a href="mailto:murphy.mccauley@gmail.com">murphy.mccauley@gmail.com</a>><br>
> Cc: <a href="mailto:pox-dev@lists.noxrepo.org">pox-dev@lists.noxrepo.org</a><br>
> Subject: Re: [pox-dev] Where is the corresponding source code for the<br>
> following Object.<br>
> Message-ID:<br>
> <CAJQX3Dzvp-ccBVpySqEsx=<a href="mailto:19EcAAqAyoNfb0QQ4AzxV2xbN-Jg@mail.gmail.com">19EcAAqAyoNfb0QQ4AzxV2xbN-Jg@mail.gmail.com</a>><br>
> Content-Type: text/plain; charset="iso-2022-jp"<br>
><br>
> Thanks and especially for the three methods.<br>
><br>
><br>
> Regards.<br>
><br>
><br>
> 2014-04-17 4:50 GMT+08:00 Murphy McCauley <<a href="mailto:murphy.mccauley@gmail.com">murphy.mccauley@gmail.com</a>>:<br>
><br>
> > On Apr 16, 2014, at 3:27 AM, Shiyao Ma <<a href="mailto:i@introo.me">i@introo.me</a>> wrote:<br>
> ><br>
> > Hi.<br>
> ><br>
> > I am following<br>
> > <a href="https://github.com/noxrepo/pox/blob/carp/pox/forwarding/l2_learning.py#L121" target="_blank">https://github.com/noxrepo/pox/blob/carp/pox/forwarding/l2_learning.py#L121</a><br>
> > I wonder where is the corresponding source for that event obj (The<br>
> > relevant class definition), so I can know what the event.attr stands for<br>
> > and how many attrs the event has.<br>
> ><br>
> ><br>
> > This is a PacketIn event handler, so the event object is a PacketIn. You<br>
> > can either grep the codebase for "class PacketIn", or you can look up the<br>
> > PacketIn event in the POX manual. It's in a subsection called "PacketIn"<br>
> > under "OpenFlow Events: Responding to Switches".<br>
> ><br>
> > Also, I'd like to know the relevant class for the connection object.<br>
> > <a href="https://github.com/noxrepo/pox/blob/carp/pox/forwarding/l2_learning.py#L86" target="_blank">https://github.com/noxrepo/pox/blob/carp/pox/forwarding/l2_learning.py#L86</a><br>
> ><br>
> ><br>
> > The connection object is from a class called Connection. You can search<br>
> > the codebase for "class Connection", or you can look it up in the manual.<br>
> > It's in a subsection called "Connection Objects".<br>
> ><br>
> ><br>
> > For either or both of these, you could also use Python to find the answers<br>
> > for you. For example, to find the class of the connection, object, insert<br>
> > the following near line 86 of l2_learning:<br>
> > import inspect<br>
> > print inspect.getsourcefile(type(connection)),<br>
> > inspect.getsourcelines(type(connection))[1]<br>
> ><br>
> > Et voila, it'll print out the file and line number of the class. Or<br>
> > simply insert "help(connection)" to get the whole pydoc for it. Or save it<br>
> > to a global variable, run the POX "py" module, and then do "help(<global<br>
> > variable name>)" from the commandline.<br>
> ><br>
> ><br>
> > Hope that helps.<br>
> ><br>
> > -- Murphy<br>
> ><br>
> > Thanks and regards.<br>
> > --<br>
> ><br>
> > ????????????????<a href="http://introo.me" target="_blank">http://introo.me</a>?<br>
> ><br>
> ><br>
> ><br>
><br>
><br>
> --<br>
><br>
> ????????????????<a href="http://introo.me" target="_blank">http://introo.me</a>?<br>
> -------------- next part --------------<br>
> An HTML attachment was scrubbed...<br>
> URL: <<a href="http://lists.noxrepo.org/pipermail/pox-dev-noxrepo.org/attachments/20140417/0b6d4011/attachment-0001.htm" target="_blank">http://lists.noxrepo.org/pipermail/pox-dev-noxrepo.org/attachments/20140417/0b6d4011/attachment-0001.htm</a>><br>
><br>
> ------------------------------<br>
><br>
> _______________________________________________<br>
> pox-dev mailing list<br>
> <a href="mailto:pox-dev@lists.noxrepo.org">pox-dev@lists.noxrepo.org</a><br>
> <a href="http://lists.noxrepo.org/listinfo.cgi/pox-dev-noxrepo.org" target="_blank">http://lists.noxrepo.org/listinfo.cgi/pox-dev-noxrepo.org</a><br>
><br>
><br>
> End of pox-dev Digest, Vol 25, Issue 17<br>
> ***************************************<br>
><br>
<br>
-------------- next part --------------<br>
An HTML attachment was scrubbed...<br>
URL: <<a href="http://lists.noxrepo.org/pipermail/pox-dev-noxrepo.org/attachments/20140422/f0ed7f29/attachment.htm" target="_blank">http://lists.noxrepo.org/pipermail/pox-dev-noxrepo.org/attachments/20140422/f0ed7f29/attachment.htm</a>><br>
<br>
------------------------------<br>
<br>
_______________________________________________<br>
pox-dev mailing list<br>
<a href="mailto:pox-dev@lists.noxrepo.org">pox-dev@lists.noxrepo.org</a><br>
<a href="http://lists.noxrepo.org/listinfo.cgi/pox-dev-noxrepo.org" target="_blank">http://lists.noxrepo.org/listinfo.cgi/pox-dev-noxrepo.org</a><br>
<br>
<br>
End of pox-dev Digest, Vol 25, Issue 23<br>
***************************************<br>
</blockquote></div><br></div>