Using Vijava, I want to add a new vnic on an existing VM, assign a specific portgroup to it and then set a static IP to it.
Adding a new vnic and assign a portgroup to it works fine. But when trying to set a static IP to the vNic I get the following error:
java.rmi.RemoteException: VI SDK invoke exception:com.vmware.vim25.InvalidRequest at com.vmware.vim25.ws.WSClient.invoke(WSClient.java:122)
Clearly the request is wrong but I don’t know how to find what is missing. I searched on the forums, I tried different combinations but got the same result.
I attached the complete Vijava code here. Also I attached a picture with the details of the request.
I’m using Vijava 5.5
I would appreciate any help.