Hi ,
I have upgraded to ansible 2.4 and using vmware_guest module to create a VM. I am getting “Failed to find a matching datastore”.
same code works fine in ansiblke 2.3.
is this a known issue or am i missing something?
Thanks,
Vijay
msg": “Failed to find a matching datastore”
Here is my ansible snippet:
- name: Create a virtual machine from the datastore VM ( Using vGPU VM)
local_action:
module: vmware_guest
hostname: ‘{{ hostname }}’
username: ‘{{ username }}’
password: ‘{{ password }}’
name: ‘{{ guest_name}}’
esxi_hostname: ‘{{ esxi_hostname1 }}’
# template: ‘’
is_template: no
datacenter: ‘{{ datacenter_name }}’
state: poweredon
validate_certs: False
register: taskresult
ignore_errors: True
when i run with -vvvv option i see following parameters are passed:
fatal: [xxxxxxxx → localhost]: FAILED! => {
“changed”: false,
“failed”: true,
“invocation”: {
“module_args”: {
“annotation”: null,
“cluster”: null,
“customization”: {},
“customvalues”: [],
“datacenter”: “Datacenter”,
“disk”: [],
“esxi_hostname”: “10…x.x.x”,
“folder”: “/vm”,
“force”: false,
“guest_id”: null,
“hardware”: {},
“hostname”: “10.x.x.x”,
“is_template”: false,
“name”: “myvgpu_clone2”,
“name_match”: “first”,
“networks”: [],
“password”: “VALUE_SPECIFIED_IN_NO_LOG_PARAMETER”,
“resource_pool”: null,
“state”: “poweredon”,
“template_src”: null,
“username”: “administrator@vsphere.local”,
“uuid”: null,
“validate_certs”: false,
“wait_for_ip_address”: false
}
},
“msg”: “Failed to find a matching datastore”
}
…ignoring
I would appreciate your help if you could please help me in resolving this issue.