Activity log for bug #1522232

Date Who What changed Old value New value Message
2015-12-03 02:54:15 Zhao Zhe bug added bug
2015-12-03 02:55:15 Zhao Zhe tags vmware
2015-12-03 03:29:42 Zhao Zhe bug task added cinder
2015-12-03 03:31:23 Zhao Zhe bug added subscriber Radoslav Gerganov
2015-12-03 05:27:00 Zhao Zhe bug added subscriber Gary Kotton
2015-12-03 05:28:34 Zhao Zhe bug added subscriber Alexander Bochkarev
2015-12-03 05:29:19 Zhao Zhe bug added subscriber Mark McLoughlin
2015-12-03 05:30:14 Zhao Zhe bug added subscriber Zhongyue Luo
2015-12-03 05:30:51 Zhao Zhe bug added subscriber Sean Chen
2015-12-03 05:31:52 Zhao Zhe bug added subscriber Sabari Murugesan
2015-12-03 05:34:13 Zhao Zhe description There can be at most 15 virtual disk attached on an SCSi controller, so if the limitation is reached, a new controller should be automatically created. In nova/virt/vmwareapi/vm_util.py: def allocate_controller_key_and_unit_number(client_factory, devices, adapter_type): """This function inspects the current set of hardware devices and returns controller_key and unit_number that can be used for attaching a new virtual disk to adapter with the given adapter_type. """ if devices.__class__.__name__ == "ArrayOfVirtualDevice": devices = devices.VirtualDevice taken = _find_allocated_slots(devices) ret = None if adapter_type == 'ide': ide_keys = [dev.key for dev in devices if _is_ide_controller(dev)] ret = _find_controller_slot(ide_keys, taken, 2) elif adapter_type in ['lsiLogic', 'lsiLogicsas', 'busLogic','paraVirtual']: scsi_keys = [dev.key for dev in devices if _is_scsi_controller(dev)] ret = _find_controller_slot(scsi_keys, taken, 16) if ret: return ret[0], ret[1], None # create new controller with the specified type and return its spec controller_key = -101 controller_spec = create_controller_spec(client_factory, controller_key, adapter_type) return controller_key, 0, controller_spec Here we can see, if 'ret' is None, a 'create_controller_spec' is generated for the creation of a new controller. I tested this function, and I check the value of 'vmdk_attach_config_spec.deviceChange' [(VirtualDeviceConfigSpec){ dynamicType = None dynamicProperty[] = <empty> operation = "add" fileOperation = "create" device = (VirtualDisk){ dynamicType = None dynamicProperty[] = <empty> key = -100 deviceInfo = (Description){ dynamicType = None dynamicProperty[] = <empty> label = None summary = None } backing = (VirtualDiskRawDiskMappingVer1BackingInfo){ dynamicType = None dynamicProperty[] = <empty> fileName = "" datastore = (ManagedObjectReference){ value = None _type = "" } backingObjectId = None lunUuid = None deviceName = "/vmfs/devices/disks/t10.IET_____001000010000000000000000000000000000000000000000" compatibilityMode = "physicalMode" diskMode = "independent_persistent" uuid = None contentId = None changeId = None parent = (VirtualDiskRawDiskMappingVer1BackingInfo){ dynamicType = None dynamicProperty[] = <empty> fileName = None datastore = (ManagedObjectReference){ value = None _type = "" } backingObjectId = None lunUuid = None deviceName = None compatibilityMode = None diskMode = None uuid = None contentId = None changeId = None } } connectable = (VirtualDeviceConnectInfo){ dynamicType = None dynamicProperty[] = <empty> startConnected = True allowGuestControl = False connected = True status = None } slotInfo = (VirtualDeviceBusSlotInfo){ dynamicType = None dynamicProperty[] = <empty> } controllerKey = -101 unitNumber = 0 capacityInKB = 0 capacityInBytes = None shares = (SharesInfo){ dynamicType = None dynamicProperty[] = <empty> shares = None level = (SharesLevel){ value = None } } storageIOAllocation = (StorageIOAllocationInfo){ dynamicType = None dynamicProperty[] = <empty> limit = None shares = (SharesInfo){ dynamicType = None dynamicProperty[] = <empty> shares = None level = (SharesLevel){ value = None } } reservation = None } diskObjectId = None vFlashCacheConfigInfo = (VirtualDiskVFlashCacheConfigInfo){ dynamicType = None dynamicProperty[] = <empty> vFlashModule = None reservationInMB = None cacheConsistencyType = None cacheMode = None blockSizeInKB = None } } profile[] = <empty> }, (VirtualDeviceConfigSpec){ dynamicType = None dynamicProperty[] = <empty> operation = "add" fileOperation = (VirtualDeviceConfigSpecFileOperation){ value = None } device = (ParaVirtualSCSIController){ dynamicType = None dynamicProperty[] = <empty> key = -101 deviceInfo = (Description){ dynamicType = None dynamicProperty[] = <empty> label = None summary = None } backing = (VirtualDeviceBackingInfo){ dynamicType = None dynamicProperty[] = <empty> } connectable = (VirtualDeviceConnectInfo){ dynamicType = None dynamicProperty[] = <empty> startConnected = None allowGuestControl = None connected = None status = None } slotInfo = (VirtualDeviceBusSlotInfo){ dynamicType = None dynamicProperty[] = <empty> } controllerKey = None unitNumber = None busNumber = 0 device[] = <empty> hotAddRemove = None sharedBus = "noSharing" scsiCtlrUnitNumber = None } profile[] = <empty> }] It really seems a request for creating a new controller, and then attach the virtual disk to it. But I met errors after this. In an icehouse environment, it is reported as "VMwareDriverException: Cannot modify existing SCSI device" In a kilo environment, it is reported as "VMwareDriverException: Number of virtual devices exceeds the maximum for a given controller." (their controller types are different, I don't know if this is the reason of the difference of the error messages) So, is this a bug? There can be at most 15 virtual disk attached on an SCSi controller, so if the limitation is reached, a new controller should be automatically created. In nova/virt/vmwareapi/vm_util.py: def allocate_controller_key_and_unit_number(client_factory, devices,                                             adapter_type):     """This function inspects the current set of hardware devices and returns     controller_key and unit_number that can be used for attaching a new virtual     disk to adapter with the given adapter_type.     """     if devices.__class__.__name__ == "ArrayOfVirtualDevice":         devices = devices.VirtualDevice     taken = _find_allocated_slots(devices)     ret = None     if adapter_type == 'ide':         ide_keys = [dev.key for dev in devices if _is_ide_controller(dev)]         ret = _find_controller_slot(ide_keys, taken, 2)     elif adapter_type in ['lsiLogic', 'lsiLogicsas', 'busLogic','paraVirtual']:         scsi_keys = [dev.key for dev in devices if _is_scsi_controller(dev)]         ret = _find_controller_slot(scsi_keys, taken, 16)     if ret:         return ret[0], ret[1], None     # create new controller with the specified type and return its spec     controller_key = -101     controller_spec = create_controller_spec(client_factory, controller_key,                                              adapter_type)     return controller_key, 0, controller_spec Here we can see, if 'ret' is None, a 'create_controller_spec' is generated for the creation of a new controller. I tested this function, and I check the value of 'vmdk_attach_config_spec.deviceChange' [(VirtualDeviceConfigSpec){    dynamicType = None    dynamicProperty[] = <empty>    operation = "add"    fileOperation = "create"    device =       (VirtualDisk){          dynamicType = None          dynamicProperty[] = <empty>          key = -100          deviceInfo =             (Description){                dynamicType = None                dynamicProperty[] = <empty>                label = None                summary = None             }          backing =             (VirtualDiskRawDiskMappingVer1BackingInfo){                dynamicType = None                dynamicProperty[] = <empty>                fileName = ""                datastore =                   (ManagedObjectReference){                      value = None                      _type = ""                   }                backingObjectId = None                lunUuid = None                deviceName = "/vmfs/devices/disks/t10.IET_____001000010000000000000000000000000000000000000000"                compatibilityMode = "physicalMode"                diskMode = "independent_persistent"                uuid = None                contentId = None                changeId = None                parent =                   (VirtualDiskRawDiskMappingVer1BackingInfo){                      dynamicType = None                      dynamicProperty[] = <empty>                      fileName = None                      datastore =                         (ManagedObjectReference){                            value = None                            _type = ""                         }                      backingObjectId = None                      lunUuid = None                      deviceName = None                      compatibilityMode = None                      diskMode = None                      uuid = None                      contentId = None                      changeId = None                   }             }          connectable =             (VirtualDeviceConnectInfo){                dynamicType = None                dynamicProperty[] = <empty>                startConnected = True                allowGuestControl = False                connected = True                status = None             }          slotInfo =             (VirtualDeviceBusSlotInfo){                dynamicType = None                dynamicProperty[] = <empty>             }          controllerKey = -101          unitNumber = 0          capacityInKB = 0          capacityInBytes = None          shares =             (SharesInfo){                dynamicType = None                dynamicProperty[] = <empty>                shares = None                level =                   (SharesLevel){                      value = None                   }             }          storageIOAllocation =             (StorageIOAllocationInfo){                dynamicType = None                dynamicProperty[] = <empty>                limit = None                shares =                   (SharesInfo){                      dynamicType = None                      dynamicProperty[] = <empty>                      shares = None                      level =                         (SharesLevel){                            value = None                         }                   }                reservation = None             }          diskObjectId = None          vFlashCacheConfigInfo =             (VirtualDiskVFlashCacheConfigInfo){                dynamicType = None                dynamicProperty[] = <empty>                vFlashModule = None                reservationInMB = None                cacheConsistencyType = None                cacheMode = None                blockSizeInKB = None             }       }    profile[] = <empty>  }, (VirtualDeviceConfigSpec){    dynamicType = None    dynamicProperty[] = <empty>    operation = "add"    fileOperation =       (VirtualDeviceConfigSpecFileOperation){          value = None       }    device =       (ParaVirtualSCSIController){          dynamicType = None          dynamicProperty[] = <empty>          key = -101          deviceInfo =             (Description){                dynamicType = None                dynamicProperty[] = <empty>                label = None                summary = None             }          backing =             (VirtualDeviceBackingInfo){                dynamicType = None                dynamicProperty[] = <empty>             }          connectable =             (VirtualDeviceConnectInfo){                dynamicType = None                dynamicProperty[] = <empty>                startConnected = None                allowGuestControl = None                connected = None                status = None             }          slotInfo =             (VirtualDeviceBusSlotInfo){                dynamicType = None                dynamicProperty[] = <empty>             }          controllerKey = None          unitNumber = None          busNumber = 0          device[] = <empty>          hotAddRemove = None          sharedBus = "noSharing"          scsiCtlrUnitNumber = None       }    profile[] = <empty>  }] It really seems a request for creating a new controller, and then attach the virtual disk to it. But I met errors after this. In an icehouse environment, it is reported as "VMwareDriverException: Cannot modify existing SCSI device" In a kilo environment, it is reported as "VMwareDriverException: Number of virtual devices exceeds the maximum for a given controller." (their controller types are different, I don't know if this is the reason of the difference of the error messages) So, in a conclusion, my questions are: 1. Is it designed to create a new controller when all existing controllers all reach their limits? 2. If the answer of question 1 is yes, is this function tested to work? 3. If the answers of question 1 and 2 are both yes, is my situation can be regard as a bug?
2015-12-03 08:19:41 Vipin Balachandran bug task deleted cinder
2015-12-18 06:47:02 Zhao Zhe description There can be at most 15 virtual disk attached on an SCSi controller, so if the limitation is reached, a new controller should be automatically created. In nova/virt/vmwareapi/vm_util.py: def allocate_controller_key_and_unit_number(client_factory, devices,                                             adapter_type):     """This function inspects the current set of hardware devices and returns     controller_key and unit_number that can be used for attaching a new virtual     disk to adapter with the given adapter_type.     """     if devices.__class__.__name__ == "ArrayOfVirtualDevice":         devices = devices.VirtualDevice     taken = _find_allocated_slots(devices)     ret = None     if adapter_type == 'ide':         ide_keys = [dev.key for dev in devices if _is_ide_controller(dev)]         ret = _find_controller_slot(ide_keys, taken, 2)     elif adapter_type in ['lsiLogic', 'lsiLogicsas', 'busLogic','paraVirtual']:         scsi_keys = [dev.key for dev in devices if _is_scsi_controller(dev)]         ret = _find_controller_slot(scsi_keys, taken, 16)     if ret:         return ret[0], ret[1], None     # create new controller with the specified type and return its spec     controller_key = -101     controller_spec = create_controller_spec(client_factory, controller_key,                                              adapter_type)     return controller_key, 0, controller_spec Here we can see, if 'ret' is None, a 'create_controller_spec' is generated for the creation of a new controller. I tested this function, and I check the value of 'vmdk_attach_config_spec.deviceChange' [(VirtualDeviceConfigSpec){    dynamicType = None    dynamicProperty[] = <empty>    operation = "add"    fileOperation = "create"    device =       (VirtualDisk){          dynamicType = None          dynamicProperty[] = <empty>          key = -100          deviceInfo =             (Description){                dynamicType = None                dynamicProperty[] = <empty>                label = None                summary = None             }          backing =             (VirtualDiskRawDiskMappingVer1BackingInfo){                dynamicType = None                dynamicProperty[] = <empty>                fileName = ""                datastore =                   (ManagedObjectReference){                      value = None                      _type = ""                   }                backingObjectId = None                lunUuid = None                deviceName = "/vmfs/devices/disks/t10.IET_____001000010000000000000000000000000000000000000000"                compatibilityMode = "physicalMode"                diskMode = "independent_persistent"                uuid = None                contentId = None                changeId = None                parent =                   (VirtualDiskRawDiskMappingVer1BackingInfo){                      dynamicType = None                      dynamicProperty[] = <empty>                      fileName = None                      datastore =                         (ManagedObjectReference){                            value = None                            _type = ""                         }                      backingObjectId = None                      lunUuid = None                      deviceName = None                      compatibilityMode = None                      diskMode = None                      uuid = None                      contentId = None                      changeId = None                   }             }          connectable =             (VirtualDeviceConnectInfo){                dynamicType = None                dynamicProperty[] = <empty>                startConnected = True                allowGuestControl = False                connected = True                status = None             }          slotInfo =             (VirtualDeviceBusSlotInfo){                dynamicType = None                dynamicProperty[] = <empty>             }          controllerKey = -101          unitNumber = 0          capacityInKB = 0          capacityInBytes = None          shares =             (SharesInfo){                dynamicType = None                dynamicProperty[] = <empty>                shares = None                level =                   (SharesLevel){                      value = None                   }             }          storageIOAllocation =             (StorageIOAllocationInfo){                dynamicType = None                dynamicProperty[] = <empty>                limit = None                shares =                   (SharesInfo){                      dynamicType = None                      dynamicProperty[] = <empty>                      shares = None                      level =                         (SharesLevel){                            value = None                         }                   }                reservation = None             }          diskObjectId = None          vFlashCacheConfigInfo =             (VirtualDiskVFlashCacheConfigInfo){                dynamicType = None                dynamicProperty[] = <empty>                vFlashModule = None                reservationInMB = None                cacheConsistencyType = None                cacheMode = None                blockSizeInKB = None             }       }    profile[] = <empty>  }, (VirtualDeviceConfigSpec){    dynamicType = None    dynamicProperty[] = <empty>    operation = "add"    fileOperation =       (VirtualDeviceConfigSpecFileOperation){          value = None       }    device =       (ParaVirtualSCSIController){          dynamicType = None          dynamicProperty[] = <empty>          key = -101          deviceInfo =             (Description){                dynamicType = None                dynamicProperty[] = <empty>                label = None                summary = None             }          backing =             (VirtualDeviceBackingInfo){                dynamicType = None                dynamicProperty[] = <empty>             }          connectable =             (VirtualDeviceConnectInfo){                dynamicType = None                dynamicProperty[] = <empty>                startConnected = None                allowGuestControl = None                connected = None                status = None             }          slotInfo =             (VirtualDeviceBusSlotInfo){                dynamicType = None                dynamicProperty[] = <empty>             }          controllerKey = None          unitNumber = None          busNumber = 0          device[] = <empty>          hotAddRemove = None          sharedBus = "noSharing"          scsiCtlrUnitNumber = None       }    profile[] = <empty>  }] It really seems a request for creating a new controller, and then attach the virtual disk to it. But I met errors after this. In an icehouse environment, it is reported as "VMwareDriverException: Cannot modify existing SCSI device" In a kilo environment, it is reported as "VMwareDriverException: Number of virtual devices exceeds the maximum for a given controller." (their controller types are different, I don't know if this is the reason of the difference of the error messages) So, in a conclusion, my questions are: 1. Is it designed to create a new controller when all existing controllers all reach their limits? 2. If the answer of question 1 is yes, is this function tested to work? 3. If the answers of question 1 and 2 are both yes, is my situation can be regard as a bug? There can be at most 15 virtual disk attached on an SCSi controller, so if the limitation is reached, a new controller should be automatically created. But I met an error when trying to attach more than 15 volumes to an instance. It is reported as "VMwareDriverException: Cannot modify existing SCSI device"
2015-12-23 05:42:55 Zhao Zhe description There can be at most 15 virtual disk attached on an SCSi controller, so if the limitation is reached, a new controller should be automatically created. But I met an error when trying to attach more than 15 volumes to an instance. It is reported as "VMwareDriverException: Cannot modify existing SCSI device" There can be at most 15 virtual disk attached on an SCSi controller, so if the limitation is reached, a new controller should be automatically created. But I met an error when trying to attach the 15th volume to an instance. It is reported as "VMwareDriverException: Invalid configuration for device '0'"
2016-01-04 07:02:42 Zhao Zhe summary error occurs during attacthing volumes when there is no slots in SCSi controllers failed automatically creating new SCSI controllers
2016-01-11 06:30:00 Feng Xi Yan nova: assignee Feng Xi Yan (yanfengxi)
2016-01-26 07:37:52 OpenStack Infra nova: status New In Progress
2016-02-02 05:30:06 OpenStack Infra nova: assignee Feng Xi Yan (yanfengxi) Ren Qiaowei (qiaowei-ren)
2016-02-02 07:13:49 OpenStack Infra nova: assignee Ren Qiaowei (qiaowei-ren) Feng Xi Yan (yanfengxi)
2016-03-29 14:58:46 OpenStack Infra nova: status In Progress Fix Released
2016-04-21 13:40:36 Matt Riedemann nova: importance Undecided Medium
2016-04-21 13:40:53 Matt Riedemann tags vmware vmware volumes
2016-04-21 15:04:30 OpenStack Infra tags vmware volumes in-stable-mitaka vmware volumes
2016-05-11 17:06:10 Matt Riedemann nominated for series nova/liberty
2016-05-11 17:06:10 Matt Riedemann bug task added nova/liberty
2016-05-11 17:06:10 Matt Riedemann nominated for series nova/mitaka
2016-05-11 17:06:10 Matt Riedemann bug task added nova/mitaka
2016-05-11 17:06:22 Matt Riedemann nova/mitaka: status New Fix Committed
2016-05-11 17:06:25 Matt Riedemann nova/mitaka: importance Undecided Medium
2016-05-11 17:06:28 Matt Riedemann nova/liberty: status New In Progress
2016-05-11 17:06:31 Matt Riedemann nova/liberty: importance Undecided Medium
2016-05-11 17:06:40 Matt Riedemann nova/liberty: assignee Feng Xi Yan (yanfengxi)
2016-05-11 17:07:22 Matt Riedemann nova/mitaka: assignee Feng Xi Yan (yanfengxi)
2016-05-11 20:15:54 OpenStack Infra nova/liberty: status In Progress Fix Committed
2017-06-16 12:18:52 Sean Dague nova/liberty: status Fix Committed Fix Released
2017-06-16 17:42:20 Sean Dague nova/mitaka: status Fix Committed Fix Released