Known Issues

The volume created by server API with “source_type:blank” property in “block_device_mapping_v2” does not work properly

(:Last updated)

Issue

API for creating virtual server instance can create volumes-attached instance by using “block_device_mapping_v2” in request body. When the “source_type”: “blank” in “block_dvice_mapping_v2” is specified, the API creates a new volume for the instance.

The instance can use the volume until you stop the instance by API or GUI. Once you stop the instance, you can not see any volume from the instance.

Detail

This section show an example how to reproduce this issue. The JSON shown below contains “source_type:blank” in “block_device_mapping_v2”. At first, please call create server API with the JSON.

{

   “server”: {

       “availability_zone”: “zone1-groupa”,

       “block_device_mapping_v2”: [

           {

               “boot_index”: 0,

               “delete_on_termination”: true,

               “destination_type”: “volume”,

               “source_type”: “image”,

               “uuid”: “29266056-fd5b-4f73-8b4d-194785cbbc45”,

               “volume_size”: 100

           },

           {

               “boot_index”: 1,

               “delete_on_termination”: true,

               “destination_type”: “volume”,

               “source_type”: “blank”,

               “volume_size”: 100

           },

           {

               “boot_index”: 2,

               “delete_on_termination”: true,

               “destination_type”: “volume”,

               “source_type”: “blank”,

               “volume_size”: 15

           }

       ],

       “flavorRef”: “1CPU-4GB”,

       “imageRef”: “”,

       “name”: “test-instance”,

       “networks”: [

           {

               “fixed_ip”: “10.10.0.6”,

               “uuid”: “xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx”,

           }

       ],

       “user_data”: “”

   }

}

Please look the following screenshot showing two volumes, vdb(100G) and vdc(15G), are attached to the instance before the instance stops for the first time.

The following screenshot showing after the instance are stopped and started, the volumes, vdb(100G) and vdc(15G), are not visible in the instance.

And you are not able to attach/detach the volumes with Cloud Computing Control Panel(GUI) and API anymore because it becomes an inconsistent state.

Workaround

Please don’t create instance with “block_device_mapping_v2” including source_type: blank.

If you want to create a volumes-attached instance, create the volume in advance by virtual server volumes API or Cloud Computing Control Panel(GUI). After that, set “source_type: volume” and “uuid: <volume uuid>”.

The following JSON is one of example.

{

   “server”: {

       “availability_zone”: “zone1-groupa”,

       “block_device_mapping_v2”: [

           {

               “boot_index”: 0,

               “delete_on_termination”: true,

               “destination_type”: “volume”,

               “source_type”: “image”,

               “uuid”: “29266056-fd5b-4f73-8b4d-194785cbbc45”,

               “volume_size”: 100

           },

           {

               “boot_index”: 1,

               “delete_on_termination”: true,

               “destination_type”: “volume”,

               “source_type”: “volume”,

               “uuid”: “xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx”

           },

           {

               “boot_index”: 2,

               “delete_on_termination”: true,

               “destination_type”: “volume”,

               “source_type”: “volume”,

               “uuid”: “xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx”

           }

       ],

       “flavorRef”: “1CPU-4GB”,

       “imageRef”: “”,

       “name”: “test-instance”,

       “networks”: [

           {

               “fixed_ip”: “10.10.0.6”,

               “uuid”: “xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx”,

           }

       ],

       “user_data”: “”

   }

}