[libvirt] [PATCH test-API] Add default uri in env.cfg for testcases

2012-03-27 Thread Guannan Ren
*env.cfg define default uri *generator.py add it into params dict --- env.cfg |4 generator.py |8 2 files changed, 12 insertions(+), 0 deletions(-) diff --git a/env.cfg b/env.cfg index 968e512..2cccbc7 100644 --- a/env.cfg +++ b/env.cfg @@ -107,6 +107,10 @@

Re: [libvirt] [test-API PATCH 4/6] Add default 'uri' parameter to all tests

2012-03-27 Thread Guannan Ren
On 03/27/2012 03:55 PM, Martin Kletzander wrote: On 03/26/2012 03:15 PM, Guannan Ren wrote: This will create a default option named uri on the framework side like logger for all of testcases. If we want all of testcases to test a remote server that results in adding uri

Re: [libvirt] [test-API PATCH 5/6] Cleanup and fix of domain/define test

2012-03-27 Thread Guannan Ren
On 03/27/2012 03:57 PM, Martin Kletzander wrote: It's better not to use libvirt API to check the result of one another API. We should use native approach to do the checking. So I insist on the original checking. There was no lookupByName function, but I agree it's better

Re: [libvirt] [test-API PATCH 5/6] Cleanup and fix of domain/define test

2012-03-27 Thread Guannan Ren
On 03/27/2012 05:42 PM, Martin Kletzander wrote: On 03/27/2012 10:59 AM, Guannan Ren wrote: On 03/27/2012 03:57 PM, Martin Kletzander wrote: It's better not to use libvirt API to check the result of one another API. We should use native approach to do the checking. So I

Re: [libvirt] [test-API PATCH 6/6] Make use of new 'uri' parameter in tests

2012-03-27 Thread Guannan Ren
+- repos/storage/pool_name.py |2 +- repos/storage/pool_uuid.py |2 +- repos/storage/undefine_pool.py |2 +- 88 files changed, 100 insertions(+), 96 deletions(-) Thanks ACK and pushed Guannan Ren

[libvirt] [PATCH 2/2] python: make python APIs use these helper functions

2012-03-26 Thread Guannan Ren
*libvirt_virDomainGetCPUStats *setPyVirTypedParameter --- python/libvirt-override-api.xml |4 +- python/libvirt-override.c | 62 +- 2 files changed, 11 insertions(+), 55 deletions(-) diff --git a/python/libvirt-override-api.xml

Re: [libvirt] [PATCH] test-API: Remove trailing spaces

2012-03-26 Thread Guannan Ren
) ret = check_domain_running(domobj, guestname, logger) if ret: -return return_close(conn, logger, 1) +return return_close(conn, logger, 1) try: domobj.save(guestname, SAVE_FILE) Thanks and pushed Guannan Ren -- libvir-list mailing list libvir

Re: [libvirt] [test-API PATCHv2] libs: Add flags for streams and the console

2012-03-26 Thread Guannan Ren
, flags are in right files according to the API, I'd definitely say ACK, depends on you if you want a second opinion. Martin thanks, pushed Guannan Ren -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] [test-API PATCH 5/6] Cleanup and fix of domain/define test

2012-03-26 Thread Guannan Ren
On 03/25/2012 01:42 AM, Martin Kletzander wrote: I added support for 'uri' parameter and moved some functions into util/Python/utils.py in order not to lose them from the code and keep them accessible for other tests. --- repos/domain/define.py | 132

Re: [libvirt] [test-API PATCH 3/6] Fixed domain/start.py

2012-03-26 Thread Guannan Ren
On 03/25/2012 01:42 AM, Martin Kletzander wrote: Function usage() was called in the code but was missing. Parameter 'flags' was defined as optional but it was still required in the code, so I fixed the handling of it. --- repos/domain/start.py | 15 +++ 1 files changed, 11

Re: [libvirt] [test-API PATCH 4/6] Add default 'uri' parameter to all tests

2012-03-26 Thread Guannan Ren
On 03/25/2012 01:42 AM, Martin Kletzander wrote: Tests should be able to run on various hypervisors and machines. Now we have only two tests that have an option to do something remotely. This commit allows tests to see 'uri' parameter that they should connect to. However it doesn't have to be

Re: [libvirt] [test-API PATCH 1/6] Slight cross-distribution support

2012-03-26 Thread Guannan Ren
Thanks, pushed Guannan Ren -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

[libvirt] [PATCH test-API 0/2]Use encapsulated python APIs in testcases

2012-03-26 Thread Guannan Ren
These two patches modify library modules and exsiting testcases for disallowing the use of the objects of subclasses in libvirt.py directly. The files in lib directory are the layer of encapsulated python APIs. we should use methods in it for good error catching. 93 files changed, 292

[libvirt] [PATCH test-API 1/2] lib: pass instance of ConnectAPI into other lib modules

2012-03-26 Thread Guannan Ren
This change make any instance of subclasses in libvirt.py invisible to testcases in order to catch libvirtError. connectAPI.py domainAPI.py interfaceAPI.py networkAPI.py nodedevAPI.py nwfilterAPI.py secretAPI.py snapshotAPI.py

Re: [libvirt] [PATCH 2/2] python: make python APIs use these helper functions

2012-03-26 Thread Guannan Ren
On 03/27/2012 07:11 AM, Eric Blake wrote: On 03/26/2012 12:11 AM, Guannan Ren wrote: *libvirt_virDomainGetCPUStats *setPyVirTypedParameter --- python/libvirt-override-api.xml |4 +- python/libvirt-override.c | 62 +- 2 files changed

Re: [libvirt] [PATCH 1/2] python: Add new helper functions for python to C integral conversion

2012-03-26 Thread Guannan Ren
libvirt_boolUnwrap will not have any checking for its type of arguments in bool wise. The upper python code could pass a null list or dictionary as a False. Maybe a little bit loose use here. but It's fine to blindly use it actually. Guannan Ren -- libvir-list mailing list libvir-list

Re: [libvirt] [test-API PATCH 0/7] Multiple fixes and improvements series

2012-03-22 Thread Guannan Ren
|4 +- 9 files changed, 105 insertions(+), 78 deletions(-) Hi Peter I have pushed the set of patches after some small modifications based on my comments. If you have any comment, please be free to tell me. Thanks your patches. Guannan Ren -- libvir-list

Re: [libvirt] [test-API PATCH 7/7] domain/[start|destroy]: Add a optional noping flag to skip the ping test

2012-03-22 Thread Guannan Ren
On 03/22/2012 03:02 PM, Martin Kletzander wrote: I'd rather do it using the get() method for dictionaries with some default, i.e. params.get('flags', None). Just my $0.02 Martin Thanks, This belongs to enhancement work, let us do it a little later. Probably, we need a cleanup patch

Re: [libvirt] [test-API PATCH 3/7] domainAPI: Add wrapper method to work with domain's console connections

2012-03-22 Thread Guannan Ren
. Peter Yeath, you are right, we can not cross the encapsulation line. We have to operate above the abstraction layer. Your patch is correct definitely. Guannan Ren -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] [test-API PATCH] streamAPI: Create stream objects that are already encapsulated

2012-03-22 Thread Guannan Ren
should delete the newStream method in connectAPI.py. Right now, the virConnect object from libvirt.py is exposed directly in existing testcases, that's not good way compared to what you did in openConsole. I will clean them next. What do you think? Guannan Ren -- libvir

Re: [libvirt] [test-API PATCH] libs: Add flags for streams and the console

2012-03-22 Thread Guannan Ren
VIR_DOMAIN_AFFECT_CONFIG = 2 +# virDomainConsoleFlags +VIR_DOMAIN_CONSOLE_FORCE = 1 +VIR_DOMAIN_CONSOLE_SAFE = 2 Sorry I didn't find virDomainConsoleFlags in libvirt.py Guannan Ren -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] [PATCH v2] python: add virDomainGetCPUStats python binding API

2012-03-21 Thread Guannan Ren
On 03/20/2012 01:36 AM, Eric Blake wrote: On 03/18/2012 04:41 AM, Guannan Ren wrote: +if (totalbool == Py_False) { Per other code in libvirt-override.c, you can't compare totalbool (type PyObject) with Py_False, at least not on all compilers. You need something like this instead

Re: [libvirt] [PATCH v2] python: add virDomainGetCPUStats python binding API

2012-03-21 Thread Guannan Ren
On 03/21/2012 08:07 PM, Eric Blake wrote: Maybe we need a wrapper: int libvirt_boolUnwrap(PyObject *obj, bool *value) { int ret = PyObject_IsTrue(obj); if (ret 0) return ret; *value = ret 0; return 0; } and then callers become: if

Re: [libvirt] [PATCH v2] python: add virDomainGetCPUStats python binding API

2012-03-21 Thread Guannan Ren
On 03/21/2012 09:23 PM, Eric Blake wrote: On 03/21/2012 07:22 AM, Guannan Ren wrote: On 03/21/2012 08:07 PM, Eric Blake wrote: Maybe we need a wrapper: int libvirt_boolUnwrap(PyObject *obj, bool *value) { int ret = PyObject_IsTrue(obj); if (ret 0) return ret

Re: [libvirt] [PATCH v2] python: add virDomainGetCPUStats python binding API

2012-03-21 Thread Guannan Ren
than forcing them to call dom.getCPUStats(False, 0), if that is the convention allowed elsewhere in native python code. Thanks for these ideas I totally agree with them. Guannan Ren ** -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo

Re: [libvirt] [test-API PATCH 2/7] lib: fix streamAPI class

2012-03-21 Thread Guannan Ren
the LibvirtAPI to raise API error in try..catch clause rather than catch all of other errors from python basic modules or somewhere. Guannan Ren -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] [test-API PATCH 3/7] domainAPI: Add wrapper method to work with domain's console connections

2012-03-21 Thread Guannan Ren
() dom.openConsole(domname, None, st_obj) receivedData = st_obj.recv(1024) (the last statement probably resides in a registered stream callback function via eventAddCallback API) Thanks for the patch. Guannan Ren -- libvir-list mailing list

Re: [libvirt] [test-API PATCH 4/7] repos/domain/create.py: Fix typo in path to python executable

2012-03-21 Thread Guannan Ren
@@ -#!/usr/bin/evn python +#!/usr/bin/env python ACK, thanks Guannan Ren -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] [test-API PATCH 5/7] utils: Allow suffixes in path to the main checkout folder

2012-03-21 Thread Guannan Ren
('(.*)libvirt-test-API', pwd) +result = re.search('(.*)libvirt-test-API(.*)', pwd) return result.group(0) + /utils def mac_to_ip(self, mac, timeout): ACK, thanks Guannan Ren -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir

Re: [libvirt] [test-API PATCH 6/7] parser: Be more specific on mistakes in case files

2012-03-21 Thread Guannan Ren
(Missing module name after \:\) Raising an exception here make parsing stronger, thanks. BTW, It's better to use if component == : Guannan Ren -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] [test-API PATCH 7/7] domain/[start|destroy]: Add a optional noping flag to skip the ping test

2012-03-21 Thread Guannan Ren
flags to be mandatory in the following code. Add checking for it in check_params() Guannan Ren -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] [test-API PATCH] utils: Make ipget.sh more portable

2012-03-21 Thread Guannan Ren
/ipget.sh +++ b/utils/ipget.sh @@ -6,8 +6,8 @@ if [[ -z $mac ]]; then exit 1 fi -if ! rpm -qa |grep -q nmap ;then - echo need nmap rpmball installed. +if ! type nmap/dev/null 21; then + echo nmap package needs to be installed. exit 1 fi ACK ,thanks Guannan Ren -- libvir

Re: [libvirt] [PATCH] python: make virDomainSetSchedulerParameters accpet integer argument

2012-03-20 Thread Guannan Ren
will do it soon Guannan Ren -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] [PATCH v4] python: add virDomainGetCPUStats python binding API

2012-03-20 Thread Guannan Ren
On 03/20/2012 11:42 PM, Eric Blake wrote: On 03/19/2012 10:34 PM, Guannan Ren wrote: dom.getCPUStats(True, 0) [{'cpu_time': 24699446159L, 'system_time': 1087000L, 'user_time': 95000L}] dom.getCPUStats(False, 0) [{'cpu_time': 8535292289L}, {'cpu_time

[libvirt] [PATCH v3] python: add virDomainGetCPUStats python binding API

2012-03-19 Thread Guannan Ren
dom.getCPUStats(True, 0) [{'cpu_time': 24699446159L, 'system_time': 1087000L, 'user_time': 95000L}] dom.getCPUStats(False, 0) [{'cpu_time': 8535292289L}, {'cpu_time': 1005395355L}, {'cpu_time': 9351766377L}, {'cpu_time': 5813545649L}] *generator.py Add a new

Re: [libvirt] [PATCH v2] python: add virDomainGetCPUStats python binding API

2012-03-19 Thread Guannan Ren
be reused to populate the correct return value for ncpus regardless of whether nparams was 0. Thanks for these good suggested points, the v3 has been sent out based on them. Guannan Ren -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir

[libvirt] [PATCH] python: make virDomainSetSchedulerParameters accpet integer argument

2012-03-19 Thread Guannan Ren
When sending a Python integer as an argument to PyLong_AsUnsignedLong or PyLong_AsUnsignedLongLong, the following error occurs SystemError: Objects/longobject.c:980: bad argument to internal function This error comes from the fact that PyLong_AsUnsignedLong and

[libvirt] [PATCH v4] python: add virDomainGetCPUStats python binding API

2012-03-19 Thread Guannan Ren
dom.getCPUStats(True, 0) [{'cpu_time': 24699446159L, 'system_time': 1087000L, 'user_time': 95000L}] dom.getCPUStats(False, 0) [{'cpu_time': 8535292289L}, {'cpu_time': 1005395355L}, {'cpu_time': 9351766377L}, {'cpu_time': 5813545649L}] *generator.py Add a new

Re: [libvirt] [PATCH v2] python: add virDomainGetCPUStats python binding API

2012-03-18 Thread Guannan Ren
On 03/17/2012 01:26 AM, Eric Blake wrote: On 03/14/2012 07:03 AM, Guannan Ren wrote: dom.getCPUStats(True, 0) [{'cpu_time': 92913537401L, 'system_time': 547000L, 'user_time': 31000L}] dom.getCPUStats(False, 0) [{'cpu_time': 39476858499L}, {'cpu_time

Re: [libvirt] Modified version of the libvirt-test-api wrapper

2012-03-16 Thread Guannan Ren
On 03/16/2012 04:24 AM, Lucas Meneghel Rodrigues wrote: On 03/14/2012 11:56 AM, Guannan Ren wrote: On 03/14/2012 06:45 PM, Daniel Veillard wrote: On Tue, Mar 13, 2012 at 11:05:31PM -0300, Lucas Meneghel Rodrigues wrote: Hi Guannan: I've worked on your first version of the libvirt-test-api

Re: [libvirt] [PATCH v2] python: add virDomainGetCPUStats python binding API

2012-03-15 Thread Guannan Ren
Is there anyone who would like to review this :) On 03/14/2012 09:03 PM, Guannan Ren wrote: dom.getCPUStats(True, 0) [{'cpu_time': 92913537401L, 'system_time': 547000L, 'user_time': 31000L}] dom.getCPUStats(False, 0) [{'cpu_time': 39476858499L}, {'cpu_time

[libvirt] [PATCH] python: add virDomainGetCPUStats python binding API

2012-03-14 Thread Guannan Ren
dom.cPUStats(True, 0) [{'cpu_time': 370942649768L, 'system_time': 1164000L, 'user_time': 89000L}] dom.cPUStats(False, 0) [{'cpu_time': 38378374721L}, {'cpu_time': 12475521087L}, {'cpu_time': 127388622598L}, {'cpu_time': 192720388324L}] ---

Re: [libvirt] [PATCH] python: add virDomainGetCPUStats python binding API

2012-03-14 Thread Guannan Ren
On 03/14/2012 05:10 PM, Eric Blake wrote: On 03/14/2012 03:02 AM, Daniel Veillard wrote: On Wed, Mar 14, 2012 at 03:06:38PM +0800, Alex Jia wrote: On 03/14/2012 01:57 PM, Guannan Ren wrote: dom.cPUStats(True, 0) I'd like getVcpuStats or cpuStats function naming. Based on existing

[libvirt] [PATCH v2] python: add virDomainGetCPUStats python binding API

2012-03-14 Thread Guannan Ren
dom.getCPUStats(True, 0) [{'cpu_time': 92913537401L, 'system_time': 547000L, 'user_time': 31000L}] dom.getCPUStats(False, 0) [{'cpu_time': 39476858499L}, {'cpu_time': 10627048370L}, {'cpu_time': 21270945682L}, {'cpu_time': 21556420641L}] *generator.py Add a new

Re: [libvirt] Modified version of the libvirt-test-api wrapper

2012-03-14 Thread Guannan Ren
On 03/14/2012 06:45 PM, Daniel Veillard wrote: On Tue, Mar 13, 2012 at 11:05:31PM -0300, Lucas Meneghel Rodrigues wrote: Hi Guannan: I've worked on your first version of the libvirt-test-api wrapper for autotest. Could you please check if you like the modified version?

[libvirt] [PATCH] qemu: A typo which causes non-exsiting NIC detachment failed

2012-03-12 Thread Guannan Ren
--- src/qemu/qemu_hotplug.c | 14 +++--- 1 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/qemu/qemu_hotplug.c b/src/qemu/qemu_hotplug.c index 1e56354..e088a49 100644 --- a/src/qemu/qemu_hotplug.c +++ b/src/qemu/qemu_hotplug.c @@ -2081,13 +2081,6 @@

Re: [libvirt] [PATCH] qemu: A typo which causes non-exsiting NIC detachment failed

2012-03-12 Thread Guannan Ren
On 03/13/2012 03:24 AM, Laine Stump wrote: On 03/12/2012 11:50 AM, Guannan Ren wrote: --- src/qemu/qemu_hotplug.c | 14 +++--- 1 files changed, 7 insertions(+), 7 deletions(-) ACK (and I'll push it in a couple hours - I want to add some details to the commit log message) Thanks

Re: [libvirt] libvirt_tck autotest wrapper looks good, commited

2012-03-09 Thread Guannan Ren
On 03/09/2012 04:28 PM, Daniel Veillard wrote: On Fri, Mar 09, 2012 at 01:33:48PM +0800, Guannan Ren wrote: On 03/09/2012 01:40 AM, Lucas Meneghel Rodrigues wrote: Thanks Guannan: https://github.com/autotest/autotest/commit/ba4b748e7b9a9bfe7898a97cdccdc9b867d5321c Cheers, Lucas That's

Re: [libvirt] libvirt_tck autotest wrapper looks good, commited

2012-03-08 Thread Guannan Ren
will be sent to autotest mainling list, is that right? Guannan Ren -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

[libvirt] [PATCH] rpc: Fix VPATH building issue

2012-03-06 Thread Guannan Ren
The XDR routine .c file generated by rpcgen includes the corresponding Header file. however, the path in include directive of the header file is picked up based on the path of .x file. In the situation of VPATH Builds it will include full path of the header file rather than relative

Re: [libvirt] [PATCH] rpc: Fix VPATH building issue

2012-03-06 Thread Guannan Ren
On 03/07/2012 04:56 AM, Eric Blake wrote: On 03/06/2012 10:07 AM, Guannan Ren wrote: The XDR routine .c file generated by rpcgen includes the corresponding Header file. however, the path in include directive of the header file is picked up based on the path of .x file

[libvirt] [libvirt-TCK][PATCH] use 'raw' format as the format of backing file of qcow2 image

2012-02-28 Thread Guannan Ren
If we don't explicitly specify the format of backing file, it should use raw by default, if so, libvirt's security drivers should *not* grant access to the last.img file the guest should not see the last.img data. That is the purpose of testing. ---

Re: [libvirt] libvirt TCK wrapper for autotest review

2012-02-28 Thread Guannan Ren
On 02/24/2012 07:50 PM, Lucas Meneghel Rodrigues wrote: On 02/23/2012 12:27 PM, Guannan Ren wrote: Hi Lucas, Thanks for your these good modifications. There is one place I noticed where you output each testcase of *.t into a separate file with .tap extension. hence, it has a corresponding log

Re: [libvirt] libvirt TCK wrapper for autotest review

2012-02-23 Thread Guannan Ren
to check compared to just one log file. The rest of them is perfect for me. Guannan Ren On 02/23/2012 04:45 AM, Lucas Meneghel Rodrigues wrote: Hi guys, I was here looking at the autotest wrapper for libvirt TCK and then decided to work on it, as I had the review fresh

Re: [libvirt] libvirt TCK wrapper for autotest review

2012-02-23 Thread Guannan Ren
work go well is using TAP parser to parse the TAP file generated by TCK and show the results to webpage, but right now, parser in autotest doesn't support this idea as far as I know. Guannan Ren /// / -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com

[libvirt] [perl-Sys-Virt][PATCH] de-mortalize the return value from hv_delete

2012-02-22 Thread Guannan Ren
when calling block_stats() like $dom-block_stats(), it will reprot errors: Attempt to free unreferenced scalar: SV 0x2598498, Perl interpreter: 0x11a0010. Attempt to free unreferenced scalar: SV 0x258c498, Perl interpreter: 0x11a0010. This patch fix it. --- Virt.xs |1 + 1

[libvirt] [PATCH] Make virInitialize be called in multithreading environment

2012-02-15 Thread Guannan Ren
When initializing libvirt shared library, calling virOnce to make load hypervisor drivers and create thread local key only once. --- src/libvirt.c | 131 +++ src/util/threads-pthread.c |8 ++- 2 files changed, 64

Re: [libvirt] [test-API][PATCH] Add 3 APIs in snapshotAPI

2012-02-13 Thread Guannan Ren
On 02/13/2012 05:03 PM, Wayne Sun wrote: * new APIs get_parent(self, domname, snapname, flag = 0) children_num(self, domname, snapname, flag) children_names_list(self, domname, snapname, flag) the flag in children_num and children_names_list could be in 0-7, which is

Re: [libvirt] [PATCH] python: make other APIs share common {get, set}PyVirTypedParameter

2012-02-11 Thread Guannan Ren
On 02/11/2012 08:18 AM, Eric Blake wrote: On 02/10/2012 03:17 AM, Guannan Ren wrote: *libvirt_virDomainBlockStatsFlags *libvirt_virDomainGetSchedulerParameters *libvirt_virDomainGetSchedulerParametersFlags *libvirt_virDomainSetSchedulerParameters

[libvirt] [PATCH] python: make other APIs share common {get, set}PyVirTypedParameter

2012-02-10 Thread Guannan Ren
*libvirt_virDomainBlockStatsFlags *libvirt_virDomainGetSchedulerParameters *libvirt_virDomainGetSchedulerParametersFlags *libvirt_virDomainSetSchedulerParameters *libvirt_virDomainSetSchedulerParametersFlags *libvirt_virDomainSetBlkioParameters

Re: [libvirt] [PATCHv5] python: refactoring virTypedParameter conversion for NUMA tuning APIs

2012-02-09 Thread Guannan Ren
On 02/10/2012 07:22 AM, Eric Blake wrote: On 02/08/2012 09:29 PM, Guannan Ren wrote: On 02/09/2012 09:41 AM, Eric Blake wrote: From: Guannan Reng...@redhat.com *getPyVirTypedParameter *setPyVirTypedParameter *virDomainSetNumaParameters

Re: [libvirt] [test-API][PATCH] Add new APIs and fix problems in connectAPI

2012-02-08 Thread Guannan Ren
On 02/08/2012 04:28 PM, Wayne Sun wrote: * add 8 new APIs get_sys_info(self, flag = 0) get_memory_stats(self, cellNum, flag = 0) get_cpu_stats(self, cpuNum, flag = 0) is_alive(self) change_begin(self, flag = 0) change_commit(self, flag = 0)

[libvirt] [PATCH v4] python: refactoring virTypedParameter conversion for NUMA tuning APIs

2012-02-08 Thread Guannan Ren
*getPyVirTypedParameter *setPyVirTypedParameter *virDomainSetNumaParameters *virDomainGetNumaParameters --- python/libvirt-override-api.xml | 13 ++ python/libvirt-override.c | 385 +++ 2 files changed, 398

Re: [libvirt] [PATCH] cgroup:fix bug to keep --device-weights value persistent

2012-02-08 Thread Guannan Ren
On 02/08/2012 08:37 AM, Eric Blake wrote: On 02/02/2012 04:57 AM, Guannan Ren wrote: src/qemu/qemu_driver.c When run virsh blkiotune dom --device-weights /dev/sda,400 --config it couldn't be persistent after dom restart. The patch fix it. --- src/qemu/qemu_driver.c | 53

Re: [libvirt] [PATCHv5] python: refactoring virTypedParameter conversion for NUMA tuning APIs

2012-02-08 Thread Guannan Ren
*) virDomainPinVcpu, libvirt_virDomainPinVcpu, METH_VARARGS, NULL}, {(char *) virDomainPinVcpuFlags, libvirt_virDomainPinVcpuFlags, METH_VARARGS, NULL}, Thanks for these comments, ACK. Guannan Ren -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman

Re: [libvirt] segment fault from libvirtmod

2012-02-07 Thread Guannan Ren
On 02/07/2012 05:35 PM, Daniel P. Berrange wrote: On Mon, Feb 06, 2012 at 03:59:19PM +0100, Michal Privoznik wrote: On 06.02.2012 10:08, Guannan Ren wrote: Hi, The Makefile.am in python forget to add probes.o if WITH_DTRACE but after I added it and tried to connect

Re: [libvirt] [PATCH] pyhton: Don't link against libvirt_util.la

2012-02-07 Thread Guannan Ren
On 02/07/2012 08:41 PM, Michal Privoznik wrote: As we already link with libvirt.la which contains libvirt_utils.la. Double linking causes global symbols to be presented twice and thus confusion. This partially reverts c700613b8d463212d142c97108b7a2352e23e559 --- python/Makefile.am |2 --

[libvirt] segment fault from libvirtmod

2012-02-06 Thread Guannan Ren
() from /usr/lib64/libpython2.7.so.1.0 #13 0x003c6530e745 in Py_Main () from /usr/lib64/libpython2.7.so.1.0 #14 0x003c62a2169d in __libc_start_main () from /lib64/libc.so.6 #15 0x00400651 in _start () Guannan Ren -- libvir-list mailing list libvir-list

Re: [libvirt] [PATCH] cgroup:fix bug to keep --device-weights value persistent

2012-02-06 Thread Guannan Ren
ping :) On 02/02/2012 07:57 PM, Guannan Ren wrote: src/qemu/qemu_driver.c When run virsh blkiotune dom --device-weights /dev/sda,400 --config it couldn't be persistent after dom restart. The patch fix it. --- src/qemu/qemu_driver.c | 53

Re: [libvirt] [PATCH 1/2 v3] Python: Refactoring virTypedParameter conversion for NUMA tuning APIs

2012-02-04 Thread Guannan Ren
On 02/03/2012 01:48 AM, Eric Blake wrote: On 01/28/2012 07:53 AM, Guannan Ren wrote: *virDomainSetNumaParameters *virDomainGetNumaParameters --- python/Makefile.am |4 +- python/libvirt-override-api.xml | 13 ++ python/libvirt-override.c | 314

Re: [libvirt] [PATCH 1/2 v3] Python: Refactoring virTypedParameter conversion for NUMA tuning APIs

2012-02-03 Thread Guannan Ren
On 02/03/2012 01:48 AM, Eric Blake wrote: On 01/28/2012 07:53 AM, Guannan Ren wrote: *virDomainSetNumaParameters *virDomainGetNumaParameters --- python/Makefile.am |4 +- python/libvirt-override-api.xml | 13 ++ python/libvirt-override.c | 314

Re: [libvirt] [PATCH 1/2 v3] Python: Refactoring virTypedParameter conversion for NUMA tuning APIs

2012-02-02 Thread Guannan Ren
Could anyone please help to review these patchset? Thanks :) On 01/28/2012 10:53 PM, Guannan Ren wrote: *virDomainSetNumaParameters *virDomainGetNumaParameters --- python/Makefile.am |4 +- python/libvirt-override-api.xml | 13 ++ python/libvirt

Re: [libvirt] [test-API][PATCH 1/2] Add 2 new functions in storageAPI

2012-01-31 Thread Guannan Ren
) +except libvirt.libvirtError, e: +message = e.get_error_message() +code = e.get_error_code() +raise exception.LibvirtAPI(message, code) ACK Guannan Ren -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

[libvirt] [PATCH 1/2 v3] Python: Refactoring virTypedParameter conversion for NUMA tuning APIs

2012-01-28 Thread Guannan Ren
*virDomainSetNumaParameters *virDomainGetNumaParameters --- python/Makefile.am |4 +- python/libvirt-override-api.xml | 13 ++ python/libvirt-override.c | 314 +++ 3 files changed, 330 insertions(+), 1 deletions(-)

[libvirt] [PATCH 2/2 v3] Python: modify other functions to use {get, set}PyVirTypedParameter

2012-01-28 Thread Guannan Ren
*libvirt_virDomainBlockStatsFlags *libvirt_virDomainGetSchedulerParameters *libvirt_virDomainGetSchedulerParametersFlags *libvirt_virDomainSetSchedulerParameters *libvirt_virDomainSetSchedulerParametersFlags *libvirt_virDomainSetBlkioParameters

Re: [libvirt] [PATCH 1/2 v3] Python: Refactoring virTypedParameter conversion for NUMA tuning APIs

2012-01-28 Thread Guannan Ren
On 01/29/2012 01:39 PM, Alex Jia wrote: On 01/28/2012 10:53 PM, Guannan Ren wrote: *virDomainSetNumaParameters *virDomainGetNumaParameters --- python/Makefile.am |4 +- python/libvirt-override-api.xml | 13 ++ python/libvirt-override.c | 314

[libvirt] [PATCH v2] Add two NUMA tuning python bindings APIs

2012-01-19 Thread Guannan Ren
*virDomainSetNumaParameters *virDomainGetNumaParameters --- python/libvirt-override-api.xml | 13 +++ python/libvirt-override.c | 186 +++ 2 files changed, 199 insertions(+), 0 deletions(-) diff --git a/python/libvirt-override-api.xml

[libvirt] [PATCH] Add two NUMA tuning python bindings APIs

2012-01-16 Thread Guannan Ren
*virDomainSetNumaParameters *virDomainGetNumaParameters --- python/libvirt-override-api.xml | 13 +++ python/libvirt-override.c | 186 +++ 2 files changed, 199 insertions(+), 0 deletions(-) diff --git a/python/libvirt-override-api.xml

Re: [libvirt] [test-API][PATCH] Add domain event type Shutdown

2012-01-09 Thread Guannan Ren
), ( Paused, Migrated, IOError, Watchdog ), ( Unpaused, Migrated), ( Shutdown, Destroyed, Crashed, Migrated, Saved, Failed, Snapshot) +( Finished, ) ) return eventStrings[event][detail] After fixing it, ack and pushed. Guannan Ren

Re: [libvirt] [test-API][PATCH 1/2] Add test case get_cpu_shares.py for cpu scheduler info testing

2011-12-14 Thread Guannan Ren
On 12/14/2011 02:59 PM, Wayne Sun wrote: On 12/13/2011 11:45 AM, Nan Zhang wrote: * repos/domain/get_cpu_shares.py: get the value of cpu_shares property of the guest. --- lib/domainAPI.py |2 +- repos/domain/get_cpu_shares.py | 117

Re: [libvirt] [test-API][PATCH 2/2] Add test case set_cpu_shares.py for setting cpu scheduler info

2011-12-14 Thread Guannan Ren
On 12/14/2011 02:59 PM, Wayne Sun wrote: On 12/13/2011 11:45 AM, Nan Zhang wrote: * repos/domain/set_cpu_shares.py: set the value of cpu_shares property of the guest. --- repos/domain/set_cpu_shares.py | 121 1 files changed, 121 insertions(+),

Re: [libvirt] [test-API][PATCH] Update clean part for cases

2011-11-22 Thread Guannan Ren
On 11/21/2011 03:23 PM, Wayne Sun wrote: * add clean function for missing ones * clean the system configuration files which been touched --- repos/domain/balloon_memory.py |2 ++ repos/domain/cpu_topology.py |5 + repos/domain/ownership_test.py | 10

Re: [libvirt] [test-API][PATCH 2/3] clean keyword update in libvirt-test-api, mapper, proxy part

2011-11-10 Thread Guannan Ren
On 11/10/2011 11:25 AM, Guannan Sun wrote: NACK - Original Message - From: Guannan Reng...@redhat.com To: libvir-list@redhat.com Sent: Wednesday, November 9, 2011 12:38:38 PM Subject: [libvirt] [test-API][PATCH 2/3] clean keyword update in libvirt-test-api, mapper, proxy part ---

[libvirt] [test-API][PATCH 1/2] update env_clear for new way of function reference

2011-11-10 Thread Guannan Ren
--- env_clear.py | 23 ++- 1 files changed, 10 insertions(+), 13 deletions(-) diff --git a/env_clear.py b/env_clear.py index 302ff62..5e78ab5 100644 --- a/env_clear.py +++ b/env_clear.py @@ -14,7 +14,7 @@ # distribution and at http://www.gnu.org/licenses. # # This module

[libvirt] [test-API][PATCH 2/2] update proxy and mapper part for cleanup using new reference

2011-11-10 Thread Guannan Ren
--- mapper.py | 19 +++ proxy.py | 11 +-- 2 files changed, 28 insertions(+), 2 deletions(-) diff --git a/mapper.py b/mapper.py index affc510..f0b675a 100644 --- a/mapper.py +++ b/mapper.py @@ -55,3 +55,22 @@ class Mapper(object): prev_testcases_params =

[libvirt] [test-API][PATCH 3/3] update parser to add clean keyword

2011-11-08 Thread Guannan Ren
--- parser.py | 21 +++-- 1 files changed, 15 insertions(+), 6 deletions(-) diff --git a/parser.py b/parser.py index 085a1f2..883de89 100644 --- a/parser.py +++ b/parser.py @@ -391,12 +391,21 @@ class CaseFileParser(object): if len(tripped_caselist) == 2 and

[libvirt] [test-API][PATCH 1/3] add new clean keyword to clean environment after each testcase

2011-11-08 Thread Guannan Ren
testcase1 option1 avalue option2 bvalue clean testcase2 option1 cvalue option2 dvalue clean --- generator.py | 44 1 files changed, 32 insertions(+), 12 deletions(-) diff --git a/generator.py

[libvirt] [test-API][PATCH 2/3] clean keyword update in libvirt-test-api, mapper, proxy part

2011-11-08 Thread Guannan Ren
--- libvirt-test-api.py |7 +++ mapper.py | 24 +++- proxy.py| 13 + 3 files changed, 35 insertions(+), 9 deletions(-) diff --git a/libvirt-test-api.py b/libvirt-test-api.py index 8a4bacd..171e13c 100644 --- a/libvirt-test-api.py

Re: [libvirt] [test-API][PATCH 1/5] Remove remote_guest_define function in migrate

2011-10-13 Thread Guannan Ren
) env_clean(src, dst, srcdom, dstdom, target_machine, guestname, logger) return 1 - try: if(migflags VIR_MIGRATE_PEER2PEER): logger.info(use migrate_to_uri() API to migrate) ACK and pushed. Guannan Ren -- libvir-list mailing list

Re: [libvirt] [test-API][PATCH 2/5] Add new variable static_uuid into env.cfg

2011-10-13 Thread Guannan Ren
need to change define.py as well as other domain related testcases to use the uuid in env.cfg. It's better to add an additional option to theses testcases, such as uuid. ACK and pushed. Guannan Ren -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com

Re: [libvirt] [test-API][PATCH 5/5] Update the migration case conf file

2011-10-13 Thread Guannan Ren
+username +$target_user +password +$target_password domain:start guestname -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list ACK and pushed Guannan Ren -- libvir-list mailing list libvir-list@redhat.com https

Re: [libvirt] [test-API][PATCH 3/5] Update add_option_value function in parser

2011-10-13 Thread Guannan Ren
to modify the last testcase instead of all of the previous. It solved the parsing bug which two or more testcases with the same name but different options caused. ACK and pushed. Guannan Ren -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo

Re: [libvirt] [test-API][PATCH 4/5] Add new element uuid in xmlgenerator

2011-10-13 Thread Guannan Ren
') if params.has_key('memory'): ACK and pushed Guannan Ren -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] [test-API][PATCH v4] Add test case update_devflag.py for update device flag

2011-09-27 Thread Guannan Ren
On 09/26/2011 05:58 PM, Nan Zhang wrote: --- repos/domain/update_devflag.py | 276 1 files changed, 276 insertions(+), 0 deletions(-) create mode 100644 repos/domain/update_devflag.py diff --git a/repos/domain/update_devflag.py

Re: [libvirt] [test-API][PATCH v2 2/4] Add libvirtd restart test case

2011-09-15 Thread Guannan Ren
restart % guestname) + +return 0 + +def restart_clean(params): + clean testing environment +pass + -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list ACK and pushed with this fixed. Guannan Ren -- libvir-list mailing list

Re: [libvirt] [test-API][PATCH v2 3/4] Add libvirtd upstart test case

2011-09-15 Thread Guannan Ren
'. +if ret !=0: Same as above. +logger.error(failed to set chkconfig) -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list ACK with these code problem fixed. Guannan Ren -- libvir-list mailing list libvir-list@redhat.com https

Re: [libvirt] [test-API][PATCH v2 4/4] Add qemu_hang test case under libvirtd

2011-09-15 Thread Guannan Ren
On 09/14/2011 06:31 PM, Wayne Sun wrote: * repos/libvirtd/qemu_hang.py qemu process get hang should not cause libvirtd hang or dead --- repos/libvirtd/qemu_hang.py | 142 +++ 1 files changed, 142 insertions(+), 0 deletions(-) create mode

Re: [libvirt] [test-API][PATCH v2] Add test case for start domain on nfs storage

2011-09-15 Thread Guannan Ren
and pushed with these small modification. Guannan Ren -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] [test-API][PATCH] Fix typos for existing problems

2011-09-15 Thread Guannan Ren
and pushed Guannan Ren -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] [test-API][PATCH v4] Add test module ownership_test

2011-09-15 Thread Guannan Ren
)): +logger.error(out[i]) + +filepath = TEMP_FILE +elif use_nfs == 'disable': +filepath = SAVE_FILE + +if os.path.exists(filepath): +os.remove(filepath) + ACK and pushed Guannan Ren -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo

<    3   4   5   6   7   8   9   >