yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #73874
[Bug 1782539] [NEW] Fail to filter the list of instances by the available zone
Public bug reported:
After the host is in the Host Aggregates (HA) where the host is modified, the Availability Zone (az) is also changed, but the available_zone in the instances database of the instance on the host does not change.
The recurring steps are as follows:
1. Query the az of the instance by nova-api:
[root@node01 ~]# nova show 82d28856-a4ec-4ddb-96e1-0298c864c024 |grep -E 'availability_zone|hypervisor_hostname'
| OS-EXT-AZ:availability_zone | nova |
| OS-EXT-SRV-ATTR:hypervisor_hostname | node01 |
2. In the database use sql to query the current instance of az:
MariaDB [nova_cell1]> SELECT display_name, vm_state, availability_zone FROM instances WHERE uuid='82d28856-a4ec-4ddb-96e1-0298c864c024';
+--------------+----------+-------------------+
| display_name | vm_state | availability_zone |
+--------------+----------+-------------------+
| vm1 | active | nova |
+--------------+----------+-------------------+
3. Create HA (name is ha1), set AZ (name is az1), add host node01 to HA ha1:
[root@node01 ~]# nova aggregate-show ha1
+----+----------------+-------------------+----------+-------------------------+--------------------------------------+
| Id | Name | Availability Zone | Hosts | Metadata | UUID |
+----+----------------+-------------------+----------+-------------------------+--------------------------------------+
| 5 | ha1 | az1 | 'node01' | 'availability_zone=az1' | e0e98cc0-48cc-4b7f-a49e-fc992892f1c9 |
+----+----------------+-------------------+----------+-------------------------+--------------------------------------+
4.Query the az of the instance by nova-api:
[root@node01 ~]# nova show 82d28856-a4ec-4ddb-96e1-0298c864c024 |grep -E 'availability_zone|hypervisor_hostname'
| OS-EXT-AZ:availability_zone | az1 |
| OS-EXT-SRV-ATTR:hypervisor_hostname | node01 |
5.In the database use sql to query the current instance of az:
MariaDB [nova_cell1]> SELECT display_name, vm_state, availability_zone FROM instances WHERE uuid='82d28856-a4ec-4ddb-96e1-0298c864c024';
+--------------+----------+-------------------+
| display_name | vm_state | availability_zone |
+--------------+----------+-------------------+
| vm1 | active | nova |
+--------------+----------+-------------------+
Summary:By comparing steps 1, 4 and 2, 5, it is found that the data
obtained by vm1 through nova-api is inconsistent with the data in the
instances database table, and the availability_zone=az1 gets by nova-
api, but the availability_zone=nova in instances data table with vm1.
In addition, you can reproduce the problem through horizon.
** Affects: nova
Importance: Undecided
Assignee: sunjiazz (sunjiazz)
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/1782539
Title:
Fail to filter the list of instances by the available zone
Status in OpenStack Compute (nova):
New
Bug description:
After the host is in the Host Aggregates (HA) where the host is modified, the Availability Zone (az) is also changed, but the available_zone in the instances database of the instance on the host does not change.
The recurring steps are as follows:
1. Query the az of the instance by nova-api:
[root@node01 ~]# nova show 82d28856-a4ec-4ddb-96e1-0298c864c024 |grep -E 'availability_zone|hypervisor_hostname'
| OS-EXT-AZ:availability_zone | nova |
| OS-EXT-SRV-ATTR:hypervisor_hostname | node01 |
2. In the database use sql to query the current instance of az:
MariaDB [nova_cell1]> SELECT display_name, vm_state, availability_zone FROM instances WHERE uuid='82d28856-a4ec-4ddb-96e1-0298c864c024';
+--------------+----------+-------------------+
| display_name | vm_state | availability_zone |
+--------------+----------+-------------------+
| vm1 | active | nova |
+--------------+----------+-------------------+
3. Create HA (name is ha1), set AZ (name is az1), add host node01 to HA ha1:
[root@node01 ~]# nova aggregate-show ha1
+----+----------------+-------------------+----------+-------------------------+--------------------------------------+
| Id | Name | Availability Zone | Hosts | Metadata | UUID |
+----+----------------+-------------------+----------+-------------------------+--------------------------------------+
| 5 | ha1 | az1 | 'node01' | 'availability_zone=az1' | e0e98cc0-48cc-4b7f-a49e-fc992892f1c9 |
+----+----------------+-------------------+----------+-------------------------+--------------------------------------+
4.Query the az of the instance by nova-api:
[root@node01 ~]# nova show 82d28856-a4ec-4ddb-96e1-0298c864c024 |grep -E 'availability_zone|hypervisor_hostname'
| OS-EXT-AZ:availability_zone | az1 |
| OS-EXT-SRV-ATTR:hypervisor_hostname | node01 |
5.In the database use sql to query the current instance of az:
MariaDB [nova_cell1]> SELECT display_name, vm_state, availability_zone FROM instances WHERE uuid='82d28856-a4ec-4ddb-96e1-0298c864c024';
+--------------+----------+-------------------+
| display_name | vm_state | availability_zone |
+--------------+----------+-------------------+
| vm1 | active | nova |
+--------------+----------+-------------------+
Summary:By comparing steps 1, 4 and 2, 5, it is found that the data
obtained by vm1 through nova-api is inconsistent with the data in the
instances database table, and the availability_zone=az1 gets by nova-
api, but the availability_zone=nova in instances data table with vm1.
In addition, you can reproduce the problem through horizon.
To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1782539/+subscriptions