Uploaded image for project: 'OpenShift Bugs'
  1. OpenShift Bugs
  2. OCPBUGS-42781

Document users of OVNKubernetes k8s.ovn.org/host-cidrs

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Normal Normal
    • None
    • 4.18
    • None
    • Moderate
    • None
    • False
    • Hide

      None

      Show
      None

      Description of problem:

      baremetal-runtimecfg uses the OVN host annotations to choose a Node IP, if k8s.ovn.org/host-cidrs changes we will need to update it.

      We should add a code comment at least.

      https://github.com/openshift/baremetal-runtimecfg/blob/master/pkg/config/node.go#L355

      getNodeIpForRequestedIpStack
      	// We need to collect IP address of a matching IP stack for every node that is part of the
      	// cluster. We need to account for a scenario where Node.Status.Addresses list is incomplete
      	// and use different source of the address.
      	//
      	// We will use here the following sources:
      	//   1) Node.Status.Addresses list
      	//   2) Node annotation "k8s.ovn.org/host-cidrs" in combination with Machine Networks
      	//   3) Deprecated node annotation "k8s.ovn.org/host-addresses" in combination with Machine Networks
      	//
      	// If none of those returns a conclusive result, we don't return an IP for this node. This is
      	// not a desired outcome, but can be extended in the future if desired.
      

      Version-Release number of selected component (if applicable):

      4.18

      How reproducible:

      Always

      Steps to Reproduce:
      Steps from OCPBUGS-34706

          1. Deploy vsphere IPv4 cluster
          2. Convert to Dualstack IPv4/IPv6
          3. Add machine network and IPv6 apiServerInternalIPs and ingressIPs
          4. Check keepalived.conf
      for f in $(oc get pods -n openshift-vsphere-infra -l app=vsphere-infra-vrrp --no-headers -o custom-columns=N:.metadata.name  ) ; do oc -n openshift-vsphere-infra exec -c keepalived $f -- cat /etc/keepalived/keepalived.conf | tee $f-keepalived.conf ; done
          

      Actual results:

      If the OVNKubernetes host annotation changes then the IPv6 VIP will not be in keepalived.conf

      Expected results:

      IPv6 VIP is in keepalived.conf

      Additional info:

      Other users of k8s.ovn.org/host-cidrs are

      https://github.com/gmeghnag/omc/pull/165
      https://github.com/redhat-best-practices-for-k8s/certsuite/pull/2122

            bbennett@redhat.com Ben Bennett
            rbrattai@redhat.com Ross Brattain
            Anurag Saxena Anurag Saxena
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: