Bug 2223045

Summary: Router and Neighbor Advertisement not working when all traffic is blocked for a port and all ACLs are stateless
Product: Red Hat Enterprise Linux Fast Datapath Reporter: Mark Michelson <mmichels>
Component: ovn23.03Assignee: OVN Team <ovnteam>
Status: CLOSED ERRATA QA Contact: Ehsan Elahi <eelahi>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: FDP 23.BCC: ctrautma, jiji, jishi
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: ovn22.12-22.12.0-50.el9fdp Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2023-08-21 02:08:16 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Mark Michelson 2023-07-15 00:41:33 UTC
This bug was initially created as a copy of Bug #2186059

I am copying this bug because: 

The original issue is cited in an errata for fast datapath RHEL 8. This issue will be cited in an errata for fast datapath RHEL 9.


+++ This bug was initially created as a clone of Bug #2149731 +++

Description of problem:
When a stateless security group is attached to the instance it fails to get an IPv6 address using SLAAC or stateless DHCP. An explicit rule is required to allow ICMPv6 traffic.

Checked with the custom security group (only egress traffic is allowed) as well as with the default security group (egress and ingress from the same SG are allowed).



Version-Release number of selected component (if applicable):
RHOS-17.1-RHEL-9-20221115.n.2
Red Hat Enterprise Linux release 9.1 (Plow)

How reproducible:
100%


Steps to Reproduce:
openstack network create net_dual_slaac
openstack subnet create --subnet-range 10.100.1.0/24 --network net_dual_slaac subnet_dual_slaac
openstack subnet create --subnet-range 2001:0:0:1::0/64 --ip-version 6 --ipv6-ra-mode slaac --ipv6-address-mode slaac --network net_dual_slaac subnet_dual_slaac_ipv6
openstack router create router_test_boot
EXT_NET=`openstack network list --external -f value -c Name`
openstack router set --external-gateway $EXT_NET router_test_boot
openstack router add subnet router_test_boot subnet_dual_slaac
openstack security group create --stateless test_sg
openstack server create --image <IMG> --flavor <FLAV> --network net_dual_slaac --security-group test_sg vm_1

Actual results:
only IPv4 address appear on the instance


Expected results:
IPv6 address is expected

Additional info:
can be worked around by adding icmpv6 rule:
# openstack security group rule create --ingress --protocol icmpv6 test_sg

--- Additional comment from Ihar Hrachyshka on 2022-12-06 19:48:39 UTC ---

DHCPv6 should work by default for stateless SGs, same as for stateful.

--- Additional comment from Eran Kuris on 2023-03-02 10:29:52 UTC ---

Hi Ihar, 
can you update regarding the fix of this issue?

--- Additional comment from Ihar Hrachyshka on 2023-03-28 12:36:54 UTC ---

Status update:

1) patches are posted in upstream;
2) upstream reviewers (Slawek and Rodolfo) suggested that this topic needs more elaboration and discussion since they don't necessarily agree with the assumption that both metadata and ipv6 dhcp should work by default for stateless SGs; (I disagree)
3) they suggested to have a discussion on this topic during the vPTG this week; specifically, this Wed at 9am EST we'll discuss this exact topic;
4) once we have a resolution on what can be implemented upstream, I will work on adjusting the existing patches to upstream (if needed) this Friday.

Note that the above suggests that we may not have the bug fixed as expected in the test plan; at least upstream. So we may have to adjust the test plan maybe? The discussion this Wed should clarify what's possible in upstream.

--- Additional comment from Ihar Hrachyshka on 2023-04-12 01:47:28 UTC ---

I now believe that the bug is not for Neutron to fix (though it's technically possible). It's an inconsistency between "pure stateless" and "mixed-stateful" networks in OVN northd implementation. This should be fixed by: https://patchwork.ozlabs.org/project/ovn/list/?series=350425 (currently on review).

This bug should probably become a test tracker for a clone to ovn component where the actual fix belongs.

Comment 4 Ehsan Elahi 2023-07-21 06:30:00 UTC
Following the reproducer given in https://bugzilla.redhat.com/show_bug.cgi?id=2186059#c6
Verified on:
openvswitch-selinux-extra-policy-1.0-34.el9fdp.noarch
openvswitch2.17-2.17.0-94.el9fdp.x86_64
ovn22.12-22.12.0-73.el9fdp.x86_64
ovn22.12-central-22.12.0-73.el9fdp.x86_64
ovn22.12-host-22.12.0-73.el9fdp.x86_64

Comment 6 errata-xmlrpc 2023-08-21 02:08:16 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (ovn23.03 bug fix and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2023:4678