Custom nova instance name

Asked by Rajeev

Hi,

I'm using Rally to qualify/benchmark openstack cloud.

The test scenarios under nova configures the instances by appending some randomly generated name, which I need to avoid.

In order to achieve this, i have modifed _boot_server sub-routine in utils.py file to include a custom name to the nova instances. The changes are:

  From: server_name = self.generate_random_name()

  To: server_name = "nova_instance_7"
(I'm aware that hard-coding the name will affect the cleanup process, but i really want to configure an instance with user defined name rather than the ones provided by rally)

However when i execute a nova - "create and delete" or "create and attach volume" scenario, instances are being created with old name itself.

How can i make sure that the changes which i make to the rally opensource files gets reflected in the tests which i execute ?
Do i have to recompile the source code?

I even tried to configure the name by providing input from the json file for the test scenario, but with no luck.
under args, i have included:
"server": {
    "name": "test_instance_7",

Can some one please help me understand how i can configure nova instances with custom name.

Thanks,
Rajeev

Question information

Language:
English Edit question
Status:
Solved
For:
Rally Edit question
Assignee:
No assignee Edit question
Solved by:
Andrey Kurilin
Solved:
Last query:
Last reply:
Revision history for this message
Rajeev (rsomayaj) said :
#1

I have changed the RESOURCE_NAME_FORMAT to some value other than "s_rally_XXXX_XXXX" in scenarios.py. Still the new instance created is with old format (s_rally_XXX). Any help is appreciated.

Thanks,
Rajeev

Revision history for this message
Best Andrey Kurilin (andreykurilin) said :
#2

Let's close this question and discuss it in https://answers.launchpad.net/rally/+question/447837

Revision history for this message
Rajeev (rsomayaj) said :
#3

Thanks Andrey Kurilin, that solved my question.