Benchmarking OpenStack With Rally

When you are trying to make changes in a code, there is a big chance of failure. And if the system is as huge as OpenStack, it becomes really hard to figure the error out. Here comes Rally. Rally makes benchmarking of OpenStack simple and automated. Rally works in three steps:

1. Deployment: Rally is not a deployment tool by itself, instead it works as a plugin with devstack, RDO etc.

2. Verification: Here Rally uses tempest to verify the OpenStack cloud deployment.

3. Benchmarking: This step is used to calculate load and performance of the particular cloud deployment.

Openstack with Rally

Openstack with Rally

Rally generally works a command line tool (GUI is work in progress) and helps in detecting scaling and performance issues, figuring out how the code change affects the system and finding out suitable architecture of deployment etc.

The first step is to install rally in OpenStack environment. I am going to use rally as a plugin with devstack, though it is possible to install it manually in an already deployed environment. To start, clone the following repositories from github:

Now, execute the following commands from your terminal in order to set devstack up with rally:

Next, as usual, we run the installation script of devstack:

Go for a coffee or take a walk, until devstack completes its work!

After the installation is done, source the openrc file present in ~/.rally/ directory to start using OpenStack.

To use rally, we first need to tell it about the OpenStack deployment which is going to be benchmarked. To do that, we have a deployment configuration file. That means, you need to provide configuration details of your OpenStack deployment in form of a json file. Go to the rally directory and create a my-deployment.json file. The content of the file should be like this:

Screenshot from 2014-02-27 17:20:18.png

You can find the relevant information for you system in openrc file. Next, we create a deployment named test using the following command:

Screenshot from 2014-02-27 17:19:54.png

Run ‘rally deployment check’ to check if current deployment is ready to be benchmarked. You should get an output like this:

Screenshot from 2014-02-27 17:21:26.png

Next, we come to benchmarking. There are a lot of ways to test the deployment, we will use an example that comes with rally. This is a boot and delete test. First copy the test to you current directory:

Now, edit the my-task.json file to look like:

Screenshot from 2014-02-27 17:25:25.png

 

Edit the falvor_id and image_id according to your system. Use “glance image-list” and “nova flavor-list” commands. And now we are ready to run our first task. Type this on your machine:

You should see the output:

Screenshot from 2014-02-27 17:29:29.png

You can also find out the detailed report about all the task.

Screenshot from 2014-02-27 17:30:25.png

There are other examples available in the doc/samples/ directory. You can learn more about test cases from these files. Happy benchmarking!

 

Leave a Reply

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