Welcome to Part 4 for this series about OpenStack and VMware NSX. To do a quick review, in the first three parts we described the different VMware NSX components and concepts and how to install and configure them, also discussed how to install and configure the KVM and GlusterFS nodes. In this fourth part of the series we will see how to deploy OpenStack in a three-node architecture and integrate it with our existent NSX installation.
If you remember the first post where I described the components of the lab, there were three OpenStack dedicated nodes:
- Cloud controller node
- Neutron networking node
- Nova compute node
Instead of installing from scratch I decided to go with one of the OpenStack distributions: RDO. What is RDO and why I decided for it? RDO is a community distribution of OpenStack sponsored by Red Hat, yes I just say Red Hat so please stop the eye rolling.
RDO is the upstream version of RHEL OpenStack Platform, the commercial version of OpenStack by Red Hat. During the last months I tried several flavors of OpenStack and while I still think that installing from scratch is the best way to learn, in fact is what I did for my first labs, RDO gives me the possibility to quickly create my testing labs. Also RHEL OP Version 4, based on RDO, is supported with VMware NSX and I really couldn’t resist myself to try it.
Before proceeding with the installation there are some preparations weneed to perform on the OpenStack nodes.
SSH key generation
Generate a new SSH key to be later distributed on the OpenStack nodes during the installation. Use
ssh-keygen to generate the new key.
Neutron server preparation
In the Neutron node install NSX Open vSwitch version as described in Part 3 for the KVM nodes, the network interface configuration it’s quite similar.
With the network interface configuration files properly setup exist your SSH session and log into the VM console to create the OVS bridges like the example below.
RDO relies on
packstack for the installation of its different components. Packstack is a tool that will install all required software in the nodes based on an answer file. Enable RDO and EPEL repos and install
Once it is installed generate a new answer file, we will use this file as a template for our installation.
packstack answer file and modify the following entries, leave the rest with the default values. It is important to do not eliminate any entry or
packstack execution will fail.
Deactivate services we do not want to deploy.
And finally Neutron settings. Don’t set any L3 value since that part will be managed by NSX.
Launch OpenStack installation process.
The installation will take a while so you better grab a cup of coffee and have a look at the output while the software installs on each of the three nodes. If everything goes as expected we should see a similar message at the of the installation process.
Reboot the three nodes as instructed and proceed to the next step.
Configure Glance to use GlusterFS
packstack cannot configure Glance to use GlusterFS as its storage backend during the installation and it has to be configured afterwards. Fortunately the necessary steps are documented on RDO site.
Stop Glance services.
Install gluster required packages on the controller node.
Mount GlusterFS share and set the ownership and permissions for
Start Glance services.
With the installation finished OpenStack Horizon dashboard should be available at http://cloud_controller_fqdn/dashboard. Log in with the user admin, the password for this user can be found in the file
/root/keystonerc_admin on the cloud controller node.
If login fails with an unexpected error check that firewall is deactivated in all three nodes and that all services are up and running, in some of my deployments Neutron server did not start after a reboot and I had to start it manually.
Once logged into horizon navigate to Admin -> Hypervisor and check that the KVM hypervisor is properly registered.
Configure the NSX integration
At this point we have a working OpenStack installation with Neutron using the Open vSwitch plugin, now we will proceed to integrate our shiny OpenStack cloud with NSX.
Install NSX Neutron plugin
VMware provides a set of RPM packages containing the NSX plugin and a VMware sanctioned version of Neutron, however I found that this packages were older than my Havana installation and didn’t want to brake any dependencies and spend hours trying to fix my installation.
A tar file containing all the source for both the plugin and Neutron itself is also available and instructions on how to compile and install it are provided in NSX documentation, during my first trials I took this path but this time I decided to use the upstream plugin instead since it was available in RDO repositories.
Configure NSX plugin
Register the Neutron server as a transport node on the NSX Controller Cluster.
Stop neutron services.
/etc/neutron/neutron.conf file and set
core_plugin value to
nvp.ini file accordingly, this file can be found in
Set NSX admin user and password.
Configure NSX controllers IP addresses.
Set the default Transport Zone UUID and the L3 and L2 gateway services UUID, these values can be retrieved from the NSX Manager web.
Configure metadata for Nova instances, set
[DEFAULT] section. In
[nvp] section set the metadata mode as
[database] section and configure the connection to Neutron MySQL database, the data can be found on
Finally before start Neutron services check
nvp.ini with the command
neutron-check-nvp-config. You should get something like this.
Start Neutron services
Create a network neutron command line to test that everything is working as expected.
Access NSX Manager web interface, navigate to Logical Switches and confirm that a new logical switch with the same name and UUID as the new OpenStack network has been created.
Congratulations! We have successfully deployed a distributed installation of OpenStack with KVM as the underlying hypervisor and integrated with VMware NSX state of the art network virtualization software. In future posts out of this four article series we will discuss some tips and other parts of OpenStack and NSX. Courteous comments are welcome.