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

Validation failure when RendezvousIP is a substring of next-hop-address

XMLWordPrintable

    • None
    • Installer Sprint 262
    • 1
    • False
    • Hide

      None

      Show
      None
    • Hide
      If the RendezvousIP matches a substring of the worker's next-hop-address field the validation can fail with the error:
      Host <worker> has role 'worker' and has the rendezvousIP assigned to it. The rendezvousIP must be assigned to a control plane host

      This fixes the substring comparison to prevent this spurious validation failure.
      Show
      If the RendezvousIP matches a substring of the worker's next-hop-address field the validation can fail with the error: Host <worker> has role 'worker' and has the rendezvousIP assigned to it. The rendezvousIP must be assigned to a control plane host This fixes the substring comparison to prevent this spurious validation failure.
    • Bug Fix
    • In Progress

      Description of problem:

      
      

      An unexpected validation failure occurs when creating the agent ISO image if the RendezvousIP is a substring of the next-hop-address set for a worker node.

      For example this configuration snippet in agent-config.yaml:

      apiVersion: v1alpha1
      kind: AgentConfig
      metadata:
        name: agent-config
      rendezvousIP: 7.162.6.1
      hosts:
      ...
       - hostname: worker-0
          role: worker
          networkConfig:
           interfaces:
              - name: eth0
                type: Ethernet
                state: up
                ipv4:
                  enabled: true
                  address:
                    - ip: 7.162.6.4
                      prefix-length: 25
                  dhcp: false
           routes:
              config:
                - destination: 0.0.0.0/0
                  next-hop-address: 7.162.6.126
                  next-hop-interface: eth0
                  table-id: 254
      

      Will result in the validation failure when creating the image:

      FATAL failed to fetch Agent Installer ISO: failed to fetch dependency of "Agent Installer ISO": failed to fetch dependency of "Agent Installer Artifacts": failed to fetch dependency of "Agent Installer Ignition": failed to fetch dependency of "Agent Manifests": failed to fetch dependency of "NMState Config": failed to generate asset "Agent Hosts": invalid Hosts configuration: [Hosts[3].Host: Forbidden: Host worker-0 has role 'worker' and has the rendezvousIP assigned to it. The rendezvousIP must be assigned to a control plane host.
      

      The problem is this check here https://github.com/openshift/installer/pull/6716/files#diff-fa305fe33630f77b65bd21cc9473b620f67cfd9ce35f7ddf24d03b26ec2ccfffR293
      Its checking for the IP in the raw nmConfig. The problem is the routes stanza is also included in the nmConfig and the route is
      next-hop-address: 7.162.6.126
      So when rendezvousIP is 7.162.6.1 that strings.Contains() check returns true and the validation fails.

            beth.white Beth White
            bfournie@redhat.com Robert Fournier
            Manoj Hans Manoj Hans
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: