I just upgraded my server to version 2.0 and my vix client to version 1.5. My vb.net code that was previously connecting properly now gets permission problems.
"Insufficient permissions in host operating system"
I'm using the same logon and userID that I use for the web access on port 8333. Does anyone have any suggestions for getting past this problem?
Here's the routine that was working for VMWare Server 1.0.x with Vix 1.1.
Public Sub New(ByRef hostname As String, ByRef userid As String, ByRef password As String, ByRef vmxFile As String)
Dim job As VixCOM.IJob
Dim vix_status
job = vixlib.Connect(VixCOM.Constants.VIX_API_VERSION, VixCOM.Constants.VIX_SERVICEPROVIDER_VMWARE_SERVER, _
"https://" & hostname & ":902/sdk", 0, userid, password, 0, Nothing, Nothing)
Dim results = Nothing
Dim props() As Integer = {VixCOM.Constants.VIX_PROPERTY_JOB_RESULT_HANDLE}
vix_status = job.Wait(props, results)
If vixlib.ErrorIndicatesFailure(vix_status) Then
Dim VixException As New Exception("Connection to VMWare server '" & hostname & "' failed with exception '" & vixlib.GetErrorText(vix_status, Nothing) & "'")
Throw VixException
End If
host = results(0)
job = host.OpenVM(vmxFile, Nothing)
vix_status = job.Wait(props, results)
If vixlib.ErrorIndicatesFailure(vix_status) Then
Dim VixException As New Exception("Open of '" & vmxFile & "' failed with exception '" & vixlib.GetErrorText(vix_status, Nothing) & "'")
Throw VixException
End If
vm_vmx_file = vmxFile
vm = results(0)
End Sub