Public bug reported:

For now the nova quota-update will not give any constraints for the
values provided(user_id, tenant_id) when updates.

Actually if user 'nova quota-update service --ram=90000' and it will get
successfully. But it could give user some confusion that  quota-show
--tenant <tenant-name> is different with quota-show --tenant <tenant-
uuid>.

It is suggested that checks can be added to only allow the uuid-hex
format tenant-id or user-id to get quota updated.

[root@openstack-zz ~]# keystone tenant-list|grep -i service
| 6194feba2f7d4ba38871cbae316c0dc5 |       
ServicesAdminNegativeV3Test-1222585335      |   True  |
| 342e8af8e9e14d5cb432c2b4caea31a2 |        
ServicesAdminNegativeV3Test-26338885       |   True  |
| 9abbd7d89f724425878dfedca3e62d73 |       
ServicesAdminNegativeV3Test-828904988       |   True  |
| 9648314c9e72430586297ec98d92ef8e |           ServicesAdminV3Test-1556513182   
       |   True  |
| 134ba2bec4e8412688868d879cb05399 |           ServicesAdminV3Test-1805549103   
       |   True  |
| ca5f77e01d4f45739e67abfbfd478ec9 |           ServicesAdminV3Test-567239400    
       |   True  |
| 02bbd8a72c7a4615866077132011c963 |                      service               
       |   True  |
[root@openstack-zz ~]# nova quota-update service --ram 94000
[root@openstack-zz ~]# nova quota-show --tenant service
+-----------------------------+-------+
| Quota                       | Limit |
+-----------------------------+-------+
| instances                   | 10    |
| cores                       | 20    |
| ram                         | 94000 |
| floating_ips                | 10    |
| fixed_ips                   | -1    |
| metadata_items              | 128   |
| injected_files              | 5     |
| injected_file_content_bytes | 10240 |
| injected_file_path_bytes    | 255   |
| key_pairs                   | 100   |
| security_groups             | 10    |
| security_group_rules        | 20    |
+-----------------------------+-------+
[root@openstack-zz ~]# nova quota-show --tenant 02bbd8a72c7a4615866077132011c963
+-----------------------------+--------+
| Quota                       | Limit  |
+-----------------------------+--------+
| instances                   | 10     |
| cores                       | 20     |
| ram                         | 100000 |
| floating_ips                | 10     |
| fixed_ips                   | -1     |
| metadata_items              | 128    |
| injected_files              | 5      |
| injected_file_content_bytes | 10240  |
| injected_file_path_bytes    | 255    |
| key_pairs                   | 100    |
| security_groups             | 10     |
| security_group_rules        | 20     |
+-----------------------------+--------+

** 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/1333571

Title:
  Quota update should add check to avoid update projects tenant_id or
  user_id

Status in OpenStack Compute (Nova):
  New

Bug description:
  For now the nova quota-update will not give any constraints for the
  values provided(user_id, tenant_id) when updates.

  Actually if user 'nova quota-update service --ram=90000' and it will
  get successfully. But it could give user some confusion that  quota-
  show --tenant <tenant-name> is different with quota-show --tenant
  <tenant-uuid>.

  It is suggested that checks can be added to only allow the uuid-hex
  format tenant-id or user-id to get quota updated.

  [root@openstack-zz ~]# keystone tenant-list|grep -i service
  | 6194feba2f7d4ba38871cbae316c0dc5 |       
ServicesAdminNegativeV3Test-1222585335      |   True  |
  | 342e8af8e9e14d5cb432c2b4caea31a2 |        
ServicesAdminNegativeV3Test-26338885       |   True  |
  | 9abbd7d89f724425878dfedca3e62d73 |       
ServicesAdminNegativeV3Test-828904988       |   True  |
  | 9648314c9e72430586297ec98d92ef8e |           ServicesAdminV3Test-1556513182 
         |   True  |
  | 134ba2bec4e8412688868d879cb05399 |           ServicesAdminV3Test-1805549103 
         |   True  |
  | ca5f77e01d4f45739e67abfbfd478ec9 |           ServicesAdminV3Test-567239400  
         |   True  |
  | 02bbd8a72c7a4615866077132011c963 |                      service             
         |   True  |
  [root@openstack-zz ~]# nova quota-update service --ram 94000
  [root@openstack-zz ~]# nova quota-show --tenant service
  +-----------------------------+-------+
  | Quota                       | Limit |
  +-----------------------------+-------+
  | instances                   | 10    |
  | cores                       | 20    |
  | ram                         | 94000 |
  | floating_ips                | 10    |
  | fixed_ips                   | -1    |
  | metadata_items              | 128   |
  | injected_files              | 5     |
  | injected_file_content_bytes | 10240 |
  | injected_file_path_bytes    | 255   |
  | key_pairs                   | 100   |
  | security_groups             | 10    |
  | security_group_rules        | 20    |
  +-----------------------------+-------+
  [root@openstack-zz ~]# nova quota-show --tenant 
02bbd8a72c7a4615866077132011c963
  +-----------------------------+--------+
  | Quota                       | Limit  |
  +-----------------------------+--------+
  | instances                   | 10     |
  | cores                       | 20     |
  | ram                         | 100000 |
  | floating_ips                | 10     |
  | fixed_ips                   | -1     |
  | metadata_items              | 128    |
  | injected_files              | 5      |
  | injected_file_content_bytes | 10240  |
  | injected_file_path_bytes    | 255    |
  | key_pairs                   | 100    |
  | security_groups             | 10     |
  | security_group_rules        | 20     |
  +-----------------------------+--------+

To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1333571/+subscriptions

-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to     : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp

Reply via email to