** Changed in: ceilometer
       Status: Fix Committed => Fix Released

** Changed in: ceilometer
    Milestone: None => havana-rc1

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

Title:
  Wrong instance_type_id field

Status in Ceilometer:
  Fix Released
Status in OpenStack Compute (Nova):
  Fix Committed

Bug description:
  Reproduce the bug:

  ** Config

  $ nova image-list
  
+--------------------------------------+---------------------------------+--------+--------+
  | ID                                   | Name                            | 
Status | Server |
  
+--------------------------------------+---------------------------------+--------+--------+
  | c91a4dcc-09f3-47c3-8532-8fa93014267c | cirros-0.3.1-x86_64-uec         | 
ACTIVE |        |
  | 65089976-7382-4177-932f-b32503c86c78 | cirros-0.3.1-x86_64-uec-kernel  | 
ACTIVE |        |
  | 81ffc23d-9efd-4f32-ac62-dfef9b969241 | cirros-0.3.1-x86_64-uec-ramdisk | 
ACTIVE |        |
  
+--------------------------------------+---------------------------------+--------+--------+

  $ 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      |
  | 2  | m1.small  | 2048      | 20   | 0         |      | 1     | 1.0         
| True      |
  | 3  | m1.medium | 4096      | 40   | 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      |
  | 84 | m1.micro  | 128       | 0    | 0         |      | 1     | 1.0         
| True      |
  
+----+-----------+-----------+------+-----------+------+-------+-------------+-----------+

  ** Now boot a VM with flavor 42 (m1.nano):

  $ nova boot server1 --image "c91a4dcc-09f3-47c3-8532-8fa93014267c" --flavor 42
  $ nova show server1
  
+--------------------------------------+----------------------------------------------------------------+
  | Property                             | Value                                
                          |
  
+--------------------------------------+----------------------------------------------------------------+
  | status                               | ACTIVE                               
                          |
  | updated                              | 2013-08-27T15:16:10Z                 
                          |
  | OS-EXT-STS:task_state                | None                                 
                          |
  | OS-EXT-SRV-ATTR:host                 | controller                           
                          |
  | key_name                             | None                                 
                          |
  | image                                | cirros-0.3.1-x86_64-uec 
(c91a4dcc-09f3-47c3-8532-8fa93014267c) |
  | private network                      | 10.0.0.2                             
                          |
  | hostId                               | 
ca0d3c4ec83e031c6117a85e15db2977136d5541494f542f35b49c5a       |
  | OS-EXT-STS:vm_state                  | active                               
                          |
  | OS-EXT-SRV-ATTR:instance_name        | instance-00000003                    
                          |
  | OS-SRV-USG:launched_at               | 2013-08-27T15:16:10.000000           
                          |
  | OS-EXT-SRV-ATTR:hypervisor_hostname  | controller                           
                          |
  | flavor                               | m1.nano (42)                         
                          |
  | id                                   | 8c20e949-d340-48cc-81cb-a35d1dbef315 
                          |
  | security_groups                      | [{u'name': u'default'}]              
                          |
  | OS-SRV-USG:terminated_at             | None                                 
                          |
  | user_id                              | 65604ab0988447738de47bb4f8ff734b     
                          |
  | name                                 | server1                              
                          |
  | created                              | 2013-08-27T15:15:49Z                 
                          |
  | tenant_id                            | 0a9a398a230b445a8968682c72f01d72     
                          |
  | OS-DCF:diskConfig                    | MANUAL                               
                          |
  | metadata                             | {}                                   
                          |
  | os-extended-volumes:volumes_attached | []                                   
                          |
  | accessIPv4                           |                                      
                          |
  | accessIPv6                           |                                      
                          |
  | progress                             | 0                                    
                          |
  | OS-EXT-STS:power_state               | 1                                    
                          |
  | OS-EXT-AZ:availability_zone          | nova                                 
                          |
  | config_drive                         |                                      
                          |
  
+--------------------------------------+----------------------------------------------------------------+

  ** We can see the corresponding flavor:

  | flavor                               | m1.nano (42)

  ** Now get the VM details through Ceilometer:

  $ curl -H 'X-Auth-Token:b497065bfc2c429b9da5e0988367e832' 
"http://localhost:8777/v2/resources/8c20e949-d340-48cc-81cb-a35d1dbef315";  | 
python -mjson.tool
    % Total    % Received % Xferd  Average Speed   Time    Time     Time  
Current
                                   Dload  Upload   Total   Spent    Left  Speed
  100  2439  100  2439    0     0  14554      0 --:--:-- --:--:-- --:--:-- 15634
  {
      "links": [
          {
              "href": 
"http://localhost:8777/v2/resources/8c20e949-d340-48cc-81cb-a35d1dbef315";,
              "rel": "self"
          },
          {
              "href": 
"http://localhost:8777/v2/meters/disk.ephemeral.size?q.field=resource_id&q.value=8c20e949-d340-48cc-81cb-a35d1dbef315";,
              "rel": "disk.ephemeral.size"
          },
          {
              "href": 
"http://localhost:8777/v2/meters/disk.root.size?q.field=resource_id&q.value=8c20e949-d340-48cc-81cb-a35d1dbef315";,
              "rel": "disk.root.size"
          },
          {
              "href": 
"http://localhost:8777/v2/meters/instance:m1.nano?q.field=resource_id&q.value=8c20e949-d340-48cc-81cb-a35d1dbef315";,
              "rel": "instance:m1.nano"
          },
          {
              "href": 
"http://localhost:8777/v2/meters/instance?q.field=resource_id&q.value=8c20e949-d340-48cc-81cb-a35d1dbef315";,
              "rel": "instance"
          },
          {
              "href": 
"http://localhost:8777/v2/meters/vcpus?q.field=resource_id&q.value=8c20e949-d340-48cc-81cb-a35d1dbef315";,
              "rel": "vcpus"
          },
          {
              "href": 
"http://localhost:8777/v2/meters/memory?q.field=resource_id&q.value=8c20e949-d340-48cc-81cb-a35d1dbef315";,
              "rel": "memory"
          }
      ],
      "metadata": {
          "access_ip_v4": "None",
          "access_ip_v6": "None",
          "architecture": "None",
          "audit_period_beginning": "2013-08-27T15:00:00.000000",
          "audit_period_ending": "2013-08-27T15:15:49.409989",
          "availability_zone": "None",
          "created_at": "2013-08-27 15:15:49.336002",
          "deleted_at": "",
          "disk_gb": "0",
          "display_name": "server1",
          "ephemeral_gb": "0",
          "event_type": "compute.instance.update",
          "host": "api.controller",
          "hostname": "server1",
          "image_meta.base_image_ref": "c91a4dcc-09f3-47c3-8532-8fa93014267c",
          "image_meta.kernel_id": "65089976-7382-4177-932f-b32503c86c78",
          "image_meta.ramdisk_id": "81ffc23d-9efd-4f32-ac62-dfef9b969241",
          "image_ref_url": 
"http://192.168.1.15:9292/images/c91a4dcc-09f3-47c3-8532-8fa93014267c";,
          "instance_id": "8c20e949-d340-48cc-81cb-a35d1dbef315",
          "instance_type": "m1.nano",
          "instance_type_id": "6",
          "kernel_id": "65089976-7382-4177-932f-b32503c86c78",
          "launched_at": "",
          "memory_mb": "64",
          "new_task_state": "scheduling",
          "node": "None",
          "old_state": "None",
          "old_task_state": "None",
          "os_type": "None",
          "ramdisk_id": "81ffc23d-9efd-4f32-ac62-dfef9b969241",
          "reservation_id": "r-rdoha2pl",
          "root_gb": "0",
          "state": "building",
          "state_description": "scheduling",
          "tenant_id": "0a9a398a230b445a8968682c72f01d72",
          "user_id": "65604ab0988447738de47bb4f8ff734b",
          "vcpus": "1"
      },
      "project_id": "0a9a398a230b445a8968682c72f01d72",
      "resource_id": "8c20e949-d340-48cc-81cb-a35d1dbef315",
      "user_id": "65604ab0988447738de47bb4f8ff734b"
  }

  ** We can see a wrong flavor id:

  "instance_type": "m1.nano",
  "instance_type_id": "6",

To manage notifications about this bug go to:
https://bugs.launchpad.net/ceilometer/+bug/1217429/+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