yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #85812
[Bug 1923899] [NEW] Nova create duplicate cells when templates are used
Public bug reported:
Description
===========
When you use templates for cell creation and re-run create_cell command,
duplicate cell will be created
This happens because logic is broken here for templates:
https://opendev.org/openstack/nova/src/commit/9e5feb051c15166988e87b10132927135bd56884/nova/cmd/manage.py#L623-L624
As cell.database_connection and cell.transport_url are already resolved
into urls, while transport_url and database_connection are still
templates.
Steps to reproduce
==================
Run 2 times: nova-manage cell_v2 create_cell --name cell1 --transport-
url {scheme}://{username}:{password}@{hostname}//{path}?{query}
--database_connection
{scheme}://{username}:{password}@{hostname}/{path}?{query} --verbose
This will result in creating 2 independent cells:
root@aio1:~# /openstack/venvs/nova-22.0.0.0rc2.dev149/bin/nova-manage cell_v2 create_cell --name cell1 --transport-url {scheme}://{username}:{password}@{hostname}//{path}?{query} --database_connection {scheme}://{username}:{password}@{hostname}/{path}?{query} --verbose
046c88f0-097e-4a7c-9eee-45654355ff56
root@aio1:~# /openstack/venvs/nova-22.0.0.0rc2.dev149/bin/nova-manage cell_v2 create_cell --name cell1 --transport-url {scheme}://{username}:{password}@{hostname}//{path}?{query} --database_connection {scheme}://{username}:{password}@{hostname}/{path}?{query} --verbose
b5f1672e-36c7-4d17-90b3-7433842cbbe0
root@aio1:~# /openstack/venvs/nova-22.0.0.0rc2.dev149/bin/nova-manage cell_v2 create_cell --name cell1 --transport-url {scheme}://{username}:{password}@{hostname}//{path}?{query} --database_connection {scheme}://{username}:{password}@{hostname}/{path}?{query} --verbose
cf2efc1c-e091-4c93-96d4-84b3ecfa4647
root@aio1:~#
Expected result
===============
Following error should be raised along with command exit code 2:
The specified transport_url and/or database_connection combination already exists for another cell with uuid
** Affects: nova
Importance: Undecided
Status: New
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1923899
Title:
Nova create duplicate cells when templates are used
Status in OpenStack Compute (nova):
New
Bug description:
Description
===========
When you use templates for cell creation and re-run create_cell
command, duplicate cell will be created
This happens because logic is broken here for templates:
https://opendev.org/openstack/nova/src/commit/9e5feb051c15166988e87b10132927135bd56884/nova/cmd/manage.py#L623-L624
As cell.database_connection and cell.transport_url are already
resolved into urls, while transport_url and database_connection are
still templates.
Steps to reproduce
==================
Run 2 times: nova-manage cell_v2 create_cell --name cell1
--transport-url
{scheme}://{username}:{password}@{hostname}//{path}?{query}
--database_connection
{scheme}://{username}:{password}@{hostname}/{path}?{query} --verbose
This will result in creating 2 independent cells:
root@aio1:~# /openstack/venvs/nova-22.0.0.0rc2.dev149/bin/nova-manage cell_v2 create_cell --name cell1 --transport-url {scheme}://{username}:{password}@{hostname}//{path}?{query} --database_connection {scheme}://{username}:{password}@{hostname}/{path}?{query} --verbose
046c88f0-097e-4a7c-9eee-45654355ff56
root@aio1:~# /openstack/venvs/nova-22.0.0.0rc2.dev149/bin/nova-manage cell_v2 create_cell --name cell1 --transport-url {scheme}://{username}:{password}@{hostname}//{path}?{query} --database_connection {scheme}://{username}:{password}@{hostname}/{path}?{query} --verbose
b5f1672e-36c7-4d17-90b3-7433842cbbe0
root@aio1:~# /openstack/venvs/nova-22.0.0.0rc2.dev149/bin/nova-manage cell_v2 create_cell --name cell1 --transport-url {scheme}://{username}:{password}@{hostname}//{path}?{query} --database_connection {scheme}://{username}:{password}@{hostname}/{path}?{query} --verbose
cf2efc1c-e091-4c93-96d4-84b3ecfa4647
root@aio1:~#
Expected result
===============
Following error should be raised along with command exit code 2:
The specified transport_url and/or database_connection combination already exists for another cell with uuid
To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1923899/+subscriptions