Well, I'll be honest, I don't have a place to run 2.5 currently, so someone
else may have to chime in. I saw that config in the source on GitHub.
I also create many VMs from templates currently with 2.4, from a base
template configured with 1 CPU that is deployed to targets with multiple
CPUs, vastly different network and disk, etc., and they show up fine,
though I'm not adjusting cores per cpu.
Including the output from '-vvv' may be helpful to others that might be
reading.
If you want more sockets, you want to set num_cpus higher. If you want
cores per cpu but aren't getting them in the machine, but you should make
sure that you're running an appropriate version of vCenter and that indeed
they are missing in the machine's settings in vCenter. Could be an issue
needs to be opened.
On Thursday, March 22, 2018 at 4:02:08 PM UTC-5, talha jilal wrote:
>
>
> Yes I also tried this option but it does not impact my number of sockets.
> Thank you for your reply ,
>
> Appreciate your response.
>
> ( Note I am creating vms from templates ) .
>
> Any suggestion ?
>
> Output from (
>
> hardware:
> memory_mb: "{{ ram_size }}"
> num_cpus: "{{ cpu_nums }}"
> num_cpu_cores_per_socket: 2
>
>
> ============= Output --============
>
>
>
> ok: [kuber-n-03] => {
> "deploy": {
> "changed": true,
> "failed": false,
> "instance": {
> "annotation": "",
> "current_snapshot": null,
> "customvalues": {},
> "guest_tools_status": "guestToolsNotRunning",
> "guest_tools_version": "2147483647",
> "hw_eth0": {
> "addresstype": "assigned",
> "ipaddresses": null,
> "label": "Network adapter 1",
> "macaddress": "00:50:56:b7:a8:a8",
> "macaddress_dash": "00-50-56-b7-a8-a8",
> "summary": "VM Network"
> },
> "hw_guest_full_name": null,
> "hw_guest_id": null,
> "hw_interfaces": [
> "eth0"
> ],
> "hw_memtotal_mb": 2048,
> "hw_name": "kuber-n-03",
> "hw_power_status": "poweredOn",
> "hw_processor_count": 2,
> "hw_product_uuid": "42371497-b8e6-5c9d-8859-6d73af6b9f78",
> "ipv4": null,
> "ipv6": null,
> "module_hw": true,
> "snapshots": []
> }
> }
> }
>
> ================ End of output =============
>
>
>
>
>
>
>
> On Thursday, 22 March 2018 16:55:01 UTC-4, Nick Rogers wrote:
>>
>> Looks like in 2.5 you specify 'num_cpu_cores_per_socket' in the
>> vmware_guest 'hardware' dictionary.
>>
>> - name: Create VM
>> vmware_guest:
>> hostname: somevmwareesxhost
>> ... other vmware_guest config ...
>> hardware:
>> num_cpus: 4
>> num_cpu_cores_per_socket: 8
>> ... other hardware config ...
>> ... other vmware_guest config ...
>>
>>
>>
>>
>> On Thursday, March 22, 2018 at 3:05:47 PM UTC-5, talha jilal wrote:
>>>
>>> Hello,
>>>
>>> I am deploying vms with vmware_guest module, and I need to edit "number
>>> of cores per socket" what statement should I use ?
>>>
>>> I tried the following statement but it always give me error.
>>>
>>> customvalues:
>>> - key: cpuid.coresPerSocket
>>> value: 2
>>>
>>> Error :
>>>
>>>
>>>
>>>
>>> fatal: [kuber-n-03 -> localhost]: FAILED! => {"changed": false, "msg":
>>> "Failed t
>>> o set custom value for
>>> key='numvcpus' and value='two'. Error was: (vmodl.fault.I
>>>
>>> nvalidArgument) {\n dynamicType = <unset>,\n
>>> dynamicProperty = (vmodl.Dynami
>>> cProperty)
>>> [],\n msg = 'A specified parameter was not correct. \\nkey',\n fa
>>>
>>> ultCause = <unset>,\n faultMessage =
>>> (vmodl.LocalizableMessage) [],\n invali
>>>
>>> dProperty = u'key'\n}"}
>>>
>>>
>>>
>>> When I set
>>>
>>> customvalues:
>>> - key: cpuid.coresPerSocket
>>> value: two
>>>
>>>
>>> Error:
>>> > localhost]: FAILED! => {"changed": false, "msg": "Failed t
>>>
>>> o set custom value for key='numvcpus' and value='two'.
>>> Error was: (vmodl.fault.I
>>> nvalidArgument)
>>> {\n dynamicType = <unset>,\n dynamicProperty = (vmodl.Dynami
>>>
>>> cProperty) [],\n msg = 'A specified parameter was
>>> not correct. \\nkey',\n fa
>>> ultCause =
>>> <unset>,\n faultMessage = (vmodl.LocalizableMessage) [],\n invali
>>>
>>> dProperty = u'key'\n}"
>>>
>>
--
You received this message because you are subscribed to the Google Groups
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/ansible-project/0e2119ab-dfb4-4436-a782-f778ba4c5a3f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.