Re: [Ryu-devel] How to pop vlan tag

2015-07-02 Thread 澤田和宏
Hi, Thank you for your quick reply. >First of all, I think it's not a good solution to pop tags on >controller. The reasons are listed below: > 1. all packets arrived controller via packetin event. The origin packets is encapsulated to be the payload of openflow message. >2. it's an ineffi

Re: [Ryu-devel] How to pop vlan tag

2015-07-02 Thread chenl...@gmail.com
Hi 澤田和宏, First of all, I think it's not a good solution to pop tags on controller. The reasons are listed below: 1. all packets arrived controller via packetin event. The origin packets is encapsulated to be the payload of openflow message. 2. it's an ineffictive when the traffic become

[Ryu-devel] [PATCH] travis: run tests with python3

2015-07-02 Thread FUJITA Tomonori
Signed-off-by: FUJITA Tomonori --- .travis.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.travis.yml b/.travis.yml index 80b25ae..cc1d109 100644 --- a/.travis.yml +++ b/.travis.yml @@ -5,6 +5,7 @@ python: env: - TOX_ENV=py26 - TOX_ENV=py27 + - TOX_ENV=py34 - TOX_ENV=pep8

Re: [Ryu-devel] [PATCH 00/13] Add python3 support

2015-07-02 Thread FUJITA Tomonori
On Fri, 3 Jul 2015 11:27:05 +0900 IWAMOTO Toshihiro wrote: > With these changes, unit tests passes on python3.4. > > IWAMOTO Toshihiro (13): > python3: Store AsciiStringType class data as str > python3: Use six.indexbytes for extracting single byte of data > python3: Partially revert b'st

[Ryu-devel] How to delete flow table and group table in of1.3

2015-07-02 Thread Vinllen Chen
Hi, Dear all: I want to delete some flow tables match the given conditions and delete group table witch specified group id. Do you have any example ? -- Best Regards, Vinllen -- Don't Limit Your Business. Reach for t

[Ryu-devel] How to pop vlan tag

2015-07-02 Thread 澤田和宏
Hello there, I am a newbie to OpenFlow and Ryu. I am trying to pop double tag which tagged by cisco's dot1q-tunnel. It is such a packet. - No. Time SourceDestination Protoc

Re: [Ryu-devel] [PATCH 3/7] python3: Use six.binary_type for I/O of ryu.lib.rpc

2015-07-02 Thread IWAMOTO Toshihiro
At Tue, 30 Jun 2015 22:57:32 +0900 (JST), FUJITA Tomonori wrote: > > On Tue, 30 Jun 2015 17:09:48 +0900 > IWAMOTO Toshihiro wrote: > > > At Tue, 30 Jun 2015 17:01:54 +0900, > > IWAMOTO Toshihiro wrote: > >> > >> While msgpack has default binary-unicode conversion, the feature is > >> somehow di

[Ryu-devel] [PATCH 13/13] python3: Convert chr to six.int2byte

2015-07-02 Thread IWAMOTO Toshihiro
Signed-off-by: IWAMOTO Toshihiro --- ryu/lib/packet/bgp.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ryu/lib/packet/bgp.py b/ryu/lib/packet/bgp.py index 80e56c1..b5d85d2 100644 --- a/ryu/lib/packet/bgp.py +++ b/ryu/lib/packet/bgp.py @@ -750,7 +750,8 @@ class _AddrPrefi

[Ryu-devel] [PATCH 07/13] python3: Use b'str' for binary data

2015-07-02 Thread IWAMOTO Toshihiro
Signed-off-by: IWAMOTO Toshihiro --- ryu/lib/packet/bgp.py| 6 ++--- ryu/lib/packet/cfm.py| 18 +++ ryu/tests/unit/packet/test_bgp.py| 44 ++-- ryu/tests/unit/packet/test_bmp.py| 16 ++--- ryu/tests/unit/

[Ryu-devel] [PATCH 09/13] python3: Round time() return value to microseconds

2015-07-02 Thread IWAMOTO Toshihiro
Signed-off-by: IWAMOTO Toshihiro --- ryu/tests/unit/packet/test_bmp.py | 13 + 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/ryu/tests/unit/packet/test_bmp.py b/ryu/tests/unit/packet/test_bmp.py index f943370..f93b801 100644 --- a/ryu/tests/unit/packet/test_bmp.py +++

[Ryu-devel] [PATCH 10/13] python3: Misc str related fixups

2015-07-02 Thread IWAMOTO Toshihiro
In python2, binary_type + bytearray gives bytearray, but it gives binary_type in python3. Make sure the result is bytearray in both cases. Also, remove some redundunt str()s rather than converting them to six.binary_type. Signed-off-by: IWAMOTO Toshihiro --- ryu/tests/unit/packet/test_icmp.py

[Ryu-devel] [PATCH 11/13] Use the asciilist type for lists of ip addresses

2015-07-02 Thread IWAMOTO Toshihiro
Signed-off-by: IWAMOTO Toshihiro --- ryu/lib/packet/cfm.py| 5 + ryu/lib/packet/icmpv6.py | 21 + ryu/lib/packet/igmp.py | 16 ryu/lib/packet/ipv6.py | 5 + 4 files changed, 47 insertions(+) diff --git a/ryu/lib/packet/cfm.py b/ryu/lib/packe

[Ryu-devel] [PATCH 02/13] python3: Use six.indexbytes for extracting single byte of data

2015-07-02 Thread IWAMOTO Toshihiro
Signed-off-by: IWAMOTO Toshihiro --- ryu/lib/packet/bfd.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ryu/lib/packet/bfd.py b/ryu/lib/packet/bfd.py index 8818da8..e12fec5 100644 --- a/ryu/lib/packet/bfd.py +++ b/ryu/lib/packet/bfd.py @@ -80,6 +80,7 @@ BFD Control pa

[Ryu-devel] [PATCH 06/13] python3: Convert str to six.binary_type

2015-07-02 Thread IWAMOTO Toshihiro
Signed-off-by: IWAMOTO Toshihiro --- ryu/lib/packet/icmpv6.py | 18 +-- ryu/lib/packet/igmp.py | 9 +++--- ryu/lib/packet/packet.py | 3 +- ryu/lib/packet/sctp.py | 30 +- ryu/lib/packet/tcp.py | 3 +- ryu/tests/u

[Ryu-devel] [PATCH 01/13] python3: Store AsciiStringType class data as str

2015-07-02 Thread IWAMOTO Toshihiro
AsciiStringType data are mostly IP addresses and they must be text_type in python3 for text_to_bin to work. Also introduce AsciiStringListType, which is suitable for lists of IP addresses. Signed-off-by: IWAMOTO Toshihiro --- ryu/lib/stringify.py | 31 +-- 1 file chan

[Ryu-devel] [PATCH 00/13] Add python3 support

2015-07-02 Thread IWAMOTO Toshihiro
With these changes, unit tests passes on python3.4. IWAMOTO Toshihiro (13): python3: Store AsciiStringType class data as str python3: Use six.indexbytes for extracting single byte of data python3: Partially revert b'str' conversion python3: Use {encode,decode}('ascii') for text packet data

[Ryu-devel] [PATCH 12/13] Fix test packet data generation

2015-07-02 Thread IWAMOTO Toshihiro
They are bugs found during python3 compatibility work. Signed-off-by: IWAMOTO Toshihiro --- ryu/tests/unit/packet/test_packet.py | 2 +- ryu/tests/unit/packet/test_slow.py | 8 +--- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/ryu/tests/unit/packet/test_packet.py b/ryu/t

[Ryu-devel] [PATCH 08/13] python3: Adapt to iterator change

2015-07-02 Thread IWAMOTO Toshihiro
Use next(i) instead of i.next() for iteration, which works both in python2 and 3. Signed-off-by: IWAMOTO Toshihiro --- ryu/tests/unit/packet/test_bfd.py | 32 ryu/tests/unit/packet/test_lldp.py | 8 2 files changed, 20 insertions(+), 20 deletions(-) d

[Ryu-devel] [PATCH 05/13] packet_utils: Remove checksum() side-effect

2015-07-02 Thread IWAMOTO Toshihiro
checksum() was modifying argument when it is bytearray. Make sure checksum() doesn't modify its argument. Signed-off-by: IWAMOTO Toshihiro --- ryu/lib/packet/packet_utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ryu/lib/packet/packet_utils.py b/ryu/lib/packet/packe

[Ryu-devel] [PATCH 03/13] python3: Partially revert b'str' conversion

2015-07-02 Thread IWAMOTO Toshihiro
This patch partially reverts 75e8c58916524243e6796e73c371981e14fff6ee and 536a42d8c1c0be48e78d5f29b6fd55a38012d953. dhcp.sname is ascii. Signed-off-by: IWAMOTO Toshihiro --- ryu/lib/packet/dhcp.py | 2 +- ryu/tests/unit/packet/test_dhcp.py | 6 +++--- 2 files changed, 4 insertions(+

[Ryu-devel] [PATCH 04/13] python3: Use {encode, decode}('ascii') for text packet data

2015-07-02 Thread IWAMOTO Toshihiro
Some packet data are ascii type. Use {encode,decode} to make python3's struct.pack happy. Signed-off-by: IWAMOTO Toshihiro --- ryu/lib/packet/dhcp.py | 5 +++-- ryu/topology/switches.py | 4 ++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/ryu/lib/packet/dhcp.py b/ryu/lib/p

Re: [Ryu-devel] communication between controllers

2015-07-02 Thread FUJITA Tomonori
On Fri, 03 Jul 2015 00:19:15 +0430 "mehran shetabi" wrote: > In multi domain SDN, I want to have communication between controllers. How > can I do this in Ryu? Ryu doesn't have its homegrown protocol for communication between controllers. I think that using existing protocols such as bgp makes

[Ryu-devel] communication between controllers

2015-07-02 Thread mehran shetabi
Hi, In multi domain SDN, I want to have communication between controllers. How can I do this in Ryu? Thank you, ... mehran shetabi PhD student Computer Engineering Department IUST---