[Openstack][nova] server groups

Ignazio Cassano ignaziocassano at gmail.com
Fri Apr 8 07:56:55 UTC 2022


Hello,
int
 he nova_api dn table request specs, the following is spec value for an
instance in server groups:
{"nova_object.version": "1.8", "nova_object.changes":
["requested_destination", "instance_uuid", "retry", "num_instances",
"pci_requests", "limits", "availability_zone", "force_nodes", "image",
"instance_group", "force_hosts", "numa_topology", "ignore_hosts", "flavor",
"project_id", "security_groups", "scheduler_hints"], "nova_object.name":
"RequestSpec", "nova_object.data": {"requested_destination": null,
"instance_uuid": "0cc6b190-73c7-4f97-8ec9-86c58ffadf2d", "retry": null,
"num_instances": 2, "pci_requests": {"nova_object.version": "1.1",
"nova_object.changes": ["requests"], "nova_object.name":
"InstancePCIRequests", "nova_object.data": {"requests": []},
"nova_object.namespace": "nova"}, "limits": {"nova_object.version": "1.0",
"nova_object.changes": ["vcpu", "memory_mb", "disk_gb", "numa_topology"], "
nova_object.name": "SchedulerLimits", "nova_object.data": {"vcpu": null,
"memory_mb": null, "disk_gb": null, "numa_topology": null},
"nova_object.namespace": "nova"}, "availability_zone": "nova",
"force_nodes": null, "image": {"nova_object.version": "1.8",
"nova_object.changes": ["status", "name", "container_format", "created_at",
"disk_format", "updated_at", "id", "min_disk", "min_ram", "checksum",
"owner", "properties", "size"], "nova_object.name": "ImageMeta",
"nova_object.data": {"status": "active", "created_at":
"2021-10-05T13:53:07Z", "name": "centos7-05102021", "container_format":
"bare", "min_ram": 0, "disk_format": "qcow2", "updated_at":
"2021-10-05T13:53:25Z", "id": "a04131be-7b16-4a0b-bc38-b77428259ec8",
"min_disk": 0, "checksum": "db51c6c23e77ac4cde8617070e640e1d", "owner":
"0e760ccde5d24af5a571de40220fbf80", "properties": {"nova_object.version":
"1.19", "nova_object.changes": ["hw_qemu_guest_agent", "os_type",
"os_require_quiesce", "hw_disk_bus"], "nova_object.name": "ImageMetaProps",
"nova_object.data": {"hw_qemu_guest_agent": true, "os_type": "linux",
"hw_disk_bus": "virtio", "os_require_quiesce": true},
"nova_object.namespace": "nova"}, "size": 4033413120},
"nova_object.namespace": "nova"}, "instance_group": {"nova_object.version":
"1.10", "nova_object.changes": ["hosts", "members"], "nova_object.name":
"InstanceGroup", "nova_object.data": {"policies": ["soft-anti-affinity"],
"project_id": "0e760ccde5d24af5a571de40220fbf80", "user_id":
"5134ed3b93284af5ba2f05d7361edf53", "uuid":
"2938ef43-9fbc-4f04-aa3b-72144e343558", "deleted": false, "created_at":
"2022-03-31T08:52:19Z", "updated_at": null, "hosts": null, "members": null,
"deleted_at": null, "id": 67, "name": "topolino"}, "nova_object.namespace":
"nova"}, "force_hosts": null, "numa_topology": null, "ignore_hosts": null,
"flavor": {"nova_object.version": "1.2", "nova_object.name": "Flavor",
"nova_object.data": {"disabled": false, "root_gb": 40, "description": null,
"flavorid": "3", "deleted": false, "created_at": "2017-12-20T15:58:13Z",
"ephemeral_gb": 0, "updated_at": null, "memory_mb": 4096, "vcpus": 2,
"extra_specs": {}, "swap": 0, "rxtx_factor": 1.0, "is_public": true,
"deleted_at": null, "vcpu_weight": 0, "name": "m1.medium"},
"nova_object.namespace": "nova"}, "project_id":
"0e760ccde5d24af5a571de40220fbf80", "security_groups":
{"nova_object.version": "1.1", "nova_object.changes": ["objects"], "
nova_object.name": "SecurityGroupList", "nova_object.data": {"objects":
[{"nova_object.version": "1.2", "nova_object.changes": ["uuid"], "
nova_object.name": "SecurityGroup", "nova_object.data": {"uuid":
"4d2fdd79-0f6c-4c26-a87b-a76b5d12901e"}, "nova_object.namespace":
"nova"}]}, "nova_object.namespace": "nova"}, "scheduler_hints": {"group":
["2938ef43-9fbc-4f04-aa3b-72144e343558"]}}, "nova_object.namespace": "nova"}

The following is the spec value of an instance not in server group:
{"nova_object.version": "1.8", "nova_object.changes":
["requested_destination", "instance_uuid", "retry", "num_instances",
"pci_requests", "limits", "availability_zone", "force_nodes", "image",
"instance_group", "force_hosts", "numa_topology", "ignore_hosts", "flavor",
"project_id", "security_groups", "scheduler_hints"], "nova_object.name":
"RequestSpec", "nova_object.data": {"requested_destination": null,
"instance_uuid": "8c0c44c3-c00a-41ec-bf23-a427d99de2b3", "retry": null,
"num_instances": 1, "pci_requests": {"nova_object.version": "1.1",
"nova_object.changes": ["requests"], "nova_object.name":
"InstancePCIRequests", "nova_object.data": {"requests": []},
"nova_object.namespace": "nova"}, "limits": {"nova_object.version": "1.0",
"nova_object.changes": ["vcpu", "memory_mb", "disk_gb", "numa_topology"], "
nova_object.name": "SchedulerLimits", "nova_object.data": {"vcpu": null,
"memory_mb": null, "disk_gb": null, "numa_topology": null},
"nova_object.namespace": "nova"}, "availability_zone": "nova",
"force_nodes": null, "image": {"nova_object.version": "1.8",
"nova_object.changes": ["min_disk", "status", "min_ram", "properties",
"size"], "nova_object.name": "ImageMeta", "nova_object.data": {"status":
"active", "min_disk": 0, "min_ram": 0, "properties":
{"nova_object.version": "1.19", "nova_object.changes":
["hw_qemu_guest_agent", "os_type", "os_require_quiesce", "hw_disk_bus"], "
nova_object.name": "ImageMetaProps", "nova_object.data":
{"hw_qemu_guest_agent": true, "os_type": "linux", "hw_disk_bus": "virtio",
"os_require_quiesce": true}, "nova_object.namespace": "nova"}, "size":
42949672960}, "nova_object.namespace": "nova"}, "instance_group": null,
"force_hosts": null, "numa_topology": null, "ignore_hosts": null, "flavor":
{"nova_object.version": "1.2", "nova_object.name": "Flavor",
"nova_object.data": {"disabled": false, "root_gb": 40, "description": null,
"flavorid": "3", "deleted": false, "created_at": "2017-12-20T15:58:13Z",
"ephemeral_gb": 0, "updated_at": null, "memory_mb": 4096, "vcpus": 2,
"extra_specs": {}, "swap": 0, "rxtx_factor": 1.0, "is_public": true,
"deleted_at": null, "vcpu_weight": 0, "id": 12, "name": "m1.medium"},
"nova_object.namespace": "nova"}, "project_id":
"0e760ccde5d24af5a571de40220fbf80", "security_groups":
{"nova_object.version": "1.1", "nova_object.changes": ["objects"], "
nova_object.name": "SecurityGroupList", "nova_object.data": {"objects":
[{"nova_object.version": "1.2", "nova_object.changes": ["uuid"], "
nova_object.name": "SecurityGroup", "nova_object.data": {"uuid":
"4d2fdd79-0f6c-4c26-a87b-a76b5d12901e"}, "nova_object.namespace":
"nova"}]}, "nova_object.namespace": "nova"}, "scheduler_hints": {}},
"nova_object.namespace": "nova"}

As you can note some keys have not values in second case, for example
scheduler_hints.
Ignazio

Il giorno mer 6 apr 2022 alle ore 23:25 Laurent Dumont <
laurentfdumont at gmail.com> ha scritto:

> Nice!
>
> Can you detail the fields you changed? I had a look in the DB for the
> request_specs and it's a big old JSON blurb.
>
> What fields did you change?
>
> On Wed, Apr 6, 2022, 12:15 PM Ignazio Cassano <ignaziocassano at gmail.com>
> wrote:
>
>> We solved our issue: the spec field in request_specs table was wrong. Non
>> live migration works fine
>> Ignazio
>>
>>
>> Il Mer 6 Apr 2022, 09:05 Ignazio Cassano <ignaziocassano at gmail.com> ha
>> scritto:
>>
>>> We've 2 cases, those VMs are in the same group, one fails when migration
>>> is launched, the other working well, you can see output of nova live
>>> migration and spec on DB
>>>
>>> not working:
>>> https://paste.openstack.org/show/b4QfkVHkUpIC97E3aWAx/
>>> working:
>>> https://paste.openstack.org/show/busPt39bkfUzQthk1Tcf/
>>>
>>> Ignazio
>>>
>>> Il Mer 6 Apr 2022, 06:53 Laurent Dumont <laurentfdumont at gmail.com> ha
>>> scritto:
>>>
>>>> I cannot easily reproduce, but what does Nova complain about with the
>>>> live migration? Any chance you can run it with DEBUG?
>>>>
>>>> On Wed, Apr 6, 2022 at 12:34 AM Ignazio Cassano <
>>>> ignaziocassano at gmail.com> wrote:
>>>>
>>>>> Thanks Laurent. Sometimes the trick works and instances can migrate.
>>>>> We do not understand what is wrong when instances fail to migrate.
>>>>> We are usung soft-anti-affinity policy.
>>>>> The spec field we inserted in both cases seeems the same.
>>>>> Ignazio.
>>>>>
>>>>> Il Mer 6 Apr 2022, 01:03 Laurent Dumont <laurentfdumont at gmail.com> ha
>>>>> scritto:
>>>>>
>>>>>> I'm trying to find where else this was discussed, but afaik, this was
>>>>>> never supported.
>>>>>>
>>>>>> I am not sure if someone was able to "hack" it's way to a working
>>>>>> setup. It's a bit of a shame because it makes server-groups really not
>>>>>> flexible :(
>>>>>>
>>>>>> On Tue, Apr 5, 2022 at 3:04 PM Ignazio Cassano <
>>>>>> ignaziocassano at gmail.com> wrote:
>>>>>>
>>>>>>> Hello, we noted that instances can be inserted in server groups only
>>>>>>> at instance creation step but we need to insert in a server group some old
>>>>>>> instances.
>>>>>>>
>>>>>>> We tried to modify database nova_api server group tables but we
>>>>>>> noted that we must modify spec in  request_specs table . For us is not
>>>>>>> clear how to modify the spec value.
>>>>>>> We tried to investigate looking at instances inserted in a server
>>>>>>> group at creation step and we got issues in instance live migration.
>>>>>>> Please, anyone could provide any utility to do it or any template ?
>>>>>>> Thanks
>>>>>>> Ignazio
>>>>>>>
>>>>>>>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-discuss/attachments/20220408/05145c43/attachment.htm>


More information about the openstack-discuss mailing list