> Signed-off-by: Alexandra Rukomoinikova <[email protected]>
Hi Alexandra,
I think this patch needs to be rebased. Moreover, I guess we can squash it with
patch 3/4, what do you think?
Regards,
Lorenzo
> ---
> v1 --> v2: nothind changed
> ---
> tests/ovn-northd.at | 107 ++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 107 insertions(+)
>
> diff --git a/tests/ovn-northd.at b/tests/ovn-northd.at
> index 5d6ea75a6..a0a2d86b4 100644
> --- a/tests/ovn-northd.at
> +++ b/tests/ovn-northd.at
> @@ -17985,6 +17985,113 @@ AT_CHECK([cat lr1_lflow | grep lr_in_dnat | grep
> priority=120 | ovn_strip_lflows
> table=??(lr_in_dnat ), priority=120 , match=(ct.new && !ct.rel &&
> ip4 && ip4.dst == 1.1.1.1 && reg1[[16..23]] == 6 && reg1[[0..15]] == 80),
> action=(drop;)
> ])
>
> +check ovn-nbctl lb-del lb_distubuted
> +echo > northd/ovn-northd.log
> +
> +# ipv6 configuration
> +check ovn-nbctl lb-add lb1 [[2001::a]]:80 [[2001::3]]:80,[[2002::3]]:80
> +
> +check_uuid ovn-nbctl --wait=sb -- --id=@hc create \
> +Load_Balancer_Health_Check vip="\[\[2001\:\:a\]\]\:80" -- add Load_Balancer
> . \
> +health_check @hc
> +
> +check_row_count sb:Service_Monitor 0
> +check ovn-nbctl --wait=sb set load_balancer .
> ip_port_mappings:\"[[2001::3]]\"=\"lport1:[[2001::2]]\"
> +
> +check_row_count sb:Service_Monitor 1
> +ovn-sbctl list service_monitor
> +check_column "2001::3" sb:Service_Monitor ip logical_port=lport1
> +check_column 80 sb:Service_Monitor port logical_port=lport1
> +check_column tcp sb:Service_Monitor protocol logical_port=lport1
> +check_column "2001::2" sb:Service_Monitor src_ip logical_port=lport1
> +check_column false sb:Service_Monitor ic_learned logical_port=lport1
> +check_column false sb:Service_Monitor remote logical_port=lport1
> +check_column "" sb:Service_Monitor logical_input_port logical_port=lport1
> +
> +# Empty src_ip.
> +check ovn-nbctl clear load_balancer lb1 ip_port_mappings
> +check ovn-nbctl --wait=sb set load_balancer .
> ip_port_mappings:\"[[2001::3]]\"=\"lport1:\"
> +OVS_WAIT_UNTIL([grep "Invalid svc mon src IP" northd/ovn-northd.log])
> +check_row_count sb:Service_Monitor 0
> +echo > northd/ovn-northd.log
> +
> +# Uncorrect ip_address.
> +check ovn-nbctl --wait=sb set load_balancer .
> ip_port_mappings:\"[[invalid]]\"=\"lport1:\"
> +OVS_WAIT_UNTIL([grep "bad IP address" northd/ovn-northd.log])
> +echo > northd/ovn-northd.log
> +
> +check ovn-nbctl --wait=sb set load_balancer .
> ip_port_mappings:\"[[2001::3]]\"=\"lport1:invalid\"
> +OVS_WAIT_UNTIL([grep "bad IP address" northd/ovn-northd.log])
> +echo > northd/ovn-northd.log
> +
> +check ovn-nbctl --wait=sb set load_balancer .
> ip_port_mappings:\"[[2001::3]]\"=\"lport1:[[2001::2]]:az_name\"
> +check_row_count sb:Service_Monitor 1
> +ovn-sbctl list service_monitor
> +check_column "2001::3" sb:Service_Monitor ip logical_port=lport1
> +check_column 80 sb:Service_Monitor port logical_port=lport1
> +check_column tcp sb:Service_Monitor protocol logical_port=lport1
> +check_column "2001::2" sb:Service_Monitor src_ip logical_port=lport1
> +check_column false sb:Service_Monitor ic_learned logical_port=lport1
> +check_column true sb:Service_Monitor remote logical_port=lport1
> +check_column "" sb:Service_Monitor logical_input_port logical_port=lport1
> +
> +uuid=$(ovn-sbctl -d bare --no-headings --columns _uuid find Service_Monitor
> logical_port=lport1)
> +
> +# Check az_name presence in options.
> +AT_CHECK([ovn-sbctl get Service_Monitor ${uuid} options:az-name],
> +[0], [az_name
> +])
> +
> +check ovn-nbctl --wait=sb set load_balancer .
> ip_port_mappings:\"[[2001::3]]\"=\"lport1:[[2001::2]]:\"
> +check_row_count sb:Service_Monitor 0
> +OVS_WAIT_UNTIL([grep "Empty AZ name specified" northd/ovn-northd.log])
> +
> +echo > northd/ovn-northd.log
> +check ovn-nbctl lb-del lb1
> +
> +# Check correct setup of distributed load balancers.
> +check ovn-nbctl lb-add lb_distubuted [[2001::a]]:80
> [[2001::3]]:80,[[2002::3]]:80
> +check ovn-nbctl lr-lb-add lr1 lb_distubuted
> +check ovn-nbctl set load_balancer lb_distubuted options:distributed=true
> +
> +# Check that load balancer does not work in a distributed mode - there is no
> ip_port_mappings setting
> +ovn-sbctl lflow-list lr1 > lr1_lflow
> +AT_CHECK([cat lr1_lflow | grep lr_in_dnat | grep priority=120 |
> ovn_strip_lflows], [0], [dnl
> + table=??(lr_in_dnat ), priority=120 , match=(ct.new && !ct.rel &&
> ip6 && ip6.dst == 2001::a && reg1[[16..23]] == 6 && reg1[[0..15]] == 80),
> action=(drop;)
> +])
> +
> +echo > northd/ovn-northd.log
> +check ovn-nbctl set load_balancer .
> ip_port_mappings:\"[[2001::3]]\"=\"lport1\"
> +ovn-sbctl lflow-list lr1 > lr1_lflow
> +AT_CHECK([cat lr1_lflow | grep lr_in_dnat | grep priority=120 |
> ovn_strip_lflows], [0], [dnl
> + table=??(lr_in_dnat ), priority=120 , match=(ct.new && !ct.rel &&
> ip6 && ip6.dst == 2001::a && reg1[[16..23]] == 6 && reg1[[0..15]] == 80),
> action=(ct_lb_mark_local(backends="lport1":[[2001::3]]:80);)
> +])
> +
> +echo > northd/ovn-northd.log
> +check ovn-nbctl set load_balancer .
> ip_port_mappings:\"[[2002::3]]\"=\"lport2\"
> +ovn-sbctl lflow-list lr1 > lr1_lflow
> +AT_CHECK([cat lr1_lflow | grep lr_in_dnat | grep priority=120 |
> ovn_strip_lflows], [0], [dnl
> + table=??(lr_in_dnat ), priority=120 , match=(ct.new && !ct.rel &&
> ip6 && ip6.dst == 2001::a && reg1[[16..23]] == 6 && reg1[[0..15]] == 80),
> action=(ct_lb_mark_local(backends="lport1":[[2001::3]]:80,"lport2":[[2002::3]]:80);)
> +])
> +
> +echo > northd/ovn-northd.log
> +check_uuid ovn-nbctl --wait=sb -- --id=@hc create \
> +Load_Balancer_Health_Check vip="\[\[2001\:\:a\]\]\:80" -- add Load_Balancer
> . \
> +health_check @hc
> +OVS_WAIT_UNTIL([grep "Expected ':' separator for:" northd/ovn-northd.log])
> +ovn-sbctl lflow-list lr1 > lr1_lflow
> +AT_CHECK([cat lr1_lflow | grep lr_in_dnat | grep priority=120 |
> ovn_strip_lflows], [0], [dnl
> + table=??(lr_in_dnat ), priority=120 , match=(ct.new && !ct.rel &&
> ip6 && ip6.dst == 2001::a && reg1[[16..23]] == 6 && reg1[[0..15]] == 80),
> action=(drop;)
> +])
> +
> +check ovn-nbctl --wait=sb set load_balancer .
> ip_port_mappings:\"[[2001::3]]\"=\"lport1:[[2001::2]]\"
> +ovn-sbctl lflow-list lr1 > lr1_lflow
> +AT_CHECK([cat lr1_lflow | grep lr_in_dnat | grep priority=120 |
> ovn_strip_lflows], [0], [dnl
> + table=??(lr_in_dnat ), priority=120 , match=(ct.new && !ct.rel &&
> ip6 && ip6.dst == 2001::a && reg1[[16..23]] == 6 && reg1[[0..15]] == 80),
> action=(ct_lb_mark_local(backends="lport1":[[2001::3]]:80);)
> +])
> +
> +check ovn-nbctl lb-del lb_distubuted
> +
> AT_CLEANUP
> ])
>
> --
> 2.48.1
>
> _______________________________________________
> dev mailing list
> [email protected]
> https://mail.openvswitch.org/mailman/listinfo/ovs-dev
>
_______________________________________________
dev mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-dev