Quantcast
Channel: VMware Communities : Popular Discussions - VIX API
Viewing all articles
Browse latest Browse all 34639

Guest Logins Via the VIX API

$
0
0

 

Hi, All,

 

 

The VIX SDK comes with a sample that supposedly allows clients to execute scripts on a guest OS running on a VI server. For some reason, I've not been able to even login to the guest OS, let alone run scripts on it. In my case, I've a linux (ubuntu) VM running on vSphere Server 4.0. I'm working with the assumption that vSphere can act as the "VIX_SERVICEPROVIDER_VMWARE_VI_SERVER".

 

 

Basically, here's the sequence of VIX calls made by the guestOps.c program provided by the VIX SDK:

 

 

VixHost_Connect, VixJob_Wait

 

 

VixVM_Open, VixJob_Wait

 

 

VixVM_LoginInGuest, VixJob_Wait

 

 

VixVM_RunProgramInGuest,  VixJob_Wait

 

 

VixVM_CopyFileFromGuestToHost, VixJob_Wait

 

 

VixVM_DeleteFileInGues, VixJob_Wait

 

 

Note that I don't try to power on the VM, since it already has been powered on and the tools installed on it. Here's what it says when I ty to run it (see attached file):

 

 

opened karthick/karthick.vmx (34603068)

failed to login to virtual machine '[vsa-mds] karthick/karthick.vmx'(3006 The virtual machine needs to be powered on)

 

 

Just for good measure,  I tried running the program in its original form (which will try to power on the VM first), and here's what happens:

 

 

opened karthick/karthick.vmx (34603068)

failed to power on virtual machine (3008 Cannot connect to the virtual machine)

 

 

So, that begs the following questions: 

 

 

a) Can the vSphere server act as a VI server? If not, how can I use VIX to talk to vSphere?

 

 

b) Can I execute a script on a VM assuming it is already powered on?

 

 

c) Do I need to grant rights to the VIX client in order for it to log into a guest OS? If so, how and where do I configure that?

 

 

Thanks in advance, Karthick Sankarachary

 

 


Viewing all articles
Browse latest Browse all 34639

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>