'''While many changes have been checked in and validated, we are still improving and updating our baseline puppet deployment manifests to address some issues raised by early adopters and additional testing of the Cisco Edition. Please check back after December 15th for an updated release which should simplify the changes needed to the build manifests.'''

+

<br>

-

== Overview ==

+

== Overview ==

-

In the Cisco OpenStack distribution, a build server outside of the OpenStack cluster is used to manage and automate the OpenStack software deployment. This build server primarily functions as a [http://puppetlabs.com/puppet/puppet-open-source/ Puppet] server for software deployment and configuration management onto the OpenStack cluster, as well as a [http://cobbler.github.com/ Cobbler] installation server to manage the PXE boot used for rapid bootstrapping of the OpenStack cluster.

+

Building OpenStack with the Cisco Edition will enable you to deploy a multi-node OpenStack system with Quantum enabled network services management. The system will also enable a simple monitoring function based on Nagios, Collectd, and Graphite.

-

Once the build server is installed and configured, it is used as an out-of-band automation and management workstation to bring up, control, and reconfigure (if later needed) the nodes of the OpenStack cluster. It also functions as a monitoring server to collect statistics about the health and performance of the OpenStack cluster, as well as to monitor the availability of the machines and services which comprise the OpenStack cluster.

+

In the Cisco OpenStack Edition (COE), an initial build server outside of the OpenStack cluster is used to manage and automate the OpenStack software deployment. This build server primarily functions as a [http://puppetlabs.com/puppet/puppet-open-source/ Puppet] server for software deployment and configuration management onto the OpenStack cluster, as well as a [http://cobbler.github.com/ Cobbler] installation server to manage the PXE boot used for rapid bootstrapping of the OpenStack cluster.

-

This current deployment supports:

+

Once the build server is installed and configured, it is used as an out-of-band automation and management workstation to bring up, control, and reconfigure (if later needed) the nodes of the OpenStack cluster. It also functions as a monitoring server to collect statistics about the health and performance of the OpenStack cluster, as well as to monitor the availability of the machines and services which comprise the OpenStack cluster.

Although other configurations are supported, the following instructions target an environment with a build node, a controller node, and at least one compute node. Additional compute nodes may optionally be added, and swift nodes may also be added if desired.

+

*Swift

+

*Cinder

+

*Ceilometer

+

*Other OpenStack community incubated projects

-

When naming your nodes, make sure that

+

The current system is deployable on Cisco UCS B-series and C-series hardware along with Nexus "Top-of-Rack" class L2/L3 network switches, though using the deployment with other compute and network platforms is possible. The system leverages the Ubuntu 12.04 LTS ("Precise") Linux operating system with KVM as its base hypervisor platform and for the build/monitoring node, RedHat/CentOS/SL support with KVM for the hypervisor function is expected in a future release. There are no known limitations to virtualized machines running in the OpenStack environement as long as they can run in a KVM environment. The system does not currently support deployment of multiple hypervisors via Puppet.

-

*all compute nodes contain "compute" in their host name

+

You can find bugs, release milestones, and other information on [https://launchpad.net/openstack-cisco Launchpad]. You can find release notes for the most recent release [https://launchpad.net/openstack-cisco/folsom/2012.2.3 here].

-

*all control nodes contain "control" in their host name

+

-

*all swift nodes contain "swift" in their host name

+

-

Also, these instructions primarily target deployment of OpenStack onto UCS servers (either blades or rack-mount form factors). Several steps in the automation leverage the UCS manager to execute system tasks. Deployment on non-UCS gear may well work, but may require additional configuration or additional manual steps to manage systems.

+

<br>

-

COE Folsom requires that you have two physically or logically (VLAN) separated IP networks. You must have an external router or layer-3 switch that provides connectivity between these two networks. This is a variation of the Quantum metadata server support requirement:

One network is used to provide connectivity for OpenStack API endpoints, Open vSwitch (OVS) GRE endpoints, and OpenStack/UCS management. The second network is used by OVS as the physical bridge interface and by Quantum as the public network.

-

=== Creating a build server ===

-

To deploy Cisco OpenStack, first configure a build server. This server has relatively modest hardware requirements: 2 GB RAM, 20 GB storage, Internet connectivity, and a network interface on the same network as the eventual management interfaces of the OpenStack cluster machines are the minimal requirements. This machine can be physical or virtual; eventually a pre-built VM of this server will be provided, but this is not yet available.

+

Although other configurations are supported, the following instructions target an environment with a build node, a controller node, and at least one compute node. Additional compute nodes may optionally be added.

-

Install Ubuntu 12.04 LTS onto this build server. A minimal install with openssh-server is sufficient. Configure the network interface on the OpenStack cluster management segment with a static IP. Also, when partitioning the storage, choose a partitioning scheme which provides at least 15 GB free space under /var, as installation packages and ISO images used to deploy OpenStack will eventually be cached there.

+

Also, these instructions primarily target deployment of OpenStack onto UCS servers (either blades or rack-mount form factors). Several steps in the automation leverage the UCS manager or CIMC to execute system tasks. Deployment on non-UCS gear may well work, particularly if the gear has functional IPMI, but may require additional configuration or additional manual steps to manage systems.

-

When the installation finishes, log in and become root:

+

COE Folsom requires that you have two physically or logically (VLAN) separated IP networks. You must have an external router or layer-3 switch that provides connectivity between these two networks. This is required in order to support Quantum and the Cloud-Init metadata server for Provider Router based deployments (similar to FlatDHCP + Floating IP support in the nova-network model):<br>[http://docs.openstack.org/folsom/openstack-network/admin/content/adv_cfg_l3_agent_metadata.html http://docs.openstack.org/folsom/openstack-network/admin/content/adv_cfg_l3_agent_metadata.html]<br>

-

<pre>sudo -H bash</pre>

+

One network is used to provide connectivity for OpenStack API endpoints, Open vSwitch (OVS) GRE endpoints, and OpenStack/UCS management. The second network is used by OVS as the physical bridge interface and by Quantum as the public network

-

''Optional: If you have your build server set up behind a non-transparent web proxy, you should export your proxy configuration:

-

<pre>export http_proxy=http://proxy.esl.cisco.com:80

-

export https_proxy=https://proxy.esl.cisco.com:80</pre>

-

''Replace proxy.es1.cisco.com:80 with whatever is appropriate for your environment.

-

Now you have two choices. You can follow the manual steps below, or you can run a one line script that tries to automate this process. In either case, you should end up with the puppet modules installed, and a set of template site manifests in /etc/puppet/manifests.

+

=== Creating a build server ===

-

To run the install script, copy and paste the following on your command line (as root with your proxy set if necessary as above):

+

To deploy Cisco OpenStack, first configure a build server. This server has relatively modest hardware requirements: 2 GB RAM, 20 GB storage, Internet connectivity, and a network interface on the same network as the eventual management interfaces of the OpenStack cluster machines are the minimal requirements. This machine can be physical or virtual; eventually a pre-built VM of this server will be provided, but this is not yet available.

Install Ubuntu 12.04 LTS onto this build server. A minimal install with openssh-server is sufficient. Configure the network interface on the OpenStack cluster management segment with a static IP. Also, when partitioning the storage, choose a partitioning scheme which provides at least 15 GB free space under /var, as installation packages and ISO images used to deploy OpenStack will eventually be cached there.<br>When the installation finishes, log in and become root:<br>

+

<pre>sudo -H bash</pre>

+

'''NOTE:''' If you have proxies, or your control and compute nodes do not have internet access, please read the following:

-

You can now jump to "Customizing your build server". Otherwise, follow along with the steps below.

+

If you require a proxy server to access the internet, be aware that proxy users have occasionally reported problems during the phases of the installation process that download and install software packages. A common symptom of proxy trouble is that apt will complain about hash mismatches or file corruptions when verifying downloaded files. A few known scenarios and workarounds include:

-

All should now install any pending security updates:

+

*If the apt-get process reports a "HASH mismatch", you may be facing an issue with a caching engine. If it's possible to do so, bypassing the caching engine may resolve the problem.

*If you do have a proxy, you will want, at a minimum, to export the two types of proxies needed in your root shell when running fetch commands, as noted in the relevant sections.

+

*You will also want to change the $proxy setting in site.pp to reflect your local proxy.<br>

-

''Note: The system may need to be restarted after applying the updates.

+

Another possible change is if you don't have "public" Internet accessible IPs for all of your machines (build, control, compute, etc.) and are building this in a controlled environment. If this is the case, ensure that $default_gateway is *not* set in site.pp and all of the files required for installing the control and compute nodes will be fetched from the boot server.

-

Get the Cisco Edition example manifests. Under the [https://github.com/CiscoSystems/folsom-manifests/branches folsom-manifests GitHub repository] you will find different branches, so select the one that matches your topology plans most closely. In the following examples the simple-multi-node branch will be used, which is likely the most common topology:

+

'''IMPORTANT''': If you have proxies, and you set your proxy information in either your .profile or in a file like /etc/environment, you will need to set both http_proxy and https_proxy. You will also need to set a no_proxy command at least for the build node. An example might look like:

Copy the puppet manifests from ~/cisco-folsom-manifests/manifests/ to /etc/puppet/manifests/

+

<span style="line-height: 1.5em;">You have two choices for setting up the build server. You can follow the manual steps below, or you can run a one line script that tries to automate this process. In either case, you should end up with the puppet modules installed, and a set of template site manifests in /etc/puppet/manifests.</span>

''Optional: If your set up is in a private network and your build node will act as a proxy server and NAT gateway for your OpenStack cluster, you need to add the corresponding NAT and forwarding configuration.

Get the Cisco Edition example manifests. Under the [https://github.com/CiscoSystems/folsom-manifests/branches folsom-manifests GitHub repository] you will find different branches, so select the one that matches your topology plans most closely. In the following examples the multi-node branch will be used, which is likely the most common topology:

In the /etc/puppet/manifests directory you will find these three files:

+

In the /etc/puppet/manifests directory you will find these files:

-

<pre>site.pp

+

<pre>clean_node.sh

+

cobbler-node.pp

core.pp

core.pp

-

cobbler-node.pp

+

modules.list

-

clean_node.sh

+

puppet-modules.sh

-

puppet_modules.sh

+

reset_nodes.sh

+

site.pp.example

</pre>

</pre>

+

<span style="line-height: 1.5em;">At a high level, cobbler-node.pp manages the deployment of cobbler to support booting of additional servers into your environment. The core.pp manifest defines the core definitions for openstack service deployment. The site.pp.example manifest captures the user modifiable components and defines the various parameters that must be set to configure the OpenStack cluster, including the puppetmaster and cobbler setup on the build server. clean_node.sh is a shell script provided as a convenience to deployment users; it wraps several cobbler and puppet commands for ease of use when building and rebuilding the nodes of the OpenStack cluster. reset_nodes.sh is a wrapper around clean_node.sh to rebuild your entire cluster quickly with one command.</span>

-

At a high level, cobbler-node.pp manages the deployment of cobbler to support booting of additional servers into your environment. The core.pp manifest defines the core definitions for openstack service deployment. The site.pp manifest captures the user modifiable components and defines the various parameters that must be set to configure the OpenStack cluster, including the puppetmaster and cobbler setup on the buidl server. clean_node.sh is a shell script provided as a convenience to deployment users; it wraps several cobbler and puppet commands for ease of use when building and rebuilding the nodes of the OpenStack cluster.

+

IMPORTANT! You must copy site.pp.example to site.pp and then edit it as appropriate for your installation. It is internally documented.

If you require a proxy server to access the internet, be aware that proxy users have occasionally reported problems during the phases of the installation process that download and install software packages. A common symptom of proxy trouble is that apt will complain about hash mismatches or file corruptions when verifying downloaded files. A few known scenarios and workarounds include:

+

-

+

-

+

-

1.) The Cisco Web Security Appliance (also known as "WSA" or "Ironport" products) has a bug in software versions prior to 7.5.1 that causes the IF-Range header to be dropped in certain circumstances. This bug is fixed in update 7.5.1. More information can be found here:

+

-

+

-

https://bugs.ironport.com/show_bug.cgi?id=86056

+

-

+

-

+

-

2.) If the apt-get process reports a "HASH mismatch", you may be facing an issue with a caching engine. If it's possible to do so, bypassing the caching engine may resolve the problem. If you are behind a Cisco Application and Content Networking System (ACNS), be aware of a bug that may cause data transfer toward HTTP clients to get terminated by TCP RST when client site persistent connections are disabled and HTTP pipelining is used. More information on this defect can be found here:

You can work around this issue by disabling HTTP pipelining by adding the following to your site.pp near the top of the file:

+

-

+

-

file { '/etc/apt/apt.conf.d/00no_pipelining':

+

-

ensure => file,

+

-

owner => 'root',

+

-

group => 'root',

+

-

mode => '0644',

+

-

content => 'Acquire::http::Pipeline-Depth "0";'

+

-

}

+

-

+

-

+

-

+

-

+

When the puppet apply command runs, the puppet client on the build server will follow the instructions in the site.pp and cobbler-node.pp manifests and will configure several programs on the build server:

When the puppet apply command runs, the puppet client on the build server will follow the instructions in the site.pp and cobbler-node.pp manifests and will configure several programs on the build server:

-

*ntpd -- a time synchronization server used on all OpenStack cluster nodes to ensure time throughout the cluster is correct<br>

+

*ntpd -- a time synchronization server used on all OpenStack cluster nodes to ensure time throughout the cluster is correct

-

*tftpd-hpa -- a TFTP server used as part of the PXE&nbsp;boot process when OpenStack nodes boot up

+

*tftpd-hpa -- a TFTP server used as part of the PXE boot process when OpenStack nodes boot up

-

*dnsmasq -- a DNS and DHCP server used as part of the PXE&nbsp;boot process when OpenStack nodes boot up

+

*dnsmasq -- a DNS and DHCP server used as part of the PXE boot process when OpenStack nodes boot up

*cobbler -- an installation and boot management daemon which manages the installation and booting of OpenStack nodes

*cobbler -- an installation and boot management daemon which manages the installation and booting of OpenStack nodes

*apt-cacher-ng -- a caching proxy for package installations, used to speed up package installation on the OpenStack nodes

*apt-cacher-ng -- a caching proxy for package installations, used to speed up package installation on the OpenStack nodes

*nagios -- a infrastructure monitoring application, used to monitor the servers and processes of the OpenStack cluster

*nagios -- a infrastructure monitoring application, used to monitor the servers and processes of the OpenStack cluster

-

*collectd --a statistics collection application, used to gather performance and other metrics from the components of the OpenStack cluster<br>

+

*collectd --a statistics collection application, used to gather performance and other metrics from the components of the OpenStack cluster

-

*graphite and carbon -- a real-time graphing system for parsing and displaying metrics and statistics about OpenStack

+

*graphite and carbon -- a real-time graphing system for parsing and displaying metrics and statistics about OpenStack

''Replace node_name with the name of your controller, and example.com with your cluster's domain.

+

-

clean_node.sh is a script which does several things:

+

<br>clean_node.sh is a script which does several things:

-

*configures Cobbler to PXE&nbsp;boot the specified node with appropriate PXE&nbsp;options to do an automated install of Ubuntu <br>

+

*Configures Cobbler to PXE boot the specified node with appropriate PXE options to do an automated install of Ubuntu

-

*uses Cobbler to power-cycle the node

+

*Uses Cobbler to power-cycle the node

-

*removes any existing client registrations for the node from Puppet, so Puppet will treat it as a new install

+

*Removes any existing client registrations for the node from Puppet, so Puppet will treat it as a new install

-

*removes any existing key entries for the node from the SSH known hosts database

+

*Removes any existing key entries for the node from the SSH known hosts database

-

When the script runs, you may see errors from the Puppet and SSH clean up steps if the machine did not already exist in Puppet or SSH. This is expected, and not a cause for alarm.

+

You can watch the progress on the console of your controller node as cobbler completes the automated install of Ubuntu. Once the installation finishes, the controller node will reboot and then will run puppet after it boots up. Puppet will pull and apply the controller node configuration defined in the puppet manifests on the build server.

-

You can watch the progress on the console of your controller node as cobbler completes the automated install of Ubuntu. Once the installation finishes, the controller node will reboot and then will run puppet after it boots up. Puppet will pull and apply the controller node configuration defined in the puppet manifests on the build server.

+

This step will take several minutes, as puppet downloads, installs, and configures the various OpenStack components and support applications needed on the control node. /var/log/syslog on the controller node will display the progress of the puppet configuration run.

-

This step will take several minutes, as puppet downloads, installs, and configures the various OpenStack components and support applications needed on the control node. /var/log/syslog on the controller node will display the progress of the puppet configuration run.

+

'''NOTE:''' It may take more than one puppet run for the controller node to be set up completely, especially if there are proxies in the path as some proxies can have issues with apt-get installs and updates. Observe the log files (/var/log/syslog on the controller node) to verify that the controller configuration has converged completely to the configuration defined in puppet.

-

''Note that it may take more than one puppet run for the controller node to be set up completely. Observe the log files to verify that the controller configuration has converged completely to the configuration defined in puppet.

+

Once the puppet configuration of the controller has completed, follow the same steps to build each of the other nodes in the cluster, using clean_node.sh to initiate each install. As with the controller, the other nodes will take several minutes for puppet configuration to complete, and may require multiple runs of puppet before they are fully converged to their defined configuration state.

-

Once the puppet configuration of the controller has completed, follow the same steps to build each of the other nodes in the cluster, using clean_node.sh to initiate each install. As with the controller, the other nodes will take several minutes for puppet configuration to complete, and may require multiple runs of puppet before they are fully converged to their defined configuration state.

+

As a short cut, if you want to build all of the nodes defined in your cobbler-node.pp file, you can run:<br>

+

<pre>for n in `cobbler system list`; do clean_node.sh $n&nbsp;; done</pre>

+

Or you can run a full reset script which also does this, and re-runs the build-node puppet apply and puppet plugin download steps:

+

<pre>./reset_nodes.sh

+

</pre>

-

As a short cut, if you want to build ''all'' of the nodes defined in your cobbler-node.pp file, you can run:

+

Once the OpenStack nodes have been built using cobbler, run puppet on the build node a second time:

Once the nodes are built, and once puppet runs have completed on all nodes (watch /var/log/syslog on the cobbler node), you should be able to log into the OpenStack Horizon interface:

+

This second puppet run will gather information about the individual OpenStack nodes collected by puppet when they were being built, and use that information to set up status monitoring of the OpenStack cluster on the build server.

you will still need to log into the console of the control node to load in an image: user: localadmin, password: ubuntu. If you SU to root, there is an openrc auth file in root’s home directory, and you can launch a test file in /tmp/nova_test.sh.

-

== Deploy Your First VM ==

-

The following deployment steps should be used after completing clean puppet runs on OpenStack Nodes and restarting quantum-server and quantum-plugin-openvswitch-agent services.

+

Once the nodes are built, and once puppet runs have completed on all nodes (watch /var/log/syslog on the cobbler node), you should be able to log into the OpenStack Horizon interface:

You will still need to log into the console of the control node to load in an image using user: localadmin, password: ubuntu. If you SU to root, you will need to source the openrc auth file which is in the root’s home directory (run "source openrc" in /root/), and you can launch a test file in /tmp/nova_test.sh.

-

2. We are using 192.168.221.0/24 as our external network. '''Note:''' The eth settings on the Controller Node associated to this network should be configured in bridged mode and not have an IP address assigned to it.

The following deployment steps should be used after completing clean puppet runs on OpenStack Nodes and restarting quantum-server and quantum-plugin-openvswitch-agent services.

-

quantum subnet-create net1 10.10.10.0/24

+

-

4. Create a virtual router and an associated interface used for the subnet created in the previous step:

+

=== Manual Process ===

-

quantum router-create router1

+

1. Create quantum public network.

-

quantum router-interface-add router1 <net1-subnet-uuid>

+

<pre>quantum net-create public --router:external=True</pre>

+

2. We are using 192.168.221.0/24 as our external network. '''Note:''' The eth settings on the Controller Node associated to this network should not have an IP address assigned to it as it will function in bridged mode.

+

<pre>quantum subnet-create public 192.168.221.0/24</pre>

+

'''NOTE:''' If there are upstream routers/L3 switches that use HSRP/GLBP/VRRP that use low-order IP addresses such as .2 and .3 then the default subnet address assignments used by Quantum for this subnet (such as floating IP addresses and the Qrouter interface [default is .3]) will directly conflict with these real IP addresses on the upstream first hop routers. You can alter these default address assignments for the Quantum subnet by using the the "--allocation-pool" range when creating the Quantum subnet. The example that follows will use the default upstream router address of .1 (in this example the upstream HSRP address would be 192.168.221.1) and the first addresses for floating-IPs will begin at .10:

3. Create the internal (data) network used for Tenants. Create additional networks and associated subnets as needed. In the example below, we are assigning specific DNS servers that will be used by the instances.&nbsp;

'''NOTE:'''&nbsp;Replace 8.8.8.8 8.8.4.4 with the IP address(es) of the DNS server or servers virtual machines should use.

+

4. Create a virtual router and an associated interface used for the subnet created in the previous step:

+

<pre>quantum router-create router1

+

quantum router-interface-add router1 &lt;net10-subnet-uuid&gt;</pre>

5. Connect the virtual router to your external network:

5. Connect the virtual router to your external network:

+

<pre>quantum router-gateway-set router1 &lt;public-net-id&gt;</pre>

+

You must create a static route on your physical router/layer-3 switch to the subnet that you define for your Tenants (quantum subnet-create command). The next-hop for the static route is the quantum router public interface. Use the following command to find the public address of your Quantum router:

5a. Continuing with our example, here is the required static route that MUST be configured on the external physical router/layer-3 switch. If you used the before mentioned "--allocation-pool" flag then the first address in the pool will be used for the qrouter address. So, in that example the next-hop entry for the example below would be "192.168.221.10":

You must create a static route on your physical router/layer-3 switch to the subnet that you define for your Tenants (quantum subnet-create command). The next-hop for the static route is the quantum router public interface. Use the following command to find the public address of your Quantum router:

9. Verify connectivity to Instance from the node running Quantum L3 Agent (Controller Node). Since we are using namespaces, we run the commands from the context of the qrouter using the "ip netns exec qrouter" syntax. Below, we list the qrouter to get its router-id, we connect to the qrouter and get a list of its addresses, we ping the instance from the qrouter and then we SSH into the instance from the qrouter:

*The script creates keys and places them in the /root/.ssh/ path therefore we are assuming you are running this script as root. If you are not running as 'root' then you need to change the path in the 'create_vm' file for the ssh-keygen line.

+

*If you have existing files in the /root/.ssh/ path then the script will see them and prompt you to overwrite. If you do not select to overwrite the existing keys then you may encounter a "permissions denied" error when SSH'ing into the test instance. If this happens then ensure that the key being referenced during the nova keypair-add step in the 'create_vm' script is correct.

-

Verify that your instance has spawned successfully:

+

'''Instructions'''<br>1. cd into the quantum-l3-test directory you just cloned:

+

<pre>cd quantum-l3-test</pre>

+

2) Run: ./create_vm this will run net_setup on its own

+

<pre>./create_vm</pre>

+

3) You will be prompted to enter your specific network values for the public/private networks as well as altering the default path where the Ubuntu Precise image is downloaded from (i.e. your own local mirror).

-

nova show <your_instance_name>

+

4) You should be able to log into the instance:

+

<pre>ssh ubuntu@{fixed or floating ip of instance}</pre>

+

To reset the Quantum settings created by the script and relaunch the test VM from scratch:

Congratulations! You have now completed a basic setup and should have a functional environment.'''

-

ip netns exec qrouter-<ID_of_quantum_router> ip addr list

+

=== Next Steps ===

-

ip netns exec qrouter-<ID_of_quantum_router> ping <fixed-ip>

+

System and service health monitoring of your OpenStack cluster is set up as part of the puppet deployment process. Once you have created your first VM, you should start seeing OpenStack status information show up in the health monitoring. To view Nagios health monitoring, log into the web page at:

-

# Note: you can get the router ID with the following command: quantum router-list

You may also wish to read the [http://docs.openstack.org/run/ OpenStack operations documents] on the [http://docs.openstack.org/ OpenStack documentation site]. Many users find the [http://docs.openstack.org/ops/ OpenStack Operations Guide] published in March of 2013 to be particularly helpful.

Overview

Building OpenStack with the Cisco Edition will enable you to deploy a multi-node OpenStack system with Quantum enabled network services management. The system will also enable a simple monitoring function based on Nagios, Collectd, and Graphite.

In the Cisco OpenStack Edition (COE), an initial build server outside of the OpenStack cluster is used to manage and automate the OpenStack software deployment. This build server primarily functions as a Puppet server for software deployment and configuration management onto the OpenStack cluster, as well as a Cobbler installation server to manage the PXE boot used for rapid bootstrapping of the OpenStack cluster.

Once the build server is installed and configured, it is used as an out-of-band automation and management workstation to bring up, control, and reconfigure (if later needed) the nodes of the OpenStack cluster. It also functions as a monitoring server to collect statistics about the health and performance of the OpenStack cluster, as well as to monitor the availability of the machines and services which comprise the OpenStack cluster.

The current system is deployable on Cisco UCS B-series and C-series hardware along with Nexus "Top-of-Rack" class L2/L3 network switches, though using the deployment with other compute and network platforms is possible. The system leverages the Ubuntu 12.04 LTS ("Precise") Linux operating system with KVM as its base hypervisor platform and for the build/monitoring node, RedHat/CentOS/SL support with KVM for the hypervisor function is expected in a future release. There are no known limitations to virtualized machines running in the OpenStack environement as long as they can run in a KVM environment. The system does not currently support deployment of multiple hypervisors via Puppet.

You can find bugs, release milestones, and other information on Launchpad. You can find release notes for the most recent release here.

Building the environment

Assumptions

Although other configurations are supported, the following instructions target an environment with a build node, a controller node, and at least one compute node. Additional compute nodes may optionally be added.

Also, these instructions primarily target deployment of OpenStack onto UCS servers (either blades or rack-mount form factors). Several steps in the automation leverage the UCS manager or CIMC to execute system tasks. Deployment on non-UCS gear may well work, particularly if the gear has functional IPMI, but may require additional configuration or additional manual steps to manage systems.

COE Folsom requires that you have two physically or logically (VLAN) separated IP networks. You must have an external router or layer-3 switch that provides connectivity between these two networks. This is required in order to support Quantum and the Cloud-Init metadata server for Provider Router based deployments (similar to FlatDHCP + Floating IP support in the nova-network model):http://docs.openstack.org/folsom/openstack-network/admin/content/adv_cfg_l3_agent_metadata.html

One network is used to provide connectivity for OpenStack API endpoints, Open vSwitch (OVS) GRE endpoints, and OpenStack/UCS management. The second network is used by OVS as the physical bridge interface and by Quantum as the public network

Creating a build server

To deploy Cisco OpenStack, first configure a build server. This server has relatively modest hardware requirements: 2 GB RAM, 20 GB storage, Internet connectivity, and a network interface on the same network as the eventual management interfaces of the OpenStack cluster machines are the minimal requirements. This machine can be physical or virtual; eventually a pre-built VM of this server will be provided, but this is not yet available.

Install Ubuntu 12.04 LTS onto this build server. A minimal install with openssh-server is sufficient. Configure the network interface on the OpenStack cluster management segment with a static IP. Also, when partitioning the storage, choose a partitioning scheme which provides at least 15 GB free space under /var, as installation packages and ISO images used to deploy OpenStack will eventually be cached there.When the installation finishes, log in and become root:

sudo -H bash

NOTE: If you have proxies, or your control and compute nodes do not have internet access, please read the following:

If you require a proxy server to access the internet, be aware that proxy users have occasionally reported problems during the phases of the installation process that download and install software packages. A common symptom of proxy trouble is that apt will complain about hash mismatches or file corruptions when verifying downloaded files. A few known scenarios and workarounds include:

If the apt-get process reports a "HASH mismatch", you may be facing an issue with a caching engine. If it's possible to do so, bypassing the caching engine may resolve the problem.

If you do have a proxy, you will want, at a minimum, to export the two types of proxies needed in your root shell when running fetch commands, as noted in the relevant sections.

You will also want to change the $proxy setting in site.pp to reflect your local proxy.

Another possible change is if you don't have "public" Internet accessible IPs for all of your machines (build, control, compute, etc.) and are building this in a controlled environment. If this is the case, ensure that $default_gateway is *not* set in site.pp and all of the files required for installing the control and compute nodes will be fetched from the boot server.

IMPORTANT: If you have proxies, and you set your proxy information in either your .profile or in a file like /etc/environment, you will need to set both http_proxy and https_proxy. You will also need to set a no_proxy command at least for the build node. An example might look like:

You have two choices for setting up the build server. You can follow the manual steps below, or you can run a one line script that tries to automate this process. In either case, you should end up with the puppet modules installed, and a set of template site manifests in /etc/puppet/manifests.

Model 1: Run the Script

To run the install script, copy and paste the following on your command line (as root with your proxy set if necessary as above):

Get the Cisco Edition example manifests. Under the folsom-manifests GitHub repository you will find different branches, so select the one that matches your topology plans most closely. In the following examples the multi-node branch will be used, which is likely the most common topology:

Customizing the Build Server

At a high level, cobbler-node.pp manages the deployment of cobbler to support booting of additional servers into your environment. The core.pp manifest defines the core definitions for openstack service deployment. The site.pp.example manifest captures the user modifiable components and defines the various parameters that must be set to configure the OpenStack cluster, including the puppetmaster and cobbler setup on the build server. clean_node.sh is a shell script provided as a convenience to deployment users; it wraps several cobbler and puppet commands for ease of use when building and rebuilding the nodes of the OpenStack cluster. reset_nodes.sh is a wrapper around clean_node.sh to rebuild your entire cluster quickly with one command.

IMPORTANT! You must copy site.pp.example to site.pp and then edit it as appropriate for your installation. It is internally documented.

When the puppet apply command runs, the puppet client on the build server will follow the instructions in the site.pp and cobbler-node.pp manifests and will configure several programs on the build server:

ntpd -- a time synchronization server used on all OpenStack cluster nodes to ensure time throughout the cluster is correct

tftpd-hpa -- a TFTP server used as part of the PXE boot process when OpenStack nodes boot up

dnsmasq -- a DNS and DHCP server used as part of the PXE boot process when OpenStack nodes boot up

cobbler -- an installation and boot management daemon which manages the installation and booting of OpenStack nodes

apt-cacher-ng -- a caching proxy for package installations, used to speed up package installation on the OpenStack nodes

nagios -- a infrastructure monitoring application, used to monitor the servers and processes of the OpenStack cluster

collectd --a statistics collection application, used to gather performance and other metrics from the components of the OpenStack cluster

graphite and carbon -- a real-time graphing system for parsing and displaying metrics and statistics about OpenStack

Configures Cobbler to PXE boot the specified node with appropriate PXE options to do an automated install of Ubuntu

Uses Cobbler to power-cycle the node

Removes any existing client registrations for the node from Puppet, so Puppet will treat it as a new install

Removes any existing key entries for the node from the SSH known hosts database

You can watch the progress on the console of your controller node as cobbler completes the automated install of Ubuntu. Once the installation finishes, the controller node will reboot and then will run puppet after it boots up. Puppet will pull and apply the controller node configuration defined in the puppet manifests on the build server.

This step will take several minutes, as puppet downloads, installs, and configures the various OpenStack components and support applications needed on the control node. /var/log/syslog on the controller node will display the progress of the puppet configuration run.

NOTE: It may take more than one puppet run for the controller node to be set up completely, especially if there are proxies in the path as some proxies can have issues with apt-get installs and updates. Observe the log files (/var/log/syslog on the controller node) to verify that the controller configuration has converged completely to the configuration defined in puppet.

Once the puppet configuration of the controller has completed, follow the same steps to build each of the other nodes in the cluster, using clean_node.sh to initiate each install. As with the controller, the other nodes will take several minutes for puppet configuration to complete, and may require multiple runs of puppet before they are fully converged to their defined configuration state.

As a short cut, if you want to build all of the nodes defined in your cobbler-node.pp file, you can run:

for n in `cobbler system list`; do clean_node.sh $n ; done

Or you can run a full reset script which also does this, and re-runs the build-node puppet apply and puppet plugin download steps:

./reset_nodes.sh

Once the OpenStack nodes have been built using cobbler, run puppet on the build node a second time:

puppet agent -t

This second puppet run will gather information about the individual OpenStack nodes collected by puppet when they were being built, and use that information to set up status monitoring of the OpenStack cluster on the build server.

Testing OpenStack

Once the nodes are built, and once puppet runs have completed on all nodes (watch /var/log/syslog on the cobbler node), you should be able to log into the OpenStack Horizon interface:

You will still need to log into the console of the control node to load in an image using user: localadmin, password: ubuntu. If you SU to root, you will need to source the openrc auth file which is in the root’s home directory (run "source openrc" in /root/), and you can launch a test file in /tmp/nova_test.sh.

Deploy Your First VM

The following deployment steps should be used after completing clean puppet runs on OpenStack Nodes and restarting quantum-server and quantum-plugin-openvswitch-agent services.

Manual Process

1. Create quantum public network.

quantum net-create public --router:external=True

2. We are using 192.168.221.0/24 as our external network. Note: The eth settings on the Controller Node associated to this network should not have an IP address assigned to it as it will function in bridged mode.

quantum subnet-create public 192.168.221.0/24

NOTE: If there are upstream routers/L3 switches that use HSRP/GLBP/VRRP that use low-order IP addresses such as .2 and .3 then the default subnet address assignments used by Quantum for this subnet (such as floating IP addresses and the Qrouter interface [default is .3]) will directly conflict with these real IP addresses on the upstream first hop routers. You can alter these default address assignments for the Quantum subnet by using the the "--allocation-pool" range when creating the Quantum subnet. The example that follows will use the default upstream router address of .1 (in this example the upstream HSRP address would be 192.168.221.1) and the first addresses for floating-IPs will begin at .10:

3. Create the internal (data) network used for Tenants. Create additional networks and associated subnets as needed. In the example below, we are assigning specific DNS servers that will be used by the instances.

You must create a static route on your physical router/layer-3 switch to the subnet that you define for your Tenants (quantum subnet-create command). The next-hop for the static route is the quantum router public interface. Use the following command to find the public address of your Quantum router:

5a. Continuing with our example, here is the required static route that MUST be configured on the external physical router/layer-3 switch. If you used the before mentioned "--allocation-pool" flag then the first address in the pool will be used for the qrouter address. So, in that example the next-hop entry for the example below would be "192.168.221.10":

9. Verify connectivity to Instance from the node running Quantum L3 Agent (Controller Node). Since we are using namespaces, we run the commands from the context of the qrouter using the "ip netns exec qrouter" syntax. Below, we list the qrouter to get its router-id, we connect to the qrouter and get a list of its addresses, we ping the instance from the qrouter and then we SSH into the instance from the qrouter:

Using Scripts to Setup a Test Quantum Network and Launch Instances

A "quick" way to get a similar environment to the one listed above running is to use the scripted quantum tests.

Clone the test repository:

git clone https://github.com/CiscoSystems/quantum-l3-test

Then follow the instructions in the README.md or follow these steps:

AssumptionsThere are a few assumptions being made in this script:

The script creates keys and places them in the /root/.ssh/ path therefore we are assuming you are running this script as root. If you are not running as 'root' then you need to change the path in the 'create_vm' file for the ssh-keygen line.

If you have existing files in the /root/.ssh/ path then the script will see them and prompt you to overwrite. If you do not select to overwrite the existing keys then you may encounter a "permissions denied" error when SSH'ing into the test instance. If this happens then ensure that the key being referenced during the nova keypair-add step in the 'create_vm' script is correct.

Instructions1. cd into the quantum-l3-test directory you just cloned:

cd quantum-l3-test

2) Run: ./create_vm this will run net_setup on its own

./create_vm

3) You will be prompted to enter your specific network values for the public/private networks as well as altering the default path where the Ubuntu Precise image is downloaded from (i.e. your own local mirror).

4) You should be able to log into the instance:

ssh ubuntu@{fixed or floating ip of instance}

To reset the Quantum settings created by the script and relaunch the test VM from scratch:

./reset
./create_vm

Congratulations

Congratulations! You have now completed a basic setup and should have a functional environment.

Next Steps

System and service health monitoring of your OpenStack cluster is set up as part of the puppet deployment process. Once you have created your first VM, you should start seeing OpenStack status information show up in the health monitoring. To view Nagios health monitoring, log into the web page at: