Language and Page Formatting Options
13.2. Configuring the Foreman Discovery Plug-in
Ensure the following are correctly configured before you configure the Foreman Discovery plug-in:
- Ensure that bare-metal provisioning is functional. See Chapter 11, Configuring the Provisioning Environment for more information. To test bare-metal provisioning, create a host entry with a MAC address and power on the system to provision it. After Foreman Discovery is configured, host creation will be automated.
- The network DHCP server must be able to serve unknown clients and it must point unknown clients to the TFTP server where the discovery image is stored. If Internet Systems Consortium (ISC) DHCP was installed via the capsule installer on the Red Hat Enterprise Linux host, this will already be configured. If you are using a different configuration or a different DHCP server, ensure the
nextserveroption is configured to return the correct TFTP server, which is under the Red Hat Satellite Server's control.
- Satellite 6.0 has a template locking capability which prevents some templates from being edited or renamed because the application relies on their presence and name. The locked default PXELinux template prevents the configuration of Discovery. To circumvent this, start a Rails console on the Satellite Capsule and unlock the template, as described below:
# foreman-rake console > ct = ConfigTemplate.find_by_name("PXELinux global default"); ct.locked = false; ct.save! > exit
Procedure 13.1. To Configure the Foreman Discovery Plug-in:
- Click Hosts → Provisioning templates and edit the PXELinux global default template. Add the following entries at the end of the template:
LABEL discovery MENU LABEL Foreman Discovery MENU DEFAULT KERNEL boot/foreman-discovery-image-latest.el6.iso-vmlinuz APPEND rootflags=loop initrd=boot/foreman-discovery-image-latest.el6.iso-img root=live:/foreman.iso rootfstype=auto ro rd.live.image rd.live.check rd.lvm=0 rootflags=ro crashkernel=128M elevator=deadline max_loop=256 rd.luks=0 rd.md=0 rd.dm=0 rd.bootif=0 rd.neednet=0 nomodeset selinux=0 stateless foreman.url=FOREMAN_URL IPAPPEND 2The
foreman.urloption on the APPEND line identifies the location of the Foreman instance. Ensure that this is set correctly in global settings or the discovered hosts will not register to Foreman.The
IPAPPEND 2option is important because it adds the
BOOTIF=MACoption. This is reported by Facter as
discovery_bootif, which is a key fact used for provisioning. It is expected that the interface that it is booted from will be the provisioning interface as well. The same interface is used as the primary interface and is used to retrieve DNS configuration from DHCP.
- Set the
discoveryto make the
foreman.urloption the default:
ONTIMEOUT discoveryAlternatively, the discovery image can search for a DNS SRV record called
_xforeman._tcp. If the DNS server is configured for this, do not configure the
foreman.urloption because it will override the DNS SRV record. The following is an example of the configuration for the ISC DNS server:
_xforeman._tcp SRV 0 5 443 foreman
- Click Hosts → Provisioning templates and then click Build PXE Default to deploy the configuration file on the TFTP server.
ImportantThe Foreman Discovery image does not support SELinux. Set
selinux=0in the template. The discovery image is read-only.