Installing oVirt 3.5 on CentOS 7 (Hosted Engine)

Posted on by 22 comments

I have had many people come to my blog looking how to install oVirt 3.5 software on the new CentOS 7. Much of this content is the same as my 3.4 post, but I thought I would keep it separate. Below are simple step by step instructions for installing the node and getting it configured for the hosted engine.

Installation Requirements

Please Note: Installing Hosted Engine on CentOS 7 requires oVirt 3.5.1
Please Note: Both the node and engine will be running CentOS 7 (Minimal Installation)
Please Note: Ensure the host is fully updated via “yum update” and rebooted before proceeding

Prerequisites

DNS

Ensure you have set up hostnames for the host and engine. If you do not have a DNS server configured and you are only testing oVirt on a single server, you can use /etc/hosts instead. I have the following:

Engine: Hostname: engine.xrsa.net, IP Address: 192.168.122.101/24
Host:
Hostname: ovirt01.xrsa.net, IP Address: 192.168.122.100/24

NFS

Ensure you have set up NFS mount points for the engine and virtual machines. If you do not have a shared NFS server and you are only testing oVirt on a single server, you can configure NFS locally on the host instead as shown below.

Please Note: UID/GID of 36:36 is vdsm:kvm which is created when you install oVirt. However, you do not require this user to be created for NFS to work properly.

Verify you can see and properly mount the correct mount points.

Installation

NTP

This not a requirement, but it is recommended that you keep your servers time in sync:

You may put your own NTP servers in /etc/ntp.conf if required.

Once you have verified DNS and NFS, install the required repositories and packages.

We will need an ISO for the hosted engine installation.

Please Note: UID/GID of 36:36 is vdsm:kvm which is created when you install oVirt.

Now all the prerequisites are in place, verify DNS and then go through the hosted-engine wizard.

When running the wizard make sure you select the Boot type of CDROM, else you will get asked for an OVA file instead.

The hosted-engine wizard will give you VNC details so you can connect to the hosted engine virtual machine and install CentOS 7.

Please note: You never VNC to the virtual machines themselves, you always VNC to the oVirt Host that particular virtual machine is running on from your PC/Laptop. Each running virtual machine on the host will get assigned a dedicated port which will give you Video / Keyboard via VNC.

Getting console access to your virtual machines is much easier once you get to the oVirt Interface, but as we don’t have that yet the first virtual machine running on a host will be assigned port 5900. So in order for us to connect to the hosted engine to install CentOS 7, we would connect to our host on that port as shown below:

Please Note: When installing CentOS 7 I recommend that you configure your Hostname/Network Settings.

Once installed choose option (1) on the hosted-engine wizard, it will wait until you have rebooted the hosted engine virtual machine. The wizard will give you another set of VNC details to connect to if you need it. However, if you configured networking during the install you should be able to SSH instead.

Once you have connected to the hosted engine, download the repositories, configure NTP and run through the ovirt-engine wizard. Please make sure the admin password matches up with the password set in the hosted-engine wizard.

Please note: Ensure DNS is configured properly so the engine can resolve itself and the host, else the installation will fail!

Please note: While in the engine setup wizard below ensure you put a proper ACL for the “NFS export ACL” option. If you do not you will not be able to activate the ISO_DOMAIN later.

Once finished go back to the hosted-engine wizard and finish off the installation by choosing option (1). It will ask you one final time for the hosted engine to be shutdown, wait a few minutes and it will come back up automatically.

After around a minute you can verify the state of the hosted engine virtual machine by using the following command:

Data Domain and ISO_Domain Setup

Before you can create virtual machines in oVirt you need to create a Data Domain and ensure the ISO_DOMAIN is attached to the Default cluster.

Navigate to https://engine.xrsa.net and login with admin.

Create a new Data / NFS Domain by going to “System -> Storage -> New Domain”:

ovirt_create_datadomain

You must wait until the NFS01 Data Domain is in an active state.

ovirt_datadomain_active

Once activated attach the ISO_DOMAIN to the Default Data Center:

ISO_DOMAIN_attach

Please note: If you are having issues attaching ISO_DOMAIN to the cluster you might have forgot to add a proper ACL on the “NFS export ACL” option during the engine wizard. You can check this as follows:

If everything went as expected you should see both the NFS01 and ISO_DOMAIN in an up and active state:

ISO_NFS_DOMAIN_UP

Uploading ISO Images

There is no GUI based ISO upload tool during this time, so to upload ISO images you must login to the engine first and run the following commands:

Using oVirt

At this point everything should be up and running for you to start creating virtual machines. For more information please read the oVirt Documentation: http://www.ovirt.org/Documentation

Category: Virtualization

22 comments on “Installing oVirt 3.5 on CentOS 7 (Hosted Engine)

  1. I was wondering if oVirt and CentOS/RHEL 7 would be compatible for a Hosted engine config, since others say the engine only supports running on CentOS 6.

    So yeah, thanks for your work.

    • You’re right, that was the case even when they released 3.5.0. But since 3.5.1 RHEL7/CentOS7 is fully supported with Hosted Engine.

  2. Whats the reasoning of runnning ovirt engine in its own vm when using a single node setup?

    • It allows you to use the same host to host virtual machines and the hosted engine itself, this is very useful when you want to try out oVirt. However in a production environment you would expand on this setup by having more than one host configured for HA and having a shared SAN infrastructure.

  3. Hi,

    I am using ovirt 3.5 engine setup.

    My question is how to convert physical server to virtual machine.

    Regards,

    Sonu Gupta

    • Hi,

      You can use the virt-p2v utility for this.

  4. Thanks Ben for a informative and simple guide that works.

    /T

  5. what user and group are this 36:36 should really be those number are local to you
    I do not have a group 36 in a cents 6.5 minimal install

    • It does not matter if you have that user/group on the system at all when providing NFS services, as you would require the same permissions even if you had an array such as NetApp.

      These uids/guids are used when writing files to your NFS server, so if these are not set correctly you will get permission issues.

  6. Isn’t 36:36 the UID:GID of vdsm user added from Ovirt?

    • Hi Alex,

      You are quite right, it’s vdsm:kvm. I have updated the NFS Section article to make this more clear. The reason I did not include that in my article was that local or remote NFS services do not require the user/group to be in play for it to work, providing the GID/UID is set correctly.

      Thanks,
      Ben

  7. Thank you Ben for the clarification.

    I was not aware that Ovirt engine can be installed on Centos7 and never read an official statement from Ovirt site. Still on their site they list only Centos6.5.

    I tried to prepare a Centos7 environment, with Ovirt hosted on Centos7 VM and two hosts with Centos7.
    Everything went fine (with some minor issues that were fixed) untill the installation of VMs. I’m encountering the following error (as displayed on Ovirt GUI), which seems to be related with the machine types qemu supports on the host side:

    qemu-kvm: -machine pc-1.0,accel=kvm,usb=off: Unsupported machine type Use -machine help to list supported machines!

    When listing the relevant key in Ovirt engine is lists the below:
    engine-config -g ClusterEmulatedMachines
    ClusterEmulatedMachines: rhel6.2.0,pc-1.0 version: 3.0
    ClusterEmulatedMachines: rhel6.3.0,pc-1.0 version: 3.1
    ClusterEmulatedMachines: rhel6.4.0,pc-1.0 version: 3.2
    ClusterEmulatedMachines: rhel6.4.0,pc-1.0,pseries version: 3.3
    ClusterEmulatedMachines: rhel6.5.0,pc-1.0,pseries version: 3.4
    ClusterEmulatedMachines: rhel6.5.0,pc-1.0,pseries version: 3.5

    The issue persists even when changing the last key values to :
    ClusterEmulatedMachines: rhel7.1.0,pc version: 3.5

    The same happened when running Ovirt engine on top Centos6.5 and the hosts on Centos7.
    When setting up all (engine + hosts) on top Centos 6.5 all went fine.

    Did you happen to encounter such an issue with Centos7?
    Thank you.

  8. Just to add on my last comment:

    The issue was caused from a native qemu installation conflicting with the ev version installed from ovirt. Removing that and making a clean install of ovirt-engine resolved the issue.

  9. Hi Alex,

    I am glad you sorted it! I have let the comments through just in case anyone else experiences that issue.

    Thanks,
    Ben

  10. I was wondering, I have my a single ovirt running in my environment(hosted Engine) with VMs hosted in managed hosts redundancy. I see my engine as the single point of failure, how can I address this to minimize down-time?

    • Hi Kulwa,

      If you only have a single physical host there is no redundancy. However, if you have more than one oVirt host you can configure the additional host to handle the Hosted Engine as well. The Hosted Engine will only run on one of these hosts, but if a host fails it’ll get restarted on another host.

      Please see:

      http://www.ovirt.org/Features/Self_Hosted_Engine#UI_-_additional_host_deployment

      I will add a section to my article for adding additional hosts.

      Thanks,
      Ben

  11. That is what I can call a detailed and right to the point tutorial! Thanks Ben, extremely useful!

  12. Hello Ben

    This is a really great article but I was wondering why you did this in the NFS part -> “mount ovirt01.xrsa.net:/home/engineha /mnt && umount /mnt” It appears you are mounting the export then unmounting the whole mount partition. Am I missing something?

    Thanks,

    • Hi Michael,

      That section is to simply verify you are able to mount that NFS share. It’s not required but it’s nice to verify this before you run the installer.

      Thanks,
      Ben

  13. Hello Ben,

    I have followed your article all is well until I get to the VM Configuration, it is asking for the OVF path/archive That is not indicated in your article you have the minimal iso install for cent os, Am I doing something worng?

    • Hi Michael,

      I’m assuming you’re at the hosted-engine –deploy section, ensure you have stated that the Boot type is cdrom.

      You can use the information below the CONFIGURATION PREVIEW as a reference, but please change it to suit your environment.

      Thanks,
      Ben

  14. Hello Ben,

    Good NEws, i did get it going

    –== Host 1 status ==–

    Status up-to-date : True
    Hostname : starfleet.coopfire.loc
    Host ID : 1
    Engine status : {“health”: “good”, “vm”: “up”, “detail”: “up”}
    Score : 3400
    stopped : False
    Local maintenance : False
    crc32 : 4907baf8
    Host timestamp : 10088

    Awesome!

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">