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/3bc6dda6-7d68-42b3-ad91-ddc929f73502%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to