Red Hat Training

A Red Hat training course is available for Red Hat Enterprise Linux

Chapter 8. Guest operating system installation procedures

This chapter covers how to install various guest operating systems in a virtualized environment on Red Hat Enterprise Linux. To understand the basic processes, see Chapter 7, Guest installation overview.

Important

When installing a Red Hat Enterprise Linux guest, the installer will ask to perform an integrity check on your installation source (CD/DVD media, or ISO file). If you select to perform the check, once the media is tested and the installation continues, you may encounter a message that states: The Red Hat Enterprise Linux Server CD was not found in any of your CDROM drives. Please insert the Red Hat Enterprise Linux Server CD and press OK to retry.
This behavior is intentional, provided as a convenience to make sure media is ejected in case a CD install (requiring multiple discs/images) is being performed as opposed to a DVD install.
To proceed past this message, make sure you either insert the next CD, or edit the guest's XML file specifying the next ISO file (or re-insert the DVD media). Next, run virsh update-device Guest1 ~/Guest1.xml (substituting your guest's name and XML file), and select OK to continue past this step.

8.1. Installing Red Hat Enterprise Linux 5 as a para-virtualized guest

This section describes how to install Red Hat Enterprise Linux 5 as a para-virtualized guest. Para-virtualization is a faster than full virtualization and supports all of the advantages of full virtualization. Para-virtualization requires a special, supported kernel, the kernel-xen kernel.

Important

Para-virtualization only works with the Xen hypervisor. Para-virtualization does not work with the KVM hypervisor.
Ensure you have root access before starting the installation.
This method installs Red Hat Enterprise Linux from a remote server. The installation instructions presented in this section are similar to installing from the minimal installation live CD-ROM.
Create para-virtualized Red Hat Enterprise Linux 5 guests using virt-manager or virt-install. For instructions on virt-manager, see Section 7.2, “Creating guests with virt-manager”.
Create a para-virtualized guest with the command line based virt-install tool. The --vnc option shows the graphical installation. The name of the guest in the example is rhel5PV, the disk image file is rhel5PV.dsk and a local mirror of the Red Hat Enterprise Linux 5 installation tree is ftp://10.1.1.1/trees/RHEL5-B2-Server-i386/. Replace those values with values accurate for your system and network.
# virt-install -n rhel5PV -r 500 \
-f /var/lib/libvirt/images/rhel5PV.dsk -s 3 --vnc -p \
-l ftp://10.1.1.1/trees/RHEL5-B2-Server-i386/

Note

Red Hat Enterprise Linux can be installed without a graphical interface or manual input. Use Kickstart files to automate the installation process.
Using either method opens this window, displaying the initial boot phases of your guest:
After your guest has completed its initial boot, the standard installation process for Red Hat Enterprise Linux starts. For most systems the default answers are acceptable.

Procedure 8.1. Para-virtualized Red Hat Enterprise Linux guest installation procedure

  1. Select the language and click OK.
  2. Select the keyboard layout and click OK.
  3. Assign the guest's network address. Choose to use DHCP (as shown below) or a static IP address:
  4. If you select DHCP the installation process will now attempt to acquire an IP address:
  5. If you chose a static IP address for your guest this prompt appears. Enter the details on the guest's networking configuration:
    1. Enter a valid IP address. Ensure the IP address you enter can reach the server with the installation tree.
    2. Enter a valid Subnet mask, default gateway and name server address.
    Select the language and click OK.
  6. This is an example of a static IP address configuration:
  7. The installation process now retrieves the files it needs from the server:
Once the initial steps are complete the graphical installation process starts.
If you are installing a Beta or early release distribution confirm that you want to install the operating system. Click Install Anyway, and then click OK:

Procedure 8.2. The graphical installation process

  1. Enter a valid registration code. If you have a valid Red Hat subscription key please enter in the Installation Number field:

    Note

    If you skip the registration step, confirm your Red Hat account details after the installation with the rhn_register command. The rhn_register command requires root access.
  2. The installation prompts you to confirm erasure of all data on the storage you selected for the installation:
    Click Yes to continue.
  3. Review the storage configuration and partition layout. You can chose to select the advanced storage configuration if you want to use iSCSI for the guest's storage.
    Make your selections then click Forward.
  4. Confirm the selected storage for the installation.
    Click Yes to continue.
  5. Configure networking and hostname settings. These settings are populated with the data entered earlier in the installation process. Change these settings if necessary.
    Click OK to continue.
  6. Select the appropriate time zone for your environment.
  7. Enter the root password for the guest.
    Click Forward to continue.
  8. Select the software packages to install. Select the Customize Now button. You must install the kernel-xen package in the System directory. The kernel-xen package is required for para-virtualization.
    Click Forward.
  9. Dependencies and space requirements are calculated.
  10. After the installation dependencies and space requirements have been verified click Forward to start the actual installation.
  11. All of the selected software packages are installed automatically.
  12. After the installation has finished reboot your guest:
  13. The guest will not reboot, instead it will shutdown..
  14. Boot the guest. The guest's name was chosen when you used the virt-install in Section 8.1, “Installing Red Hat Enterprise Linux 5 as a para-virtualized guest”. If you used the default example the name is rhel5PV.
    Use virsh to reboot the guest:
    # virsh reboot rhel5PV
    Alternatively, open virt-manager, select the name of your guest, click Open, then click Run.
    A VNC window displaying the guest's boot processes now opens.
  15. Booting the guest starts the First Boot configuration screen. This wizard prompts you for some basic configuration choices for your guest.
  16. Read and agree to the license agreement.
    Click Forward on the license agreement windows.
  17. Configure the firewall.
    Click Forward to continue.
    1. If you disable the firewall you will be prompted to confirm your choice. Click Yes to confirm and continue. It is not recommended to disable your firewall.
  18. Configure SELinux. It is strongly recommended you run SELinux in enforcing mode. You can choose to either run SELinux in permissive mode or completely disable it.
    Click Forward to continue.
    1. If you choose to disable SELinux this warning displays. Click Yes to disable SELinux.
  19. Disable kdump. The use of kdump is unsupported on para-virtualized guests.
    Click Forward to continue.
  20. Confirm time and date are set correctly for your guest. If you install a para-virtualized guest time and date should synchronize with the hypervisor.
    If the users sets the time or date during the installation it is ignored and the hypervisor's time is used.
    Click Forward to continue.
  21. Set up software updates. If you have a Red Hat account or want to trial one use the screen below to register your newly installed guest.
    Click Forward to continue.
    1. Confirm your choices for RHN.
    2. You may see an additional screen if you did not configure RHN access. If RHN access is not enabled, you will not receive software updates.
      Click the Forward button.
  22. Create a non root user account. It is advised to create a non root user for normal usage and enhanced security. Enter the Username, Name and password.
    Click the Forward button.
  23. If a sound device is detected and you require sound, calibrate it. Complete the process and click Forward.
  24. You can install additional packages from a CD or another repository using this screen. It is often more efficient to not install any additional software at this point but add packages later using the yum command or RHN. Click Finish.
  25. The guest now configure any settings you changed and continues the boot process.
  26. The Red Hat Enterprise Linux 5 login screen displays. Log in using the username created in the previous steps.
  27. You have now successfully installed a para-virtualized Red Hat Enterprise Linux guest.