Re: [Ryu-devel] Extracting field value

2013-03-25 Thread FUJITA Tomonori
On Mon, 25 Mar 2013 16:56:48 + Bright Dadson wrote: > This is what I thought initially but when I log the values held in > msg.match.fields as shown below; > > match = msg.match.fields > for field in match: > logger.info("++> %s ",field.value) > > I only get data

Re: [Ryu-devel] Extracting field value

2013-03-25 Thread FUJITA Tomonori
On Mon, 25 Mar 2013 15:58:37 + Bright Dadson wrote: > I have created a flow which sets a match field in an action as shown below; > > field = datapath.ofproto_parser.OFPMatchField.make( > datapath.ofproto.OXM_OF_VLAN_VID, vlan_id) > actions = > [datapath.ofpro

[Ryu-devel] Extracting field value

2013-03-25 Thread Bright Dadson
Hi guys, I have created a flow which sets a match field in an action as shown below; field = datapath.ofproto_parser.OFPMatchField.make( datapath.ofproto.OXM_OF_VLAN_VID, vlan_id) actions = [datapath.ofproto_parser.OFPActionPushVlan(VLAN_TAG_802_1Q),

Re: [Ryu-devel] get the ovs's address by ryu

2013-03-25 Thread Isaku Yamahata
Ryu is able to talk Open vSwitch db protocol directly. get/set-controller command is available. It's equivalent of ovs-vsctl get/set-controller. See ryu.lib.ovs.vsctl.py. The real usage is in ryu.app.quantum_adapter.OVSSwitch.set_ovsdb_addr. It uses set-controller. You can easily understand the cas

Re: [Ryu-devel] [PATCH] ofproto_parser: dump packets if error is encountered during parse

2013-03-25 Thread can.
Hello, 2013/3/25 Isaku Yamahata > > > Before message, didn't you find something like the following? > (If no, it should be fixed.) > 'This implies switch sending a malfold OpenFlow packet.' > 'version 0x%02x msg_type %d msg_len %d xid %d buf %s' > > Yep, I missed them :| Below are two of them.

Re: [Ryu-devel] [PATCH] ofproto_parser: dump packets if error is encountered during parse

2013-03-25 Thread Isaku Yamahata
Thank you for testing. On Mon, Mar 25, 2013 at 03:23:15PM +0800, can. wrote: > Hello, > > I tried to apply your patch to the latest master on github, but got an error > at > line 12: > > fatal: corrupt patch at line 12 > (the line with "import struct") Oops, will fix. > So I manually patche

Re: [Ryu-devel] [PATCH] ryu-manager: use try-finally statement

2013-03-25 Thread OHMURA Kei
2013/3/25 FUJITA Tomonori : > On Fri, 22 Mar 2013 14:29:35 +0900 > OHMURA Kei wrote: > >> This fixes a problem that app_mgr.close() is not called when >> KeyboardInterrupt exception occurs. > > What's a real problem if app_mgr.close() is not called when I stop the > program by hitting ctrl-c? I f

[Ryu-devel] get the ovs's address by ryu

2013-03-25 Thread 赵美美
Hi Guys, As we all know,it is easy to modify the open vswitch'default tcp port(6634) using 'listenPort', but I want to find if there is a method or ofp message in ryu to get the open vswitch'tcp address and port when the open vswitch connect to the controller(ryu)? It has puzzled me all day. Can

[Ryu-devel] [PATCH 0/2] add snort_alert support

2013-03-25 Thread OHMURA Kei
Hi, these patches implement snort_alert parser and snort_alert monitoring library. I think that it is important for Ryu to collaborate with security tools such as snort. OHMURA Kei (2): snort: add snort_alert parser snort: add snort_alert monitor ryu/lib/snort/alert.py | 125 +++

[Ryu-devel] [PATCH 1/2] snort: add snort_alert parser

2013-03-25 Thread OHMURA Kei
Signed-off-by: OHMURA Kei --- ryu/lib/snort/alert.py | 125 1 file changed, 125 insertions(+) create mode 100644 ryu/lib/snort/__init__.py create mode 100644 ryu/lib/snort/alert.py diff --git a/ryu/lib/snort/__init__.py b/ryu/lib/snort/__init__

[Ryu-devel] [PATCH 2/2] snort: add snort_alert monitor

2013-03-25 Thread OHMURA Kei
This library gets snort_alert packet and sends it to the Ryu applications. Signed-off-by: OHMURA Kei --- ryu/lib/snort/alert_monitor.py | 61 1 file changed, 61 insertions(+) create mode 100644 ryu/lib/snort/alert_monitor.py diff --git a/ryu/lib/snort

Re: [Ryu-devel] [PATCH] ofproto_parser: dump packets if error is encountered during parse

2013-03-25 Thread can.
Hello, I tried to apply your patch to the latest master on github, but got an error at line 12: fatal: corrupt patch at line 12 (the line with "import struct") So I manually patched it, and found that the error is still: Error in the datapath 2 from ('10.109.242.118', 57275) Traceback (most rec