Hi, I see that xenstat (lib and xentop) code is all written in C. Is there python front-end available for this library or is anyone working on the same? It would be great to have one, because that can be first step to building distributed access to xenstat (I see this mentioned in ''To think about'' in TODO). If no one is working on it I can give it a shot. I saw two instances in xen source tree, that pull data from low level C code up to python scripts: 1. The way xend interacts with lowlevel xc.c 2. Xenmon and Xenbaked - through a scratch file created on disk. First approach looks more efficient even though slightly more difficult. Let me know if anyone has any plans on these lines. Thanks, -- Jayesh ------------------------------------------------------------------------ Everything you can imagine is real _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
To answer my own question, I found the bindings directory and the swig targets in Makefile. I could build perl and python bindings from them by doing ''make all-bindings''. I will have a look at the generated python code and see how I can use it. Jayesh On 4/15/06, Jayesh Salvi <jayeshsalvi@gmail.com> wrote:> > Hi, > > I see that xenstat (lib and xentop) code is all written in C. Is there > python front-end available for this library or is anyone working on the > same? > > It would be great to have one, because that can be first step to building > distributed access to xenstat (I see this mentioned in ''To think about'' in > TODO). > > If no one is working on it I can give it a shot. I saw two instances in > xen source tree, that pull data from low level C code up to python scripts: > 1. The way xend interacts with lowlevel xc.c > 2. Xenmon and Xenbaked - through a scratch file created on disk. > > First approach looks more efficient even though slightly more difficult. > > Let me know if anyone has any plans on these lines. > > Thanks, > -- > Jayesh > ------------------------------------------------------------------------ > Everything you can imagine is real >-- Jayesh ------------------------------------------------------------------------ Everything you can imagine is real _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
On 4/15/06, Jayesh Salvi <jayeshsalvi@gmail.com> wrote:> To answer my own question, I found the bindings directory and the swig > targets in Makefile. I could build perl and python bindings from them by > doing ''make all-bindings''. > > I will have a look at the generated python code and see how I can use it.Did you have any success with this? I could generate the bindings, but when I try to use the Python bindings, I see this error: import xenstat /usr/lib/python2.4/site-packages/xenstat.py 3 # This file is compatible with both classic and new-style classes. 4 ----> 5 import _xenstat 6 import new 7 new_instancemethod = new.instancemethod ImportError: /usr/lib/python2.4/site-packages/_xenstat.so: undefined symbol: xenstat_init Has anyone had success with the xenstat python bindings? TIA, Diwaker -- Web/Blog/Gallery: http://floatingsun.net/blog _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel