CloudForms Installation and Configuration Guide for Red Hat Enterprise Virtualization



In this article we will deploy CloudForms 4.2 on Red Hat Enterprise Virtualization (RHEV). We will also show how to configure CloudForms in order to properly manage a RHEV cluster and it’s hosts as well as virtual machines. Before you begin a RHEV cluster is needed. If you haven’t set one up, here is a guide on how to build a basic two node RHEV cluster.

Install CloudForms

CloudForms is provided by Red Hat as a virtual applicance. Red Hat provides appliances for many infrastructure platforms such as RHEV, VMware, Hyper-V, OpenStack, AWS, GCE and Azure. In this case we will download the RHEV virtual appliance. Download Image Image should be downloaded to the CFME appliance using your RHN login.—4.2/4.2/x86_64/product-software Add Appliance into RHEV Export Domain In order to import an appliance it needs to be copied to export domain or imported to export domain using CLI.
# cp cfme-rhevm- /usr/share/export/30621071-3dba-401d-9605-02a914b4069a
Once copied to export domain we need to extract the appliance and set permissions.
# cd /usr/share/export/30621071-3dba-401d-9605-02a914b4069a/
# tar xvf cfme-rhevm-5.3-15.x86_64.rhevm.ova
# chown -R 36:36 images/
# chown -R 36:36 master/
Import CFME Appliance as Template Once the appliance is in the export domain we can import it as an appliance using the RHEV-M management console. Under export domain and template, choose the import option. rhevm_cfme_imported rhevm_import_cfme We can provide our CFME template with a new name. cfme_import_2 Once import completes the status will change to “OK”. rhevm_cfme_import_complete Create CloudForms Virtual Machine Under “Virtual Machines”, select “new” in the RHEV-M management console. For template choose the newly imported CFME template. cfme_new_vm Add Additional Disk for CloudForms Database Under CFME “Virtual Machine” Disks select “new” to add a new disk. I would recommend 30GB but this is based on how much data is to be collected and for how long. cfme_db_disk

Configure Appliance

Start CFME VM from RHEV-M management console. Login as “root/smartvm” and run “appliance_console” to configure CloudForms. cfme_setup1 Configure static network settings cfme_setup2 Configure local database cfme_db_1 Make sure you create an internal database cfme_db_2 Choose a disk, this should be the 30GB disk we added cfme_db_3 Choose “N” to run standalone database server cfme_db_4 Create database region and choose password cfme_db_5 Restart the CFME appliance cfme_db_6 Below are the basic settings that should be configured cfme_db_7

Configure RHEV for CloudForms

In order for CloudForms to report capacity & utilization we need to configure access from RHEV-M. Login to RHEV-M host using ssh as root Connect to RHEV-M database
# su - postgres
As postgres user add a new role for CloudForms. As of this article CloudForms needs superuser but there is an RFE to enable read-only access in future.
$ psql -U postgres CREATE ROLE cfme LOGIN UNENCRYPTED PASSWORD 'redhat01' \
  Open firewall ports to allow communication to database
# firewall-cmd --add-port=5432/tcp --permanent
# firewall-cmd --reload
Ensure PostgreSQL is exposing port and listening to all interfaces
# vi /var/lib/pgsql/data/pg_hba.conf
host all all md5
# vi /var/lib/pgsql/data/postgresql.conf
listen_addresses = '*'
Restart PostgreSQL database
# service postgresql reload

Configure RHEV Provider in CloudForms

Connect to CloudForms management console Using browser you can simply hit the IP of CloudForms appliance using https. Login with “admin/smartvm”. cfme_login Add RHEV Provider Under providers, choose “Infrastructure Providers” and “new”. Add the default credentials using IP or name of RHEV-M host. The user should be admin@internal for RHEV-M. Once that is complete, go to the “C& U Database” tab. Here you will enter the IP or name for the RHEV-M host and the superuser credentials you created above. In this example “cfme/redhat01”. cfme_add_rhev_providerConfigure Hypervisors CloudForms requires access to hypervisors for certain capabilities like “smart state analysis”. Ability to peer inside VM images in order to for example, check security vulnerabilities. In this environment there are two hypervisor hosts (rhevh01.lab and rhevh02.lab). Configure RHEVH01 Under RHEV infrastructure provider select host rhevh01.lab and configure. cfme_rhev_hypervisor Configure RHEVH02 Under RHEV infrastructure provider select host rhevh02.lab and configure. cfme_rhev_hypervisor2 Enable Capacity and Utilization On upper far right in CloudForms management console under user, select “Configuration”. Enable the Capacity and Utilization roles underthe “Server: EVM”. C & U cfme_c+u Set SmartProxy Affinity Under “Zone: Default Zone” associate all hosts and datastores. cmfe_c+u2 Enable Capacity and Utilization Collection of RHEV Environment Under “CFME:Region” enable collection for all clusters and datastores. cfme_c+u4 At this point CloudForms is collecting capacity and utilization statistics and after a few hours you should start seeing data under VM. You can also use planning to forecast and model various growth scenarios.


In this article we installed and configured the CloudForms appliance on an existing RHEV cluster. We prepared RHEV-M for CloudForms data collection. Configured a new infrastructure provider for RHEV in CloudForms. Finally we enabled capacity and utilization for RHEV within CloudForms. Happy CloudForming! (c) 2017 Keith Tenzer  
, , , , ,

Leave a Reply

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

%d bloggers like this: