# Host configuration

This section outlines the steps to configure the automation environment and utilizes the automation environment to install SLES 15 SP2 operating system on each of them.

# Preparing the execution environment

This section provides a detailed overview and steps to configure the components deployed for this solution.

# Installer machine

This document assumes that a server running Centos 7 or RHEL 7 with the following configuration exists within the deployment environment and is accessible to the installation user to be used in an installer machine.

  1. At least 1.5 TB of free disk space (especially in the "/" partition), 8 CPU cores and 32GB RAM.
  2. One (1) network interface with static IP address configured on same network as the management plane of the bare-metal servers and has access to internet.

In this solution, a virtual machine is used to act as an installer machine and the same host is utilized as an Ansible Engine host.

# Setup the prerequisites

Login to the installer VM and perform the following steps:

  1. Use the following commands to install and enable Python 3.6.x.
> yum -y install centos-release-scl
> yum -y install rh-python36
> scl enable rh-python36 bash
  1. Use the following commands to create and activate a Python3 virtual environment for deploying this solution.
> python3 -m venv <virtual_environment_name>
> source <virtual_environment_name>/bin/activate
  1. Use the following command to install Ansible 2.9.
> python3 -m pip install ansible==2.9.0
  1. Disable SELinux

    • Edit the /etc/selinux/config file and set the SELINUX to disabled

    • Reboot the server

    • Verify the SELinux status by running the following command:

      > sestatus
      
  2. Execute the following commands in the Ansible Engine to download the repositories.

> mkdir -p /opt/hpe/solutions/hpecp/
> cd /opt/hpe/solutions/hpecp/
> yum install -y git
> git clone https://github.com/HewlettPackard/hpe-solutions-hpecp.git

NOTE

  • The value for the constant "$BASE_DIR" referred to in this deployment guide is /opt/hpe/solutions/hpecp/hpe-solutions-hpecp/DL/scripts/
  • This solution utilizes the Service Pack for ProLiant (SPP)/firmware bundle ISO image to enable an unattended update of firmware on the servers. Hence, ensure this image is available on the installer machine. Solution utilizes the ISO image of SLES 15 SP2 to enable an unattended installation of SLES on the servers. Hence, ensure this image is also available on the installer machine.

# Ansible inventory file

The files that are cloned from the GitHub site include a sample inventory file. The installation user should review this file (located on the installer VM at $BASE_DIR/infrastructure/hosts and $BASE_DIR/prepare_hpecp_hosts/hosts) and ensure that the information within the file accurately reflects the information in their environment.

Use an editor such as vi or nano to edit the inventory file.

> vi $BASE_DIR/infrastructure/hosts
> vi $BASE_DIR/prepare_hpecp_hosts/hosts

NOTE

The values provided in the variable files, inventory files, figures, and tables in this document are intended to be used for reference purpose. It is expected that the installation user updates them to suit the local environment.

By default, the forks parameter in Ansible is limited to 5. Execute the following command to update the Ansible configuration to increase the value of number of hosts that are getting configured using this playbook.

> export ANSIBLE_FORKS=<number_of_hosts_present_in_the_ansible_inventory_file>

# Ansible vault

A preconfigured Ansible vault file (secret.yml) is provided as a part of this solution, which consists of sensitive information to support the host and virtual machine deployment.

Run the following commands on the installer VM to edit the vault to match the installation environment.

> ansible-vault edit $BASE_DIR/infrastructure/secret.yml

NOTE

The default password for the Ansible vault file is changeme.