VMware vSphere

 View Only
  • 1.  vmware_guest_info error: unrecognized arguments

    Posted Jun 16, 2020 02:46 AM

    I am almost sure I have the syntax wrong, but cant seem to find an example of the correct usage.

    What is the correct syntax to specify the datacenter name for the vmware_guest_info module?

    I also get the same error if I use datacenter: "{{ Datacenter }}" as shown in the playbook example

    Thanks



  • 2.  RE: vmware_guest_info error: unrecognized arguments

    Posted Nov 03, 2020 12:02 PM

    You can execute it by the following procedure.

    export VMWARE_HOST=vcenter host

    export VMWARE_USERNAME=administrator@vsphere.local

    export VMWARE_PASSWORD=password

    export VMWARE_VALIDATE_CERTS=False

    ansible localhost -c local, -m vmware_guest_info -a "datacenter=DC name=test_vm1"