buuren / pysphere

Automatically exported from code.google.com/p/pysphere
0 stars 0 forks source link

Timeout when running a long process on VM and waiting for it to complete #5

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Used a Windows VM
2. Issued a remote command that takes a long time
   (you can simulate this by a batch program that just waits 
    around for 20 or more minutes)
3. Issue the VM's list_processes waiting for the exit_code to be set

What is the expected output? What do you see instead?
Expect the exit_code to eventually get set.  Instead, get the following error:
  File "test.py", line 154, in _getProcess
    processes = vm.list_processes() 
File 
"/root/Perforce/ToolsAutomation/PEToolsDepot/ToolsAutomation/VSAInstaller/python
/pysphere/vi_virtual_machine.py", line 1236, in list_processes
    raise VIApiException(e)
pysphere.resources.vi_exception.VIApiException: 
[GuestOperationsUnavailableFault]: The guest operations agent could not be 
contacted.

What version of the product are you using? On what operating system?
0.1.6 
Linux (CentOS 5.3)
(also failed same way under Windows, so it has more to do with the SOAP 
interface)

Please provide any additional information below.

Original issue reported on code.google.com by kenru...@q.com on 1 Mar 2012 at 5:37

GoogleCodeExporter commented 8 years ago
Hi, thanks for reporting this.

I've haven't been able to reproduce it, I left a long process running on a 
Windows VM (about 40 minutes), and I could run list_processes successfully.

However, the error you're getting is triggered and return by your server 
(vCenter or ESX), pysphere just raises the fault returned as a python 
exception. So if this happen to be a bug, it's a VMWare bug not a pysphere's.
This is the fault returned by your server:

http://pubs.vmware.com/vsphere-50/index.jsp?topic=/com.vmware.wssdk.apiref.doc_5
0/vim.fault.GuestOperationsUnavailable.html

I guess this my be a communication issue between the Host server and the guest 
agent (which runs within the vmware tools service)

I'm closing this ticket as invalid.

Original comment by argo...@gmail.com on 6 Mar 2012 at 1:00

GoogleCodeExporter commented 8 years ago
I believe you are right.  The more we looked into it, the more it appears that 
the guest agent isn't able to respond when the host VM gets really busy (this 
occurred while software was being installed).  We noticed that if we just kept 
polling, eventually the system would start responding again.

Original comment by kenru...@q.com on 7 Mar 2012 at 7:42