← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1435265] Re: nova flavor consider Lower case when create and but not in update

 

this should be related to mysql.
after some investigate.
the model of InstanceTypes has this constraint, but it's not case-sensitive, so it consider test1-0 and TEST1-0 same thing.

        schema.UniqueConstraint("name", "deleted",
                                name="uniq_instance_types0name0deleted")


** Project changed: nova => oslo.db

** Changed in: oslo.db
     Assignee: Eli Qiao (taget-9) => (unassigned)

-- 
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/1435265

Title:
  nova flavor consider Lower case when create and but not in update

Status in Oslo Database library:
  Confirmed

Bug description:

  taget@taget-ThinkStation-P300:~/devstack$ nova flavor-create Test1 100
  ^C11 1 1


  when create/delete a flavor, nova considers the name as lower case letter.
  but it doesn't for update

  for example:

  1. I have a flavor named TEST1

  taget@taget-ThinkStation-P300:~/devstack$ nova flavor-list
  +--------------------------------------+-------------------+-----------+------+-----------+------+-------+-------------+-----------+
  | ID                                   | Name              | Memory_MB | Disk | Ephemeral | Swap | VCPUs | RXTX_Factor | Is_Public |
  +--------------------------------------+-------------------+-----------+------+-----------+------+-------+-------------+-----------+
  | 1                                    | m1.tiny           | 512       | 1    | 0         |      | 1     | 1.0         | True      |
  | 101                                  | TEST1             | 511       | 1    | 0         |      | 1     | 1.0         | True      |
  | 2                                    | m1.small          | 2048      | 20   | 0         |      | 1     | 1.0         | True      |
  | 3                                    | m1.medium         | 4096      | 40   | 0         |      | 2     | 1.0         | True      |
  | 31eb8c58-2b0a-4892-80d6-ee36d4e64871 | test              | 512       | 3    | 0         |      | 2     | 1.0         | True      |
  | 4                                    | m1.large          | 8192      | 80   | 0         |      | 4     | 1.0         | True      |
  | 42                                   | m1.nano           | 64        | 0    | 0         |      | 1     | 1.0         | True      |
  | 5                                    | m1.xlarge         | 16384     | 160  | 0         |      | 8     | 1.0         | True      |
  | 78cd18c8-aa73-4cfc-8b01-9fbdad87b61b | controller-flavor | 4096      | 20   | 5         | 1    | 4     | 1.0         | True      |
  | 84                                   | m1.micro          | 128       | 0    | 0         |      | 1     | 1.0         | True      |
  +--------------------------------------+-------------------+-----------+------+-----------+------+-------+-------------+-----------+

  2. I can not create a flavor named Test1, nova consider they are same.
  taget@taget-ThinkStation-P300:~/devstack$ nova flavor-create Test1 100  511 1 1
  ERROR (Conflict): Flavor with name Test1 already exists. (HTTP 409) (Request-ID: req-9d3a652b-84c8-4580-96f2-c684a95be5f9)

  3. but When I try to update it by Test1, failed, nova considers it not
  exists.

  taget@taget-ThinkStation-P300:~/devstack$ nova flavor-key Test1 set ram 510
  ERROR (CommandError): No flavor with a name or ID of 'Test1' exists.

To manage notifications about this bug go to:
https://bugs.launchpad.net/oslo.db/+bug/1435265/+subscriptions


References