Setting up DHCP

Steps to set up the DHCP server for IBM Storage Fusion HCI System appliance.

About this task

All storage, AFM, and GPU nodes in the IBM Storage Fusion appliance must be in the same network segment (subnet). The nodes must have access to a DHCP server to provide IP addresses and other network parameters, for example, default gateway and DNS address.

Note: The samples in this procedure are based on Red Hat® Enterprise Linux. If you are on Microsoft® Linux®, then use equivalent commands.
Use the DHCP server to provide all the nodes of the OpenShift® cluster and bootstrap virtual machine that you are about to install, with IP information that corresponds to the mac address of the node. It is the reason for you to use fixed-address directive for DHCP to statically map all the mac addresses of the nodes to the required IP addresses. Also, the DHCP server must provide these DHCP options in its DHCP responses for the nodes to be configured correctly:
option routers                  
option broadcast-address        
option subnet-mask             
option domain-name-servers     
option domain-name             
option domain-search          
option host-name
Note: For the host-name option, it must be full FQDN value.

Procedure

  1. Edit /etc/dhcp/dhcpd.conf file to update values for routers, broadcast-address, subnet-mask, domain-name-servers.
    Note: The following sample dhcpd.conf (DHCP configuration file) provides bootstrap IP addresses for the control nodes and computes nodes in the 10.44.100.0/24 subnet. In this example, the OpenShift cluster name is isf and the DNS domain is mycompany.com. Together, the cluster name and domain name form the cluster subdomain. The MAC addresses are provided by IBM.
    authoritative;
    ddns-update-style interim;
    default-lease-time 489776228;
    max-lease-time 489776228;
    
    
           option domain-name-servers      10.44.100.142;
    
           subnet 10.44.100.128 netmask 255.255.255.128 {
    	interface bond0;
    	option routers                  10.44.100.129;
    	option broadcast-address        10.44.100.255;
    	option subnet-mask              255.255.255.128;
    	group {
    		
    		option domain-name              "isf.mycompany.com";
    		option domain-search            "isf.mycompany.com";
    		host bootstrap.isf.mycompany.com { option host-name "bootstrap.isf.mycompany.com"; hardware ethernet 00:16:3e:e0:31:65; fixed-address 10.44.100.151; }
    		host control-1-ru2.isf.mycompany.com { option host-name "control-1-ru2.isf.mycompany.com"; hardware ethernet 04:3f:72:f7:2f:76; fixed-address 10.44.100.145; }
    		host control-1-ru3.isf.mycompany.com { option host-name "control-1-ru3.isf.mycompany.com"; hardware ethernet 04:3f:72:f7:31:2e; fixed-address 10.44.100.146; }
    		host control-1-ru4.isf.mycompany.com { option host-name "control-1-ru4.isf.mycompany.com"; hardware ethernet 04:3f:72:f5:a7:2a; fixed-address 10.44.100.147; }
    
    		host compute-1-ru5.isf.mycompany.com { option host-name "compute-1-ru5.isf.mycompany.com"; hardware ethernet 04:3f:72:f5:a7:26; fixed-address 10.44.100.148; }
    		host compute-1-ru6.isf.mycompany.com { option host-name "compute-1-ru6.isf.mycompany.com"; hardware ethernet 04:3f:72:f5:a7:16; fixed-address 10.44.100.149; }
    		host compute-1-ru7.isf.mycompany.com { option host-name "compute-1-ru7.isf.mycompany.com"; hardware ethernet b8:59:9f:e4:46:6e; fixed-address 10.44.100.150; }
                  
                  # The compute-1-ru23.isf.mycompany.com and compute-1-ru23.isf.mycompany.com are for AFM nodes.
           	
                  host compute-1-ru23.isf.mycompany.com { option host-name "compute-1-ru23.isf.mycompany.com"; hardware ethernet 04:3f:72:df:16:b4; fixed-address 10.44.100.156; }
    		host compute-1-ru24.isf.mycompany.com { option host-name "compute-1-ru24.isf.mycompany.com"; hardware ethernet 04:3f:72:df:1a:bc; fixed-address 10.44.100.157; }
    	       
                  #The compute-1-ru25.isf.mycompany.com and compute-1-ru27.isf.mycompany.com are for GPU node.
                  host compute-1-ru25.isf.mycompany.com { option host-name "compute--1-ru25.isf.mycompany.com"; hardware ethernet 04:3f:72:df:16:c4; fixed-address 10.44.100.158; }
    		host compute-1-ru27.isf.mycompany.com { option host-name "compute-1-ru27.isf.mycompany.com"; hardware ethernet 04:3f:72:df:1a:cc; fixed-address 10.44.100.159; }
    
    }
    	deny unknown-clients;
    
    Note: Here, the same domain-name-servers value and option host name must be used when you configure in DNS as they are interconnected. Make sure that the fixed addresses that you configure here must be the same in DNS as well.

    This example is for a single rack. If you want to configure DHCP for a high availability multi rack cluster or expansion rack, then add rest of the nodes in the cluster according to your host name. For more details about the hostname, see Setting up the DNS and DHCP for IBM Storage Fusion HCI System.

    If you want to configure using dnsmasq:
    
    user=dnsmasq
    group=dnsmasq
    interface=ens19
    domain=isf.mycompany.com
    dhcp-range=10.10.9.10,10.10.9.127,9.9.9.0,infinite
    conf-dir=/etc/dnsmasq.d,.rpmnew,.rpmsave,.rpmorig
    
    
    
    
    dhcp-host=00:16:3e:65:c3:52,bootstrap,10.10.9.10,infinite,set:bootstrap
    dhcp-option=tag:bootstrap,12,bootstrap.isf.mycompany.com
    
    dhcp-host=08:c0:eb:ff:40:66,control-0,10.10.9.12,infinite,set:control-0
    dhcp-option=tag:control-0,12,control-0.isf.mycompany.com
    
    dhcp-host=08:c0:eb:ff:43:36,control-1,10.10.9.13,infinite,set:control-1
    dhcp-option=tag:control-1,12,control-1.isf.mycompany.com
    
    dhcp-host=08:c0:eb:ff:40:86,control-2,10.10.9.14,infinite,set:control-2
    dhcp-option=tag:control-2,12,control-2.isf.mycompany.com
    
    dhcp-host=08:c0:eb:ff:2f:86,compute-0,10.10.9.15,infinite,set:compute-0
    dhcp-option=tag:compute-0,12,compute-0.isf.mycompany.com
    
    dhcp-host=08:c0:eb:ff:3e:92,compute-1,10.10.9.16,infinite,set:compute-1
    dhcp-option=tag:compute-1,12,compute-1.isf.mycompany.com
    
    dhcp-host=08:c0:eb:ff:30:42,compute-2,10.10.9.17,infinite,set:compute-2
    dhcp-option=tag:compute-2,12,compute-2.isf.mycompany.com
    
    dhcp-host=08:c0:eb:cb:09:2e,compute-13,10.10.9.18,infinite,set:compute-13
    dhcp-option=tag:compute-13,12,compute-13.isf.mycompany.com
    
    dhcp-host=08:c0:eb:cb:08:8e,compute-14,10.10.9.19,infinite,set:compute-14
    dhcp-option=tag:compute-14,12,compute-14.isf.mycompany.com
    
    dhcp-host=b8:ce:f6:74:ef:d6,compute-15,10.10.9.20,infinite,set:compute-15
    dhcp-option=tag:compute-15,12,compute-15.isf.mycompany.com
    
    dhcp-host=08:c0:eb:ff:31:66,compute-16,10.10.9.21,infinite,set:compute-16
    dhcp-option=tag:compute-16,12,compute-16.isf.mycompany.com
    
    address=/api.isf.mycompany.com/10.10.9.6
    address=/api-int.isf.mycompany.com/10.10.9.6
    address=/apps.isf.mycompany.com/10.10.9.7
  2. After you update the configuration file, restart the service for the changes to take effect.
    For example, on Linux®, run the following command:
    sudo /etc/init.d/dnsmasq restart
    or
    sudo restart network-manager