#xCAT generated dhcp configuration

option conf-file code 209 = text;
option space isan;
option isan-encap-opts code 43 = encapsulate isan;
option isan.iqn code 203 = string;
option isan.root-path code 201 = string;
option space gpxe;
option gpxe-encap-opts code 175 = encapsulate gpxe;
option gpxe.bus-id code 177 = string;
option user-class-identifier code 77 = string;
option gpxe.no-pxedhcp code 176 = unsigned integer 8;
option tcode code 101 = text;
option iscsi-initiator-iqn code 203 = string;
ddns-update-style interim;
ignore client-updates;
option client-architecture code 93 = unsigned integer 16;
option tcode "Europe/London";
option gpxe.no-pxedhcp 1;
option www-server code 114 = string;
option cumulus-provision-url code 239 = text;

omapi-port 7911;
key xcat_key {
  algorithm hmac-md5;
  secret "UHBYMVJEM3hENDVtUHNYTWZJMHJiZkVYU0hjUUttUEc=";
};
omapi-key xcat_key;
class "pxe" {
   match if substring (option vendor-class-identifier, 0, 9) = "PXEClient";
   ddns-updates off;
    max-lease-time 600;
}
shared-network bond0 {
  subnet 130.246.32.0 netmask 255.255.252.0 {
    authoritative;
    max-lease-time 3888000;
    min-lease-time 388800;
    default-lease-time 3888000;
    option routers  130.246.32.254;
    next-server  130.246.32.140;
    option log-servers 130.246.32.140;
    option ntp-servers 130.246.32.140, 130.246.8.13, 193.62.22.82;
    option domain-name "bnsc.rl.ac.uk";
    option domain-name-servers  130.246.32.140, 130.246.8.13, 130.246.188.240;
    option domain-search  "bnsc.rl.ac.uk";
    option cumulus-provision-url "http://130.246.32.140:80/install/postscripts/cumulusztp";
    ddns-domainname "bnsc.rl.ac.uk";
    zone bnsc.rl.ac.uk. {
       primary 130.246.32.140; key xcat_key; 
    }
    zone 32.246.130.IN-ADDR.ARPA. {
       primary 130.246.32.140; key xcat_key; 
    }
    zone 33.246.130.IN-ADDR.ARPA. {
       primary 130.246.32.140; key xcat_key; 
    }
    zone 34.246.130.IN-ADDR.ARPA. {
       primary 130.246.32.140; key xcat_key; 
    }
    zone 35.246.130.IN-ADDR.ARPA. {
       primary 130.246.32.140; key xcat_key; 
    }
    if option user-class-identifier = "xNBA" and option client-architecture = 00:00 { #x86, xCAT Network Boot Agent
        always-broadcast on;
        filename = "http://130.246.32.140:80/tftpboot/xcat/xnba/nets/130.246.32.0_22";
    } else if option user-class-identifier = "xNBA" and option client-architecture = 00:09 { #x86, xCAT Network Boot Agent
        filename = "http://130.246.32.140:80/tftpboot/xcat/xnba/nets/130.246.32.0_22.uefi";
    } else if option client-architecture = 00:00  { #x86
        filename "xcat/xnba.kpxe";
    } else if option vendor-class-identifier = "Etherboot-5.4"  { #x86
        filename "xcat/xnba.kpxe";
    } else if option client-architecture = 00:07 { #x86_64 uefi
         filename "xcat/xnba.efi";
    } else if option client-architecture = 00:09 { #x86_64 uefi alternative id
         filename "xcat/xnba.efi";
    } else if option client-architecture = 00:02 { #ia64
         filename "elilo.efi";
    } else if option client-architecture = 00:0e { #OPAL-v3
         option conf-file = "http://130.246.32.140:80/tftpboot/pxelinux.cfg/p/130.246.32.0_22";
    } else if substring (option vendor-class-identifier,0,11) = "onie_vendor" { #for onie on cumulus switch
        option www-server = "http://130.246.32.140:80/install/onie/onie-installer";
    } else if substring(filename,0,1) = null { #otherwise, provide yaboot if the client isn't specific
         filename "/yaboot";
    }
    range dynamic-bootp 130.246.32.141 130.246.32.155;

    host proc01.bnsc.rl.ac.uk {hardware ethernet 00:25:90:5a:eb:8a; fixed-address 130.246.32.141;}

    host proc02.bnsc.rl.ac.uk {hardware ethernet 00:25:90:5a:ec:73; fixed-address 130.246.32.142;}

    host proc03.bnsc.rl.ac.uk {hardware ethernet 00:25:90:5a:ec:a6; fixed-address 130.246.32.143;}

    host proc04.bnsc.rl.ac.uk {hardware ethernet 00:25:90:5a:eb:d0; fixed-address 130.246.32.144;}

    host proc01-mng.bnsc.rl.ac.uk {hardware ethernet 00:25:90:5a:ec:91; fixed-address 130.246.32.151;}

    host proc02-mng.bnsc.rl.ac.uk {hardware ethernet 00:25:90:5a:ec:73; fixed-address 130.246.32.152;}

    host proc03-mng.bnsc.rl.ac.uk {hardware ethernet 00:25:90:5a:ec:a6; fixed-address 130.246.32.153;}

    host proc04-mng.bnsc.rl.ac.uk {hardware ethernet 00:25:90:5a:ec:77; fixed-address 130.246.32.154;}


    deny unknown-clients;
  } # 130.246.32.0/255.255.252.0 subnet_end
} # bond0 nic_end
#definition for host proc01 aka host proc01 can be found in the dhcpd.leases file (typically /var/lib/dhcpd/dhcpd.leases)
#definition for host proc02 aka host proc02 can be found in the dhcpd.leases file (typically /var/lib/dhcpd/dhcpd.leases)
#definition for host proc03 aka host proc03 can be found in the dhcpd.leases file (typically /var/lib/dhcpd/dhcpd.leases)
#definition for host proc04 aka host proc04 can be found in the dhcpd.leases file (typically /var/lib/dhcpd/dhcpd.leases)
#definition for host xcatmntest aka host xcatmntest can be found in the dhcpd.leases file (typically /var/lib/dhcpd/dhcpd.leases)
