1.1 - Laboratory: Installation and setup

2 minute read

Physical Host Setup

This step is optional, if you want to start with a fresh installation.

Download your favorite OS, such as CentOS. To boot from a USB Device, you can use the unetbootin or dd command

[email protected]:~$ dd if=/data/CentOS-7-x86_64-Minimal-1804.iso of=/dev/sdb1 bs=512M; sync

To procred with the installation and environment configuration, you can follow the guides bellow or the tecmint guide. 1

How to Get RHEL7

It’s possible to get a free version of RHEL 7, if it’s not used for production, in the Red Hat developer page.2

This steps will be done on a physical machine


Check whether your system’s CPU supports Hardware Virtualisation

[email protected]:~# grep -E '(vmx|svm)' /proc/cpuinfo

Make sure modules are loaded

[email protected]:~# lsmod | grep kvm

Install required packages

[email protected]:~# sudo yum groupinstall virtualization-client virtualization-platform virtualization-tools

The virtualization daemon which manage all of the platform is libvirtd.3

[email protected]:~# sudo systemctl restart libvirtd
[email protected]:~# sudo systemctl status libvirtd

Installing RHEL7

  ## make sure X11 forward is enabled, if using ssh
[email protected]:~# virt-manager

Crete a new VM with the following setup: (can be adjust your available resources)

  • Name: rhel7
  • RAM: 4 GB
  • DISK: 2 Disks, 30 + 20 GB, qcow2

As an alternative to the manual setup, you can create the VM using the following commands:

[email protected]:~# qemu-img create -f qcow2 -o preallocation=metadata /data/images/rhel7_1.qcow2 30G
[email protected]:~# qemu-img create -f qcow2 -o preallocation=metadata /data/images/rhel7_2.qcow2 20G
[email protected]:~# virt-install \
  --name=rhel7 \
  --vcpus=4 --ram=4096 \
  --disk path=/data/images/rhel7_1.qcow2,format=qcow2,cache=none,device=disk,bus=virtio \
  --disk path=/data/images/rhel7_2.qcow2,format=qcow2,cache=none,device=disk,bus=virtio \
  --disk path=/data/iso/rhel-server-7.5-x86_64-dvd.iso,device=cdrom \
  --cdrom=/home/felixmf/software/rhel-server-7.5-x86_64-dvd.iso \
  --os-type=linux \

Configure the next options:

  • Software Selection: Server with a GUI
  • Date & Time, Keyboard: your local zone

rhel7 installation

It’s not mandatory to have a “Server with a GUI”, but it’s selected to help simulate the exam environment and show some alternative tools.

Installation Destination: Select only one the drive, with 30 Gb and “I will configure Partitioning”. rhel7 device selection

Click done and “Click hehe to create them automatically”. Change The root Mount point / to a desired capacity of 13 Gb. rhel7 partitioning

Start the installation and add a password to root, a personal user and enable the network.

If you are having trouble, it’s possible to follow this step-by-step video:4

After installation

If forgot to change the keyboard, you use this command, as this example for pt type.

[email protected]:~# setxkbmap pt

Configure Network

[email protected]:~# sudo nmtui

change the eth to manual, add an Addresses and check the Automatically connect

check the ifcfg file: cat /etc/sysconfig/network-scripts/ifcfg-eth0 configuration


and restart network. Check the IP / status:

[email protected]:~# systemctl restart network
[email protected]:~# systemctl status network
[email protected]:~# ip a
[email protected]:~# ping google.com
  1. < https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/installation_guide/sect-making-usb-media > 

  2. < https://developers.redhat.com/blog/2016/03/31/no-cost-rhel-developer-subscription-now-available > 

  3. < https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/virtualization_deployment_and_administration_guide/chap-installing_the_virtualization_packages > 

  4. < https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/installation_guide/index > 


Leave a Comment