Open er1cthe0ne opened 4 years ago
@er1cthe0ne I will look at this. And also i need to see the OVS documentation and the current l3 design.
As the DHCP feature enhancement is done, I believe we can start looking into this feature as well @Gzure .
@Gzure - see this wiki page on the current layout of openflow table and how we want to update it for on demand routing rules. https://github.com/futurewei-cloud/alcor-control-agent/wiki/Openflow-Tables-Explain
@er1cthe0ne I see the docs which about on demand routing rules, I have some questions:
Also, the on demand rule: (on demand rule) table=55, priority=50,dl_vlan=[VLAN tag of network 1],dl_dst=[mac of GW for network 1] actions=
‘strip_vlan,load:[VLAN tag of network 2->NXM_NX_TUN_ID[],‘ - Replace to network 2 VLAN tag
‘mod_dl_dst=[destination VM MAC]‘ – replace the GW mac to destination VM’s MAC
‘actions=NORMAL‘
need add 'nw_dst' match field.
@er1cthe0ne I see the docs which about on demand routing rules, I have some questions:
- We will store all neighbor info in memory, do we need to store them in DB?
Store in DB will be the next step, for now, we can store it in memory: _routers_table->neighbor_ports->neighbor_port_table_entry
- How do we handle South-North case?
For the case where there is no routing match with L3 neighbor, or routing rule match, I am thinking to install an on demand rule to send the traffic to some default external gateway. We don't have that working flow completed yet.
need add 'nw_dst' match field.
Yes, it is in the code below but missed in the doc. Feel free to update the doc as we work on the implementation :)
cmd_string = "add-flow br-tun \"table=0,priority=50,ip,dl_vlan=" +
to_string(source_vlan_id) + ",nw_dst=" + virtual_ip +
",dl_dst=" + subnet_it->second.gateway_mac +
" actions=mod_vlan_vid:" + to_string(destination_vlan_id) +
",mod_dl_src:" + _host_dvr_mac +
",mod_dl_dst:" + virtual_mac + ",resubmit(,2)\"";
For on demand ovs rule programming for L3 routing, we have the design in place: https://github.com/futurewei-cloud/alcor/blob/master/docs/modules/ROOT/pages/high_level/routing_design.adoc
And the current code in ACA already have the framework ready, need to add implementation and corresponding testing.