Skip to content

Latest commit

 

History

History
133 lines (118 loc) · 4.27 KB

agent-install-networking.adoc

File metadata and controls

133 lines (118 loc) · 4.27 KB

About networking

The rendezvous IP must be known at the time of generating the agent ISO, so that during the initial boot all the hosts can check in to the assisted service. If the IP addresses are assigned using a Dynamic Host Configuration Protocol (DHCP) server, then the rendezvousIP field must be set to an IP address of one of the hosts that will become part of the deployed control plane. In an environment without a DHCP server, you can define IP addresses statically.

In addition to static IP addresses, you can apply any network configuration that is in NMState format. This includes VLANs and NIC bonds.

DHCP

Preferred method: install-config.yaml and agent-config.yaml

You must specify the value for the rendezvousIP field. The networkConfig fields can be left blank:

Sample agent-config.yaml.file
apiVersion: v1alpha1
kind: AgentConfig
metadata:
  name: sno-cluster
rendezvousIP: 192.168.111.80 (1)
  1. The IP address for the rendezvous host.

Static networking

  1. Preferred method: install-config.yaml and agent-config.yaml

    Sample agent-config.yaml.file
      cat > agent-config.yaml << EOF
      apiVersion: v1alpha1
      kind: AgentConfig
      metadata:
        name: sno-cluster
      rendezvousIP: 192.168.111.80 (1)
      hosts:
        - hostname: master-0
          interfaces:
            - name: eno1
              macAddress: 00:ef:44:21:e6:a5 (2)
          networkConfig:
            interfaces:
              - name: eno1
                type: ethernet
                state: up
                mac-address: 00:ef:44:21:e6:a5
                ipv4:
                  enabled: true
                  address:
                    - ip: 192.168.111.80 (3)
                      prefix-length: 23 (4)
                  dhcp: false
            dns-resolver:
              config:
                server:
                  - 192.168.111.1 (5)
            routes:
              config:
                - destination: 0.0.0.0/0
                  next-hop-address: 192.168.111.1 (6)
                  next-hop-interface: eno1
                  table-id: 254
      EOF
    1. If a value is not specified for the rendezvousIP field, one address will be chosen from the static IP addresses specified in the networkConfig fields.

    2. The MAC address of an interface on the host, used to determine which host to apply the configuration to.

    3. The static IP address of the target bare metal host.

    4. The static IP address’s subnet prefix for the target bare metal host.

    5. The DNS server for the target bare metal host.

    6. Next hop address for the node traffic. This must be in the same subnet as the IP address set for the specified interface.

  2. Optional method: {ztp} manifests

    The optional method of the {ztp} custom resources comprises 6 custom resources; you can configure static IPs in the nmstateconfig.yaml file.

    apiVersion: agent-install.openshift.io/v1beta1
    kind: NMStateConfig
    metadata:
      name: master-0
      namespace: openshift-machine-api
      labels:
        cluster0-nmstate-label-name: cluster0-nmstate-label-value
    spec:
      config:
        interfaces:
          - name: eth0
            type: ethernet
            state: up
            mac-address: 52:54:01:aa:aa:a1
            ipv4:
              enabled: true
              address:
                - ip: 192.168.122.2 (1)
                  prefix-length: 23 (2)
              dhcp: false
        dns-resolver:
          config:
            server:
              - 192.168.122.1 (3)
        routes:
          config:
            - destination: 0.0.0.0/0
              next-hop-address: 192.168.122.1 (4)
              next-hop-interface: eth0
              table-id: 254
      interfaces:
        - name: eth0
          macAddress: 52:54:01:aa:aa:a1 (5)
    1. The static IP address of the target bare metal host.

    2. The static IP address’s subnet prefix for the target bare metal host.

    3. The DNS server for the target bare metal host.

    4. Next hop address for the node traffic. This must be in the same subnet as the IP address set for the specified interface.

    5. The MAC address of an interface on the host, used to determine which host to apply the configuration to.

The rendezvous IP is chosen from the static IP addresses specified in the config fields.