Ask Your Question

prevent server group deletion when its being used ?

asked 2018-11-04 22:19:23 -0600


We're running Ocata i believe, and when i create multiple server groups and add members to it e.g.

| Field    | Value                                                                      |
| id       | d77e1b84-3874-49fc-ace9-2f1d2b9ffe6e                                       |
| members  | 36c1f857-7674-43ed-922d-ff26262d23a8, 6533d1a7-d95a-4608-b29d-a15237254685 |
| name     | affinity-server-group: redis                                               |
| policies | anti-affinity                                                              |

.. even thought its being used, I can delete the server group :(

I was expecting that the delete would error as it is occupied. Is this a bug that's fixed in newer versions ?

If the server groups members isn't empty, an error warning and having to use a --force option to delete would be better.


edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted

answered 2018-11-04 23:28:48 -0600

The following is my opinion and not an official statement by OpenStack or my employer (and I am self-employed anyway).

The purpose of server groups is scheduling. That is, they are only used when the Nova scheduler needs to find a host to run an instance. Which is at the time the instance is created (and when it is live-migrated, which I will ignore for now).

Thus, once an instance is up and running, its server group has no meaning anymore. The instance doesn't depend on the server group in any way.

Even when we also consider live-migration, there is no harm. If the user removes the server group, we can assume that s/he doesn't need schedule affinity or anti-affinity anymore, thus no harm is caused by the absence of the server group.

Contrast this with a network, for example. Instances that are connected to this network would be affected by its removal. For this reason, you can't remove a network before removing or reconnecting all instances (and routers).

edit flag offensive delete link more

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower


Asked: 2018-11-04 22:19:23 -0600

Seen: 239 times

Last updated: Nov 04 '18