On Feb 20, 2014, at 4:35 AM, ㄜˊ ㄋㄣˋ ㄜˊ ㄋㄣˋ <rabbi...@hotmail.com> wrote:

> Recently, I am research on openflow to control my virtual machine 
> 
> I have question about libopenflow_01:
> what is @openflow_action ('OFPAT_SET_VLAN_VID', 1) at class 
> ofp_action_vlan_vid
> I am so confuse about "1" .. is the argument? 

This is a decorator which is used internally by libopenflow.  You don't need to 
worry about it.  If you really want to understand what is going on, you can 
read the code and/or about Python decorators.  The short answer is that 
OFPAT_SET_VLAN_VID is specified on the wire as having a value of 1, and this is 
how libopenflow knows that.

> And the other question is that It is possible to create vxlan just like 
> ofp_action_vlan_vid to set vxlan VNI ? 

There's nothing about VXLAN in the OpenFlow 1.0 specification.  So no.  Unless 
you add it to the protocol, the controller, and the switch.  More than one 
vendor has probably already done the first and last of these.  For example, you 
can do this in Open vSwitch.  If I recall, in POX, this would be through the 
openflow.nicira component which lets you set the "tunnel ID" on a virtual port 
associated with a VXLAN tunnel.

-- Murphy

Reply via email to