From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andrew Cooper Subject: Re: xend with XenAPI in stackless python-2.7 Date: Fri, 1 Nov 2013 17:34:23 +0000 Message-ID: <5273E61F.5080701@citrix.com> References: Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1320290233123549173==" Return-path: In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Eric Camachat Cc: xen-devel@lists.xen.org List-Id: xen-devel@lists.xenproject.org --===============1320290233123549173== Content-Type: multipart/alternative; boundary="------------040204080201080708080208" --------------040204080201080708080208 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7bit On 01/11/13 17:05, Eric Camachat wrote: > Hi, > > I am using XEN-4.1.2 and linux-2.6.32 as dom0. > After I upgraded stackless python from 2.5 to 2.7 (and rebuilt xen). > XenAPI became unusable, I spent some time to investigate XenAPI,py, it > looks fine. > So, I guess xend has problem with python 2.7, because it always > returned method unknown. > Do I have to tweak xend to let it support python 2.7? > > Thanks, > Eric xend and XenAPI are two completely different things. xend is the old deprecated Xen toolstack, written entirely in python. It has been replaced with the xenlight toolstack upstream. Xen-API is a separate open source toolstack, written in OCaml. XenAPI.py is just a small python wrapper around the Xen-API XMLRPC interface. Which toolstack are you expecting to be using? ~Andrew > > /root # > python > > Python 2.7.5 Stackless 3.1b3 060516 (default, Oct 31 2013, > 16:45:11) > [GCC 4.2.2] on > linux2 > > Type "help", "copyright", "credits" or "license" for more > information. > >>> import > XenAPI > > >>> session = > XenAPI.xapi_local() > > >>> session.login_with_password('', > '') > > Traceback (most recent call > last): > > File "", line 1, in > > > File "/usr/lib/python2.7/site-packages/XenAPI.py", line 198, in > > return lambda *params: self._login(name, > params) > File "/usr/lib/python2.7/site-packages/XenAPI.py", line 171, in > _login > self.API_version = > self._get_api_version() > > File "/usr/lib/python2.7/site-packages/XenAPI.py", line 186, in > _get_api_version > pool = > self.xenapi.pool.get_all()[0] > > File "/usr/lib/python2.7/site-packages/XenAPI.py", line 245, in > __call__ > return self.__send(self.__name, > args) > > File "/usr/lib/python2.7/site-packages/XenAPI.py", line 149, in > xenapi_request > result = _parse_result(getattr(self, > methodname)(*full_params)) > > File "/usr/lib/python2.7/site-packages/XenAPI.py", line 219, in > _parse_result > raise > Failure(result['ErrorDescription']) > > XenAPI.Failure: ['MESSAGE_METHOD_UNKNOWN', > 'pool.get_all'] > >>> > > > > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xen.org > http://lists.xen.org/xen-devel --------------040204080201080708080208 Content-Type: text/html; charset="ISO-8859-1" Content-Transfer-Encoding: 7bit
On 01/11/13 17:05, Eric Camachat wrote:
Hi,

I am using XEN-4.1.2 and linux-2.6.32 as dom0.
After I upgraded stackless python from 2.5 to 2.7 (and rebuilt xen).
XenAPI became unusable, I spent some time to investigate XenAPI,py, it looks fine.
So, I guess xend has problem with python 2.7, because it always returned method unknown.
Do I have to tweak xend to let it support python 2.7?

Thanks,
Eric

xend and XenAPI are two completely different things.

xend is the old deprecated Xen toolstack, written entirely in python.  It has been replaced with the xenlight toolstack upstream.

Xen-API is a separate open source toolstack, written in OCaml.  XenAPI.py is just a small python wrapper around the Xen-API XMLRPC interface.

Which toolstack are you expecting to be using?

~Andrew


/root # python                                                                                                      
Python 2.7.5 Stackless 3.1b3 060516 (default, Oct 31 2013, 16:45:11)                                                
[GCC 4.2.2] on linux2                                                                                               
Type "help", "copyright", "credits" or "license" for more information.                                              
>>> import XenAPI                                                                                                   
>>> session = XenAPI.xapi_local()                                                                                   
>>> session.login_with_password('', '')                                                                             
Traceback (most recent call last):                                                                                  
  File "<stdin>", line 1, in <module>                                                                               
  File "/usr/lib/python2.7/site-packages/XenAPI.py", line 198, in <lambda>                                          
    return lambda *params: self._login(name, params)                                                                
  File "/usr/lib/python2.7/site-packages/XenAPI.py", line 171, in _login                                            
    self.API_version = self._get_api_version()                                                                      
  File "/usr/lib/python2.7/site-packages/XenAPI.py", line 186, in _get_api_version                                  
    pool = self.xenapi.pool.get_all()[0]                                                                            
  File "/usr/lib/python2.7/site-packages/XenAPI.py", line 245, in __call__                                          
    return self.__send(self.__name, args)                                                                           
  File "/usr/lib/python2.7/site-packages/XenAPI.py", line 149, in xenapi_request                                    
    result = _parse_result(getattr(self, methodname)(*full_params))                                                 
  File "/usr/lib/python2.7/site-packages/XenAPI.py", line 219, in _parse_result                                     
    raise Failure(result['ErrorDescription'])                                                                       
XenAPI.Failure: ['MESSAGE_METHOD_UNKNOWN', 'pool.get_all']                                                          
>>>



_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

--------------040204080201080708080208-- --===============1320290233123549173== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel --===============1320290233123549173==--