Unable to create more than 7 harddisk for windows VM using vmware cloud provider
Unable to create more than 7 harddisk for windows VM using vmware cloud provider
Setup
vm_profile:
name: testVM
provider: vcenter01
clonefrom: Win2012R2
num_cpus: 4
memory: 8GB
datastore: test-datastore
cluster: Test-Cluster
folder: Test VMs
devices:
disk:
Hard disk 1:
size: 45
controller: SCSI controller 1
Hard disk 2:
size: 12
controller: SCSI controller 2
Hard disk 3:
size: 13
controller: SCSI controller 3
Hard disk 4:
size: 45
controller: SCSI controller 1
Hard disk 5:
size: 12
controller: SCSI controller 2
Hard disk 6:
size: 13
controller: SCSI controller 3
Hard disk 7:
size: 45
controller: SCSI controller 1
Hard disk 8:
size: 12
controller: SCSI controller 2
Hard disk 9:
size: 13
controller: SCSI controller 3
scsi:
SCSI controller 1:
type: lsilogic
SCSI controller 2:
type: lsilogic_sas
bus_sharing: virtual
SCSI controller 3:
type: paravirtual
win_installer: /root/Salt-Minion-2015.8.4-AMD64-Setup.exe
win_username: Administrator
win_password: admin
plain_text: True
Steps to Reproduce Issue
Unable to provision VM, getting following error:
[ERROR ] Error creating testVM: (vmodl.fault.InvalidArgument) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
msg = 'A specified parameter was not correct: unitNumber',
faultCause = <unset>,
faultMessage = (vmodl.LocalizableMessage) [],
invalidProperty = u'unitNumber'
}
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/salt-2016.3.0-py2.7.egg/salt/cloud/clouds/vmware.py", line 2499, in create
salt.utils.vmware.wait_for_task(task, vm_name, 'clone', 5, 'info')
File "/usr/local/lib/python2.7/dist-packages/salt-2016.3.0-py2.7.egg/salt/utils/vmware.py", line 650, in wait_for_task
raise Exception(task.info.error)
Exception: (vmodl.fault.InvalidArgument) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
msg = 'A specified parameter was not correct: unitNumber',
faultCause = <unset>,
faultMessage = (vmodl.LocalizableMessage) [],
invalidProperty = u'unitNumber'
}
[DEBUG ] LazyLoaded nested.output
testVM:
----------
Error:
Error creating testVM: (vmodl.fault.InvalidArgument) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
msg = 'A specified parameter was not correct: unitNumber',
faultCause = <unset>,
faultMessage = (vmodl.LocalizableMessage) [],
invalidProperty = u'unitNumber'
Versions Report
Provided by running salt --versions-report
Salt Version:
Salt: 2016.3.0
Dependency Versions:
Jinja2: 2.8
M2Crypto: Not Installed
Mako: Not Installed
PyYAML: 3.11
PyZMQ: 15.2.0
Python: 2.7.9 (default, Mar 1 2015, 12:57:24)
RAET: Not Installed
Tornado: 4.3
ZMQ: 4.0.5
cffi: 0.8.6
cherrypy: Not Installed
dateutil: Not Installed
gitdb: Not Installed
gitpython: Not Installed
ioflo: Not Installed
libgit2: Not Installed
libnacl: Not Installed
msgpack-pure: Not Installed
msgpack-python: 0.4.7
mysql-python: Not Installed
pycparser: 2.10
pycrypto: 2.6.1
pygit2: Not Installed
python-gnupg: Not Installed
smmap: Not Installed
timelib: Not Installed
System Versions:
dist: debian 8.3
machine: x86_64
release: 3.10.0-229.20.1.el7.x86_64
system: debian 8.3
@anandxoriant, thanks for reporting. This looks like it might be a limitation with vmware, although I have not found anything conclusive from searching online. Does it work if you remove one of the disks?
Ping @nmadhok
Only 7 Hard Disks can be created per SCSI controller. I think there may be a bug in the code somewhere. I'll take a look when I get some time.
@anandxoriant Can you share with me/post the complete debug log?
@nmadhok below debug log of salt-cloud command:
root@localhost:/# salt-cloud -p vm_prof testVM -l debug
[DEBUG ] Missing configuration file: /etc/salt/cloud
[DEBUG ] Missing configuration file: /etc/salt/master
[WARNING ] Key master_tops with value {} has an invalid type of dict, a bool is required for this value
[DEBUG ] Reading configuration from /etc/salt/cloud.providers
[DEBUG ] Reading configuration from /etc/salt/cloud.profiles
[DEBUG ] Missing configuration file: /etc/salt/master
[DEBUG ] Please install 'virt-what' to improve results of the 'virtual' grain.
[DEBUG ] Configuration file path: /etc/salt/master
[WARNING ] Insecure logging configuration detected! Sensitive data may be logged.
[INFO ] salt-cloud starting
[DEBUG ] Could not LazyLoad parallels.avail_sizes
[DEBUG ] LazyLoaded parallels.avail_locations
[DEBUG ] LazyLoaded proxmox.avail_sizes
[DEBUG ] Could not LazyLoad saltify.destroy
[DEBUG ] Could not LazyLoad saltify.avail_sizes
[DEBUG ] Could not LazyLoad saltify.avail_images
[DEBUG ] Could not LazyLoad saltify.avail_locations
[DEBUG ] LazyLoaded rackspace.reboot
[DEBUG ] LazyLoaded openstack.list_locations
[DEBUG ] LazyLoaded rackspace.list_locations
[DEBUG ] Could not LazyLoad vmware.optimize_providers
[DEBUG ] The 'vmware' cloud driver is unable to be optimized.
[DEBUG ] Could not LazyLoad parallels.avail_sizes
[DEBUG ] LazyLoaded parallels.avail_locations
[DEBUG ] LazyLoaded proxmox.avail_sizes
[DEBUG ] Could not LazyLoad saltify.destroy
[DEBUG ] Could not LazyLoad saltify.avail_sizes
[DEBUG ] Could not LazyLoad saltify.avail_images
[DEBUG ] Could not LazyLoad saltify.avail_locations
[DEBUG ] LazyLoaded rackspace.reboot
[DEBUG ] LazyLoaded openstack.list_locations
[DEBUG ] LazyLoaded rackspace.list_locations
[INFO ] Starting new HTTPS connection (1): 10.130.72.150
[DEBUG ] "GET //sdk/vimServiceVersions.xml HTTP/1.1" 200 429
[INFO ] Starting new HTTPS connection (1): 10.130.72.150
[DEBUG ] "GET //sdk/vimServiceVersions.xml HTTP/1.1" 200 429
[DEBUG ] Generating minion keys for 'testVM'
[DEBUG ] MasterEvent PUB socket URI: /var/run/salt/master/master_event_pub.ipc
[DEBUG ] MasterEvent PULL socket URI: /var/run/salt/master/master_event_pull.ipc
[DEBUG ] Initializing new IPCClient for path: /var/run/salt/master/master_event_pull.ipc
[DEBUG ] Sending event - data = {'profile': 'vm_prof', 'event': 'starting create', '_stamp': '2016-03-10T05:58:07.846067', 'name': 'testVM', 'provider': 'vcenter:vmware'}
[INFO ] Starting new HTTPS connection (1): 10.130.72.150
[DEBUG ] "GET //sdk/vimServiceVersions.xml HTTP/1.1" 200 429
[INFO ] Starting new HTTPS connection (1): 10.130.72.150
[DEBUG ] "GET //sdk/vimServiceVersions.xml HTTP/1.1" 200 429
[INFO ] Starting new HTTPS connection (1): 10.130.72.150
[DEBUG ] "GET //sdk/vimServiceVersions.xml HTTP/1.1" 200 429
[INFO ] Starting new HTTPS connection (1): 10.130.72.150
[DEBUG ] "GET //sdk/vimServiceVersions.xml HTTP/1.1" 200 429
[INFO ] Starting new HTTPS connection (1): 10.130.72.150
[DEBUG ] "GET //sdk/vimServiceVersions.xml HTTP/1.1" 200 429
[INFO ] Starting new HTTPS connection (1): 10.130.72.150
[DEBUG ] "GET //sdk/vimServiceVersions.xml HTTP/1.1" 200 429
[INFO ] Starting new HTTPS connection (1): 10.130.72.150
[DEBUG ] "GET //sdk/vimServiceVersions.xml HTTP/1.1" 200 429
[INFO ] Starting new HTTPS connection (1): 10.130.72.150
[DEBUG ] "GET //sdk/vimServiceVersions.xml HTTP/1.1" 200 429
[DEBUG ] Setting cpu to: 4
[DEBUG ] Setting memory to: 4096 MB
[DEBUG ] SCSI controllers to create: ['SCSI controller 1', 'SCSI controller 2', 'SCSI controller 3', 'SCSI controller 4']
[DEBUG ] Hard disks to create: ['Hard disk 2', 'Hard disk 3', 'Hard disk 4', 'Hard disk 5', 'Hard disk 6', 'Hard disk 7', 'Hard disk 8', 'Hard disk 9']
[DEBUG ] CD/DVD drives to create: ['CD/DVD drive 1']
[INFO ] Starting new HTTPS connection (1): 10.130.72.150
[DEBUG ] "GET //sdk/vimServiceVersions.xml HTTP/1.1" 200 429
[INFO ] Starting new HTTPS connection (1): 10.130.72.150
[DEBUG ] "GET //sdk/vimServiceVersions.xml HTTP/1.1" 200 429
[DEBUG ] clone_spec set to:
(vim.vm.CloneSpec) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
location = (vim.vm.RelocateSpec) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
datastore = 'vim.Datastore:datastore-11',
diskMoveType = <unset>,
pool = 'vim.ResourcePool:resgroup-8',
host = <unset>,
disk = (vim.vm.RelocateSpec.DiskLocator) [],
transform = <unset>,
deviceChange = (vim.vm.device.VirtualDeviceSpec) [],
profile = (vim.vm.ProfileSpec) []
},
template = false,
config = (vim.vm.ConfigSpec) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
changeVersion = <unset>,
name = <unset>,
version = <unset>,
uuid = <unset>,
instanceUuid = <unset>,
npivNodeWorldWideName = (long) [],
npivPortWorldWideName = (long) [],
npivWorldWideNameType = <unset>,
npivDesiredNodeWwns = <unset>,
npivDesiredPortWwns = <unset>,
npivTemporaryDisabled = <unset>,
npivOnNonRdmDisks = <unset>,
npivWorldWideNameOp = <unset>,
locationId = <unset>,
guestId = <unset>,
alternateGuestName = <unset>,
annotation = <unset>,
files = <unset>,
tools = <unset>,
flags = <unset>,
consolePreferences = <unset>,
powerOpInfo = <unset>,
numCPUs = 4,
numCoresPerSocket = <unset>,
memoryMB = 4096,
memoryHotAddEnabled = <unset>,
cpuHotAddEnabled = <unset>,
cpuHotRemoveEnabled = <unset>,
virtualICH7MPresent = <unset>,
virtualSMCPresent = <unset>,
deviceChange = (vim.vm.device.VirtualDeviceSpec) [
(vim.vm.device.VirtualDeviceSpec) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
operation = 'edit',
fileOperation = <unset>,
device = (vim.vm.device.VirtualDisk) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
key = 2000,
deviceInfo = (vim.Description) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
label = 'Hard disk 1',
summary = '41,943,040 KB'
},
backing = (vim.vm.device.VirtualDisk.FlatVer2BackingInfo) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
fileName = '[test-datastore] Win2008R2/Win2008R2.vmdk',
datastore = 'vim.Datastore:datastore-11',
backingObjectId = '135-2000-0',
diskMode = 'persistent',
split = false,
writeThrough = false,
thinProvisioned = false,
eagerlyScrub = true,
uuid = '6000C292-739d-403a-7482-a49993c4b56e',
contentId = '04c9a73ed2f34672015a1da4da9ba83f',
changeId = <unset>,
parent = <unset>,
deltaDiskFormat = <unset>,
digestEnabled = false,
deltaGrainSize = <unset>
},
connectable = <unset>,
slotInfo = <unset>,
controllerKey = 1000,
unitNumber = 0,
capacityInKB = 47185920,
capacityInBytes = 42949672960L,
shares = (vim.SharesInfo) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
shares = 1000,
level = 'normal'
},
storageIOAllocation = (vim.StorageResourceManager.IOAllocationInfo) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
limit = -1L,
shares = (vim.SharesInfo) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
shares = 1000,
level = 'normal'
},
reservation = 0
},
diskObjectId = '135-2000',
vFlashCacheConfigInfo = <unset>
},
profile = (vim.vm.ProfileSpec) []
},
(vim.vm.device.VirtualDeviceSpec) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
operation = 'add',
fileOperation = <unset>,
device = (vim.vm.device.VirtualLsiLogicController) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
key = -1036,
deviceInfo = (vim.Description) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
label = 'SCSI controller 1',
summary = 'LSI Logic'
},
backing = <unset>,
connectable = <unset>,
slotInfo = <unset>,
controllerKey = <unset>,
unitNumber = <unset>,
busNumber = 1,
device = (int) [],
hotAddRemove = <unset>,
sharedBus = 'noSharing',
scsiCtlrUnitNumber = <unset>
},
profile = (vim.vm.ProfileSpec) []
},
(vim.vm.device.VirtualDeviceSpec) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
operation = 'add',
fileOperation = <unset>,
device = (vim.vm.device.VirtualLsiLogicSASController) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
key = -1033,
deviceInfo = (vim.Description) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
label = 'SCSI controller 2',
summary = 'LSI Logic Sas'
},
backing = <unset>,
connectable = <unset>,
slotInfo = <unset>,
controllerKey = <unset>,
unitNumber = <unset>,
busNumber = 2,
device = (int) [],
hotAddRemove = <unset>,
sharedBus = 'noSharing',
scsiCtlrUnitNumber = <unset>
},
profile = (vim.vm.ProfileSpec) []
},
(vim.vm.device.VirtualDeviceSpec) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
operation = 'add',
fileOperation = <unset>,
device = (vim.vm.device.VirtualLsiLogicSASController) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
key = -1030,
deviceInfo = (vim.Description) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
label = 'SCSI controller 3',
summary = 'LSI Logic Sas'
},
backing = <unset>,
connectable = <unset>,
slotInfo = <unset>,
controllerKey = <unset>,
unitNumber = <unset>,
busNumber = 3,
device = (int) [],
hotAddRemove = <unset>,
sharedBus = 'noSharing',
scsiCtlrUnitNumber = <unset>
},
profile = (vim.vm.ProfileSpec) []
},
(vim.vm.device.VirtualDeviceSpec) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
operation = 'add',
fileOperation = <unset>,
device = (vim.vm.device.VirtualLsiLogicController) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
key = -1020,
deviceInfo = (vim.Description) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
label = 'SCSI controller 4',
summary = 'LSI Logic'
},
backing = <unset>,
connectable = <unset>,
slotInfo = <unset>,
controllerKey = <unset>,
unitNumber = <unset>,
busNumber = 4,
device = (int) [],
hotAddRemove = <unset>,
sharedBus = 'noSharing',
scsiCtlrUnitNumber = <unset>
},
profile = (vim.vm.ProfileSpec) []
},
(vim.vm.device.VirtualDeviceSpec) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
operation = 'add',
fileOperation = 'create',
device = (vim.vm.device.VirtualDisk) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
key = -2098,
deviceInfo = (vim.Description) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
label = 'Hard disk 2',
summary = '12.0 GB'
},
backing = (vim.vm.device.VirtualDisk.FlatVer2BackingInfo) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
fileName = '',
datastore = <unset>,
backingObjectId = <unset>,
diskMode = 'persistent',
split = <unset>,
writeThrough = <unset>,
thinProvisioned = false,
eagerlyScrub = <unset>,
uuid = <unset>,
contentId = <unset>,
changeId = <unset>,
parent = <unset>,
deltaDiskFormat = <unset>,
digestEnabled = <unset>,
deltaGrainSize = <unset>
},
connectable = <unset>,
slotInfo = <unset>,
controllerKey = -1033,
unitNumber = 1,
capacityInKB = 12582912,
capacityInBytes = <unset>,
shares = <unset>,
storageIOAllocation = <unset>,
diskObjectId = <unset>,
vFlashCacheConfigInfo = <unset>
},
profile = (vim.vm.ProfileSpec) []
},
(vim.vm.device.VirtualDeviceSpec) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
operation = 'add',
fileOperation = 'create',
device = (vim.vm.device.VirtualDisk) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
key = -2085,
deviceInfo = (vim.Description) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
label = 'Hard disk 3',
summary = '13.0 GB'
},
backing = (vim.vm.device.VirtualDisk.FlatVer2BackingInfo) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
fileName = '',
datastore = <unset>,
backingObjectId = <unset>,
diskMode = 'persistent',
split = <unset>,
writeThrough = <unset>,
thinProvisioned = false,
eagerlyScrub = <unset>,
uuid = <unset>,
contentId = <unset>,
changeId = <unset>,
parent = <unset>,
deltaDiskFormat = <unset>,
digestEnabled = <unset>,
deltaGrainSize = <unset>
},
connectable = <unset>,
slotInfo = <unset>,
controllerKey = -1030,
unitNumber = 2,
capacityInKB = 13631488,
capacityInBytes = <unset>,
shares = <unset>,
storageIOAllocation = <unset>,
diskObjectId = <unset>,
vFlashCacheConfigInfo = <unset>
},
profile = (vim.vm.ProfileSpec) []
},
(vim.vm.device.VirtualDeviceSpec) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
operation = 'add',
fileOperation = 'create',
device = (vim.vm.device.VirtualDisk) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
key = -2014,
deviceInfo = (vim.Description) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
label = 'Hard disk 4',
summary = '45.0 GB'
},
backing = (vim.vm.device.VirtualDisk.FlatVer2BackingInfo) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
fileName = '',
datastore = <unset>,
backingObjectId = <unset>,
diskMode = 'persistent',
split = <unset>,
writeThrough = <unset>,
thinProvisioned = false,
eagerlyScrub = <unset>,
uuid = <unset>,
contentId = <unset>,
changeId = <unset>,
parent = <unset>,
deltaDiskFormat = <unset>,
digestEnabled = <unset>,
deltaGrainSize = <unset>
},
connectable = <unset>,
slotInfo = <unset>,
controllerKey = -1036,
unitNumber = 3,
capacityInKB = 47185920,
capacityInBytes = <unset>,
shares = <unset>,
storageIOAllocation = <unset>,
diskObjectId = <unset>,
vFlashCacheConfigInfo = <unset>
},
profile = (vim.vm.ProfileSpec) []
},
(vim.vm.device.VirtualDeviceSpec) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
operation = 'add',
fileOperation = 'create',
device = (vim.vm.device.VirtualDisk) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
key = -2058,
deviceInfo = (vim.Description) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
label = 'Hard disk 5',
summary = '12.0 GB'
},
backing = (vim.vm.device.VirtualDisk.FlatVer2BackingInfo) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
fileName = '',
datastore = <unset>,
backingObjectId = <unset>,
diskMode = 'persistent',
split = <unset>,
writeThrough = <unset>,
thinProvisioned = false,
eagerlyScrub = <unset>,
uuid = <unset>,
contentId = <unset>,
changeId = <unset>,
parent = <unset>,
deltaDiskFormat = <unset>,
digestEnabled = <unset>,
deltaGrainSize = <unset>
},
connectable = <unset>,
slotInfo = <unset>,
controllerKey = -1033,
unitNumber = 4,
capacityInKB = 12582912,
capacityInBytes = <unset>,
shares = <unset>,
storageIOAllocation = <unset>,
diskObjectId = <unset>,
vFlashCacheConfigInfo = <unset>
},
profile = (vim.vm.ProfileSpec) []
},
(vim.vm.device.VirtualDeviceSpec) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
operation = 'add',
fileOperation = 'create',
device = (vim.vm.device.VirtualDisk) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
key = -2012,
deviceInfo = (vim.Description) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
label = 'Hard disk 6',
summary = '13.0 GB'
},
backing = (vim.vm.device.VirtualDisk.FlatVer2BackingInfo) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
fileName = '',
datastore = <unset>,
backingObjectId = <unset>,
diskMode = 'persistent',
split = <unset>,
writeThrough = <unset>,
thinProvisioned = false,
eagerlyScrub = <unset>,
uuid = <unset>,
contentId = <unset>,
changeId = <unset>,
parent = <unset>,
deltaDiskFormat = <unset>,
digestEnabled = <unset>,
deltaGrainSize = <unset>
},
connectable = <unset>,
slotInfo = <unset>,
controllerKey = -1030,
unitNumber = 5,
capacityInKB = 13631488,
capacityInBytes = <unset>,
shares = <unset>,
storageIOAllocation = <unset>,
diskObjectId = <unset>,
vFlashCacheConfigInfo = <unset>
},
profile = (vim.vm.ProfileSpec) []
},
(vim.vm.device.VirtualDeviceSpec) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
operation = 'add',
fileOperation = 'create',
device = (vim.vm.device.VirtualDisk) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
key = -2028,
deviceInfo = (vim.Description) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
label = 'Hard disk 7',
summary = '45.0 GB'
},
backing = (vim.vm.device.VirtualDisk.FlatVer2BackingInfo) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
fileName = '',
datastore = <unset>,
backingObjectId = <unset>,
diskMode = 'persistent',
split = <unset>,
writeThrough = <unset>,
thinProvisioned = false,
eagerlyScrub = <unset>,
uuid = <unset>,
contentId = <unset>,
changeId = <unset>,
parent = <unset>,
deltaDiskFormat = <unset>,
digestEnabled = <unset>,
deltaGrainSize = <unset>
},
connectable = <unset>,
slotInfo = <unset>,
controllerKey = -1036,
unitNumber = 6,
capacityInKB = 47185920,
capacityInBytes = <unset>,
shares = <unset>,
storageIOAllocation = <unset>,
diskObjectId = <unset>,
vFlashCacheConfigInfo = <unset>
},
profile = (vim.vm.ProfileSpec) []
},
(vim.vm.device.VirtualDeviceSpec) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
operation = 'add',
fileOperation = 'create',
device = (vim.vm.device.VirtualDisk) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
key = -2086,
deviceInfo = (vim.Description) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
label = 'Hard disk 8',
summary = '12.0 GB'
},
backing = (vim.vm.device.VirtualDisk.FlatVer2BackingInfo) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
fileName = '',
datastore = <unset>,
backingObjectId = <unset>,
diskMode = 'persistent',
split = <unset>,
writeThrough = <unset>,
thinProvisioned = false,
eagerlyScrub = <unset>,
uuid = <unset>,
contentId = <unset>,
changeId = <unset>,
parent = <unset>,
deltaDiskFormat = <unset>,
digestEnabled = <unset>,
deltaGrainSize = <unset>
},
connectable = <unset>,
slotInfo = <unset>,
controllerKey = -1033,
unitNumber = 7,
capacityInKB = 12582912,
capacityInBytes = <unset>,
shares = <unset>,
storageIOAllocation = <unset>,
diskObjectId = <unset>,
vFlashCacheConfigInfo = <unset>
},
profile = (vim.vm.ProfileSpec) []
},
(vim.vm.device.VirtualDeviceSpec) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
operation = 'add',
fileOperation = 'create',
device = (vim.vm.device.VirtualDisk) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
key = -2004,
deviceInfo = (vim.Description) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
label = 'Hard disk 9',
summary = '13.0 GB'
},
backing = (vim.vm.device.VirtualDisk.FlatVer2BackingInfo) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
fileName = '',
datastore = <unset>,
backingObjectId = <unset>,
diskMode = 'persistent',
split = <unset>,
writeThrough = <unset>,
thinProvisioned = false,
eagerlyScrub = <unset>,
uuid = <unset>,
contentId = <unset>,
changeId = <unset>,
parent = <unset>,
deltaDiskFormat = <unset>,
digestEnabled = <unset>,
deltaGrainSize = <unset>
},
connectable = <unset>,
slotInfo = <unset>,
controllerKey = -1030,
unitNumber = 8,
capacityInKB = 13631488,
capacityInBytes = <unset>,
shares = <unset>,
storageIOAllocation = <unset>,
diskObjectId = <unset>,
vFlashCacheConfigInfo = <unset>
},
profile = (vim.vm.ProfileSpec) []
},
(vim.vm.device.VirtualDeviceSpec) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
operation = 'add',
fileOperation = <unset>,
device = (vim.vm.device.VirtualCdrom) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
key = -3017,
deviceInfo = (vim.Description) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
label = 'CD/DVD drive 1',
summary = 'ISO [test-datastore] ISOs/en_sql_server_2012_enterprise_edition_with_sp1_x64_dvd_1227976.iso'
},
backing = (vim.vm.device.VirtualCdrom.IsoBackingInfo) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
fileName = '[test-datastore] ISOs/en_sql_server_2012_enterprise_edition_with_sp1_x64_dvd_1227976.iso',
datastore = 'vim.Datastore:datastore-11',
backingObjectId = <unset>
},
connectable = (vim.vm.device.VirtualDevice.ConnectInfo) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
startConnected = true,
allowGuestControl = true,
connected = false,
status = <unset>
},
slotInfo = <unset>,
controllerKey = 200,
unitNumber = <unset>
},
profile = (vim.vm.ProfileSpec) []
}
],
cpuAllocation = <unset>,
memoryAllocation = <unset>,
latencySensitivity = <unset>,
cpuAffinity = <unset>,
memoryAffinity = <unset>,
networkShaper = <unset>,
cpuFeatureMask = (vim.vm.ConfigSpec.CpuIdInfoSpec) [],
extraConfig = (vim.option.OptionValue) [],
swapPlacement = <unset>,
bootOptions = <unset>,
vAppConfig = <unset>,
ftInfo = <unset>,
vAppConfigRemoved = <unset>,
vAssertsEnabled = <unset>,
changeTrackingEnabled = <unset>,
firmware = <unset>,
maxMksConnections = <unset>,
guestAutoLockEnabled = <unset>,
managedBy = <unset>,
memoryReservationLockedToMax = <unset>,
nestedHVEnabled = <unset>,
vPMCEnabled = <unset>,
scheduledHardwareUpgradeInfo = <unset>,
vmProfile = (vim.vm.ProfileSpec) []
},
customization = <unset>,
powerOn = true,
snapshot = <unset>,
memory = <unset>
}
[DEBUG ] MasterEvent PUB socket URI: /var/run/salt/master/master_event_pub.ipc
[DEBUG ] MasterEvent PULL socket URI: /var/run/salt/master/master_event_pull.ipc
[DEBUG ] Initializing new IPCClient for path: /var/run/salt/master/master_event_pull.ipc
[DEBUG ] Sending event - data = {'_stamp': '2016-03-10T05:58:09.129283', 'event': 'requesting instance', 'kwargs': {'profile': 'vm_prof', 'inline_script': None, 'priv_key': '-----BEGIN RSA PRIVATE KEY-----\nMIIEpAIBAAKCAQEA8jJ+wjV50gxU9wgsOPFZHihJFc/Iaymuc7i7zwULOmjEDP7a\n4O+gaGFOQ/+tRm5Ag05vIBN2Z4a2wGasDvLZe330jrZKuffgUC3xLnjcKA21XWUL\nxcGMcIEqp68ivVLdFoPmy4PSJd66dE9Oa+2X9caFJoQNI5ZdvX4Tfy3tEycAaO+X\npuuIfLiWu6b6vLdMenGHxy+TWhWQqJLxJHRM2GMpGKVyUJ2t2CgwU9itSMCT9UPU\nCn8yWDgk0roz/tRtE9SPttJhP5H4PddkSdDFXjcnlrLVQ5BT67JPxSzco8SOs5XC\nY4XpeG27adj3sptOLW9ffP0ktiGsHziDu/2hnQIDAQABAoIBAQC5MWM7nShJNKTD\nP7yQzfsW1DcONpNJXdXHJrp00aaEQxel2DoFRTWimsT9ucME18j8njzaigc/ogKb\nm+Z0h71EcEtP1JPPH3ql1HtWzZOKDPFhOKKH1DdOz3WOQpyNp47maHVRqLpHusdX\nqEyOul430FR/3vks/Q0wl/bQiI1+1hbetfM5zOIbz87xfek2GYpwTU9g6Dxjgv2W\nlaHhlMcNVxenYs1N6DvDX12D/peDOE/dJfXfllW+psF3sgtB4Os7Z7JPcLX1mLNo\n7XriBaknu9pKOycEQmeM4sKQIWGL9HqjIVbkTmil4sKiSXPQI54YiTCrUW+y2ptc\nuDTWfekBAoGBAPS0+2bDHbLiZDX60+iOPMh3NYfsmLWQDo1DBDGFX+TeIJhVhlHN\nBk8i9YSennpL8Dd7C2OPSM9/Pyohr7VWQ1zaDuq+vBYOCF6qHCi6q1bD5I3ALyZg\nH57dAgvYYbGRss5Qwp+jCYjgrv4KTIf601yay7T3oYSLLOEMUFox9OSrAoGBAP1f\n3OLVF0FJpT4XErB8Ry6hB1zMPxhAtmpBKxFnOCmu6HdEnwV0muq+3iZ1p+m99Yko\n3Mv/kFnpqi8ssOVhuGTCqpnl7RIb4lH3m/1cI71+BB+HSJS8Umd+IACkBxKlFVBz\nB3pYU3FTroMmmRMPnDkxqYEOqkgybGIrAERGGMLXAoGALg25mrdx6W6uCXKxWv0Z\n92hoDLK8cr8v3eoU6fT9/SbI36KI6vA5Fb+wkUsA7GdKSEbB9/TJcTOzgYxhczFO\n8DShxhArecMeVCKTth6bjHLFmt/mf8RrbwyNDAmnKTIQgr+0QTL/4mDWzjzF9nmA\nOddwKxjHrxg6VAhrPu5T9o0CgYEAizkgm3dxlstLxAlTmKxBRMrwy7njNYVhdpMm\ngiKQhr74N4j6RDolYbXNRZ7CzDo3780HPgTIoc82V0OcU/5VHvCkY3omwRuXSWjg\nSuBVNytGQrjIVgoA0aNJHHEE/ea+Bn2eb0iXWR8dNi2AUSvzsK2sMSEIyjECwxJT\nzDAkLPMCgYBaV4dODVsWblMbxEH5Q4xconBX83nmfVY86eTfETflH9puJSOZwdQp\nFM1bK4KPJGQFHtIbLJJjkwnVITLCqduSePjfOZhwtjznUXOM69IfD8CbslpKWI//\n7rmij8Q/RD0O90rF6WN7gBPjpvQYMx9oQDEEFzzce0yiDTjhO58d8A==\n-----END RSA PRIVATE KEY-----', 'protocol': 'https', 'minion': {'master': '10.XX.XX.XX'}, 'plain_text': True, 'memory': '4GB', 'driver': 'vcenter:vmware', 'cluster': 'Test-Cluster', 'win_installer': '/root/Salt-Minion-2015.8.4-AMD64-Setup.exe', 'user': 'administrator', 'win_password': 'admin', 'password': 'XXXXX', 'port': 443, 'name': 'testVM', 'clonefrom': 'Win2012R2', 'url': '10.XX.XX.XX', 'pub_key': '-----BEGIN PUBLIC KEY-----\nMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA8jJ+wjV50gxU9wgsOPFZ\nHihJFc/Iaymuc7i7zwULOmjEDP7a4O+gaGFOQ/+tRm5Ag05vIBN2Z4a2wGasDvLZ\ne330jrZKuffgUC3xLnjcKA21XWULxcGMcIEqp68ivVLdFoPmy4PSJd66dE9Oa+2X\n9caFJoQNI5ZdvX4Tfy3tEycAaO+XpuuIfLiWu6b6vLdMenGHxy+TWhWQqJLxJHRM\n2GMpGKVyUJ2t2CgwU9itSMCT9UPUCn8yWDgk0roz/tRtE9SPttJhP5H4PddkSdDF\nXjcnlrLVQ5BT67JPxSzco8SOs5XCY4XpeG27adj3sptOLW9ffP0ktiGsHziDu/2h\nnQIDAQAB\n-----END PUBLIC KEY-----', 'num_cpus': 4, 'devices': {'scsi': {'SCSI controller 3': {'type': 'lsilogic_sas'}, 'SCSI controller 2': {'type': 'lsilogic_sas'}, 'SCSI controller 1': {'type': 'lsilogic'}, 'SCSI controller 4': {'type': 'lsilogic'}}, 'disk': {'Hard disk 9': {'controller': 'SCSI controller 3', 'size': 13}, 'Hard disk 8': {'controller': 'SCSI controller 2', 'size': 12}, 'Hard disk 1': {'controller': 'SCSI controller 1', 'size': 45}, 'Hard disk 3': {'controller': 'SCSI controller 3', 'size': 13}, 'Hard disk 2': {'controller': 'SCSI controller 2', 'size': 12}, 'Hard disk 5': {'controller': 'SCSI controller 2', 'size': 12}, 'Hard disk 4': {'controller': 'SCSI controller 1', 'size': 45}, 'Hard disk 7': {'controller': 'SCSI controller 1', 'size': 45}, 'Hard disk 6': {'controller': 'SCSI controller 3', 'size': 13}}, 'cd': {'CD/DVD drive 1': {'device_type': 'datastore_iso_file', 'iso_path': '[test-datastore] ISOs/en_sql_server_2012_enterprise_edition_with_sp1_x64_dvd_1227976.iso'}}}, 'win_username': 'Administrator','folder': 'TestVMs', 'os': 'bootstrap-salt', 'datastore': 'test-datastore'}}
[INFO ] Creating testVM from template(Win2012R2)
[INFO ] [ testVM ] Waiting for clone task to finish [0 s]
[INFO ] [ testVM ] Waiting for clone task to finish [5 s]
[INFO ] [ testVM ] Waiting for clone task to finish [10 s]
[INFO ] [ testVM ] Waiting for clone task to finish [15 s]
[INFO ] [ testVM ] Waiting for clone task to finish [20 s]
[INFO ] [ testVM ] Waiting for clone task to finish [25 s]
[ERROR ] Error creating testVM: (vmodl.fault.InvalidArgument) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
msg = 'A specified parameter was not correct: unitNumber',
faultCause = <unset>,
faultMessage = (vmodl.LocalizableMessage) [],
invalidProperty = u'unitNumber'
}
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/salt-2016.3.0-py2.7.egg/salt/cloud/clouds/vmware.py", line 2500, in create
salt.utils.vmware.wait_for_task(task, vm_name, 'clone', 5, 'info')
File "/usr/local/lib/python2.7/dist-packages/salt-2016.3.0-py2.7.egg/salt/utils/vmware.py", line 650, in wait_for_task
raise Exception(task.info.error)
Exception: (vmodl.fault.InvalidArgument) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
msg = 'A specified parameter was not correct: unitNumber',
faultCause = <unset>,
faultMessage = (vmodl.LocalizableMessage) [],
invalidProperty = u'unitNumber'
}
[DEBUG ] LazyLoaded nested.output
testVM:
----------
Error:
Error creating testVM: (vmodl.fault.InvalidArgument) {
dynamicType = <unset>,
dynamicProperty = (vmodl.DynamicProperty) [],
msg = 'A specified parameter was not correct: unitNumber',
faultCause = <unset>,
faultMessage = (vmodl.LocalizableMessage) [],
invalidProperty = u'unitNumber'
}
It seems that assigning SCSI storage controller conditions to device is missing as per VMWare standard practice i.e. by default, the SCSI controller is assigned to virtual device node (z:7), so that device node is unavailable for hard disks or SCSI devices.
Please refer below VMware documentation for details explanation: https://pubs.vmware.com/vsphere-60/index.jsp?topic=%2Fcom.vmware.vsphere.vm_admin.doc%2FGUID-5872D173-A076-42FE-8D0B-9DB0EB0E7362.html
still actual issue looks like need to set this disk_spec.device.unitNumber = unit_number never == 7
if unit_number >= 7: unit_number +=1
or something like this
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
If this issue is closed prematurely, please leave a comment and we will gladly reopen the issue.