Skip to content

java.lang.IllegalArgumentException: No enum constant com.vmware.vim25.mox.VirtualMachineDeviceManager.VirtualNetworkAdapterType.VirtualE1000e #7

@alexZJR

Description

@alexZJR

When I used the method 'addNetworkAdapter()' in the sample class 'VmNetworkUtil', to create a vNIC for my Windows2012 VM, I received the IllegalArgumentException as the title mentioned.
I've looked into the Enum in VirtualMachineDeviceManager, and find the following value list:

    VirtualE1000("VirtualE1000"),
    VirtualE1000E("VirtualE1000e"),
    VirtualPCNet32("VirtualPCNet32"),
    VirtualSriovEthernetCard("VirtualSriovEthernetCard"),
    VirtualVmxnet("VirtualVmxnet"),
    VirtualVmxnet2("VirtualVmxnet2"),
    VirtualVmxnet3("VirtualVmxnet3"),
    Unknown("Unknown");

While the result returned by the method 'guestOsInfo.getSupportedEthernetCard()' contains 'VirtualE1000e', which is different from the 'VirtualE1000E ' in the Enum.

So, please kindly fix this issue via correct the 'VirtualE1000E ' into 'VirtualE1000e', or just add value for 'VirtualE1000e'...
Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions