Re: [libvirt] [Qemu-devel] virtio serial device problem

2013-05-09 Thread Li Zhang
On 2013年05月08日 23:53, fred.kon...@greensocs.com wrote: On 05/07/2013 07:50 PM, Paolo Bonzini wrote: Il 07/05/2013 09:20, Li Zhang ha scritto: Hi all, Hi, When we use the latest version of QEMU to build ovirt, we get this error reported from libvirt. What QEMU commit is this?

Re: [libvirt] [Qemu-devel] virtio serial device problem

2013-05-09 Thread Alexey Kardashevskiy
On 05/09/2013 04:07 PM, Li Zhang wrote: On 2013年05月08日 23:53, fred.kon...@greensocs.com wrote: On 05/07/2013 07:50 PM, Paolo Bonzini wrote: Il 07/05/2013 09:20, Li Zhang ha scritto: Hi all, Hi, When we use the latest version of QEMU to build ovirt, we get this error reported from libvirt.

Re: [libvirt] [Qemu-devel] virtio serial device problem

2013-05-09 Thread Li Zhang
On 2013年05月09日 14:31, Alexey Kardashevskiy wrote: On 05/09/2013 04:07 PM, Li Zhang wrote: On 2013年05月08日 23:53, fred.kon...@greensocs.com wrote: On 05/07/2013 07:50 PM, Paolo Bonzini wrote: Il 07/05/2013 09:20, Li Zhang ha scritto: Hi all, Hi, When we use the latest version of QEMU to

Re: [libvirt] [PATCH v3 09/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/lxc/*

2013-05-09 Thread Daniel P. Berrange
On Wed, May 08, 2013 at 04:01:04PM -0600, Eric Blake wrote: On 05/03/2013 08:53 AM, Michal Privoznik wrote: --- src/lxc/lxc_cgroup.c | 3 +-- src/lxc/lxc_conf.c | 36 +--- src/lxc/lxc_container.c | 18 --

Re: [libvirt] [PATCH 21/40] Simplify the Xen domain get XML driver method

2013-05-09 Thread Daniel P. Berrange
On Wed, May 08, 2013 at 03:56:14PM -0600, Jim Fehlig wrote: Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com The xenUnifiedDomainGetXMLDesc driver can assume that the XM and XenD drivers are always present Signed-off-by: Daniel P. Berrange berra...@redhat.com

Re: [libvirt] [PATCH 2/4] docs: Update description of SMBIOS fields

2013-05-09 Thread Martin Kletzander
On 04/30/2013 08:19 PM, John Ferlan wrote: --- docs/formatdomain.html.in | 48 +++ 1 file changed, 40 insertions(+), 8 deletions(-) ACK, also looks much nicer, Martin -- libvir-list mailing list libvir-list@redhat.com

Re: [libvirt] [PATCH 1/4] docs: Fix syntax in sysinfo description

2013-05-09 Thread Martin Kletzander
On 04/30/2013 08:19 PM, John Ferlan wrote: --- docs/formatdomain.html.in | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/formatdomain.html.in b/docs/formatdomain.html.in index f325c3c..017d2b9 100644 --- a/docs/formatdomain.html.in +++

[libvirt] [PATCH] don't mention disk controllers in generic controller errors

2013-05-09 Thread Ján Tomko
The controller element supports non-disk controller types too. https://bugzilla.redhat.com/show_bug.cgi?id=960958 --- src/conf/domain_conf.c | 2 +- src/qemu/qemu_driver.c | 4 ++-- src/qemu/qemu_hotplug.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git

[libvirt] [libvirt PATCH 0/8] Fixes for cgroup setting

2013-05-09 Thread Osier Yang
1/8 ~ 5/8 are refactorings, real fixes are 6/8, 7/8. 8/8 is RFC. Osier Yang (8): qemu: Abstract the code for blkio controller setting into a helper qemu: Abstract code for memory controller setting into a helper qemu: Abstract code for devices controller setting into a helper qemu:

[libvirt] [PATCH 2/8] qemu: Abstract code for memory controller setting into a helper

2013-05-09 Thread Osier Yang
--- src/qemu/qemu_cgroup.c | 120 - 1 file changed, 68 insertions(+), 52 deletions(-) diff --git a/src/qemu/qemu_cgroup.c b/src/qemu/qemu_cgroup.c index 6772ab2..8c4bc0f 100644 --- a/src/qemu/qemu_cgroup.c +++ b/src/qemu/qemu_cgroup.c @@ -413,6

[libvirt] [PATCH 4/8] qemu: Abstract code for cpuset controller setting into a helper

2013-05-09 Thread Osier Yang
--- src/qemu/qemu_cgroup.c | 73 -- 1 file changed, 47 insertions(+), 26 deletions(-) diff --git a/src/qemu/qemu_cgroup.c b/src/qemu/qemu_cgroup.c index 057ddaf..f384b98 100644 --- a/src/qemu/qemu_cgroup.c +++ b/src/qemu/qemu_cgroup.c @@ -584,6

[libvirt] [PATCH 1/8] qemu: Abstract the code for blkio controller setting into a helper

2013-05-09 Thread Osier Yang
--- src/qemu/qemu_cgroup.c | 90 -- 1 file changed, 50 insertions(+), 40 deletions(-) diff --git a/src/qemu/qemu_cgroup.c b/src/qemu/qemu_cgroup.c index 9c45b76..6772ab2 100644 --- a/src/qemu/qemu_cgroup.c +++ b/src/qemu/qemu_cgroup.c @@ -365,6

[libvirt] [PATCH 3/8] qemu: Abstract code for devices controller setting into a helper

2013-05-09 Thread Osier Yang
--- src/qemu/qemu_cgroup.c | 195 +++-- 1 file changed, 107 insertions(+), 88 deletions(-) diff --git a/src/qemu/qemu_cgroup.c b/src/qemu/qemu_cgroup.c index 8c4bc0f..057ddaf 100644 --- a/src/qemu/qemu_cgroup.c +++ b/src/qemu/qemu_cgroup.c @@ -479,6

[libvirt] [PATCH 7/8] qemu: Prohibit getting the numa parameters if mode is not strict

2013-05-09 Thread Osier Yang
I don't see any reason to getting the numa parameters if mode is not strict, as long as setNumaParameters doesn't allow to set nodeset if the mode is not strict, and cpuset.mems only understand strict mode. Things could be changed if we support to get numa parameters with libnuma one day, but

Re: [libvirt] [RFC PATCH 8/8] qemu: Set cpuset.mems even if the numatune mode is not strict

2013-05-09 Thread Osier Yang
[cC Hu Tao] On 09/05/13 18:22, Osier Yang wrote: When the numatune memory mode is not strict, the cpuset.mems inherits the parent's setting, which causes problem like: % virsh dumpxml rhel6_local | grep interleave -2 vcpu placement='static'2/vcpu numatune memory mode='interleave'

[libvirt] [PATCH 6/8] qemu: Set cpuset.cpus for domain process

2013-05-09 Thread Osier Yang
When either cpuset of vcpu is specified, or the placement of vcpu is auto, only setting the cpuset.mems might cause the guest starting to fail. E.g. (placement of both vcpu and numatune is auto): 1) Related XMLs vcpu placement='auto'4/vcpu numatune memory mode='strict' placement='auto'/

[libvirt] [RFC PATCH 8/8] qemu: Set cpuset.mems even if the numatune mode is not strict

2013-05-09 Thread Osier Yang
When the numatune memory mode is not strict, the cpuset.mems inherits the parent's setting, which causes problem like: % virsh dumpxml rhel6_local | grep interleave -2 vcpu placement='static'2/vcpu numatune memory mode='interleave' nodeset='1-2'/ /numatune os % cat /proc/3713/status

Re: [libvirt] [PATCH] don't mention disk controllers in generic controller errors

2013-05-09 Thread Osier Yang
On 09/05/13 18:08, Ján Tomko wrote: The controller element supports non-disk controller types too. https://bugzilla.redhat.com/show_bug.cgi?id=960958 ACK -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

[libvirt] [PATCH 5/8] qemu: Abstract code for the cpu controller setting into a helper

2013-05-09 Thread Osier Yang
--- src/qemu/qemu_cgroup.c | 63 ++ 1 file changed, 38 insertions(+), 25 deletions(-) diff --git a/src/qemu/qemu_cgroup.c b/src/qemu/qemu_cgroup.c index f384b98..0e00b47 100644 --- a/src/qemu/qemu_cgroup.c +++ b/src/qemu/qemu_cgroup.c @@ -629,6

Re: [libvirt] [PATCH 6/8] qemu: Set cpuset.cpus for domain process

2013-05-09 Thread Osier Yang
Hi, Doug Do you think if this fixes your problem? https://www.redhat.com/archives/libvirt-users/2013-January/msg00071.html Osier On 09/05/13 18:22, Osier Yang wrote: When either cpuset of vcpu is specified, or the placement of vcpu is auto, only setting the cpuset.mems might cause the guest

Re: [libvirt] [PATCH 4/4] Need better validation of sysinfo uuid

2013-05-09 Thread Martin Kletzander
On 04/30/2013 08:19 PM, John Ferlan wrote: If the sysinfo system table 'uuid' field is improperly formatted, then qemu will fail to start the guest with the error: virsh start dom error: Failed to start domain dom error: internal error process exited while connecting to monitor: Invalid

Re: [libvirt] [PATCH v3 09/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/lxc/*

2013-05-09 Thread Michal Privoznik
On 09.05.2013 10:15, Daniel P. Berrange wrote: On Wed, May 08, 2013 at 04:01:04PM -0600, Eric Blake wrote: On 05/03/2013 08:53 AM, Michal Privoznik wrote: --- src/lxc/lxc_cgroup.c | 3 +-- src/lxc/lxc_conf.c | 36 +--- src/lxc/lxc_container.c | 18

[libvirt] [PATCH] conf: don't crash on a tpm device with no backends

2013-05-09 Thread Ján Tomko
Print an error instead of crashing when a TPM device without a backend is specified. https://bugzilla.redhat.com/show_bug.cgi?id=961252 --- src/conf/domain_conf.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index d55ce6b..eb579c6

Re: [libvirt] [PATCH v3 34/34] Introduce syntax-check rule to prefer VIR_STRDUP over strdup

2013-05-09 Thread Michal Privoznik
On 07.05.2013 05:54, Eric Blake wrote: On 05/03/2013 08:53 AM, Michal Privoznik wrote: --- cfg.mk | 8 1 file changed, 8 insertions(+) diff --git a/cfg.mk b/cfg.mk index 1d63bbd..4ed2c3a 100644 --- a/cfg.mk +++ b/cfg.mk @@ -387,6 +387,11 @@ sc_prohibit_asprintf: halt='use

Re: [libvirt] [PATCH] conf: don't crash on a tpm device with no backends

2013-05-09 Thread Osier Yang
On 09/05/13 18:36, Ján Tomko wrote: Print an error instead of crashing when a TPM device without a backend is specified. https://bugzilla.redhat.com/show_bug.cgi?id=961252 --- src/conf/domain_conf.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/src/conf/domain_conf.c

Re: [libvirt] [PATCH] conf: don't crash on a tpm device with no backends

2013-05-09 Thread Daniel P. Berrange
On Thu, May 09, 2013 at 12:36:37PM +0200, Ján Tomko wrote: Print an error instead of crashing when a TPM device without a backend is specified. https://bugzilla.redhat.com/show_bug.cgi?id=961252 --- src/conf/domain_conf.c | 6 ++ 1 file changed, 6 insertions(+) diff --git

Re: [libvirt] [PATCH v3 09/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/lxc/*

2013-05-09 Thread Daniel P. Berrange
On Thu, May 09, 2013 at 12:31:14PM +0200, Michal Privoznik wrote: On 09.05.2013 10:15, Daniel P. Berrange wrote: On Wed, May 08, 2013 at 04:01:04PM -0600, Eric Blake wrote: On 05/03/2013 08:53 AM, Michal Privoznik wrote: --- src/lxc/lxc_cgroup.c | 3 +-- src/lxc/lxc_conf.c |

Re: [libvirt] [PATCH v3 09/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/lxc/*

2013-05-09 Thread Michal Privoznik
On 09.05.2013 12:49, Daniel P. Berrange wrote: On Thu, May 09, 2013 at 12:31:14PM +0200, Michal Privoznik wrote: On 09.05.2013 10:15, Daniel P. Berrange wrote: On Wed, May 08, 2013 at 04:01:04PM -0600, Eric Blake wrote: On 05/03/2013 08:53 AM, Michal Privoznik wrote: ---

Re: [libvirt] [PATCH v3 09/34] Adapt to VIR_STRDUP and VIR_STRNDUP in src/lxc/*

2013-05-09 Thread Martin Kletzander
On 05/09/2013 12:53 PM, Michal Privoznik wrote: On 09.05.2013 12:49, Daniel P. Berrange wrote: On Thu, May 09, 2013 at 12:31:14PM +0200, Michal Privoznik wrote: On 09.05.2013 10:15, Daniel P. Berrange wrote: On Wed, May 08, 2013 at 04:01:04PM -0600, Eric Blake wrote: On 05/03/2013 08:53 AM,

Re: [libvirt] [PATCH 3/4] Validate the bios_date format for sysinfo

2013-05-09 Thread Martin Kletzander
On 04/30/2013 08:19 PM, John Ferlan wrote: --- src/conf/domain_conf.c | 24 1 file changed, 24 insertions(+) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index a8b5dfd..43273f8 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@

Re: [libvirt] [PATCH 3/4] Validate the bios_date format for sysinfo

2013-05-09 Thread John Ferlan
On 05/09/2013 06:59 AM, Martin Kletzander wrote: On 04/30/2013 08:19 PM, John Ferlan wrote: --- src/conf/domain_conf.c | 24 1 file changed, 24 insertions(+) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index a8b5dfd..43273f8 100644 ---

Re: [libvirt] [PATCH 24/40] Simplify the Xen domain start driver method

2013-05-09 Thread Daniel P. Berrange
On Wed, May 08, 2013 at 04:40:04PM -0600, Jim Fehlig wrote: Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Directly call either the XenD or XM driver when starting a persistent domain Signed-off-by: Daniel P. Berrange berra...@redhat.com ---

[libvirt] virsh edit failed to take effect on KVM

2013-05-09 Thread Gonglei (Arei)
Hi all, we use the command virsh edit to modify the VM configuration information online on KVM Platform(libvirt-1.0.0 and qemu-1.4), but it does not take effect after reboot. However, it works fine on Xen Platform. for an example,a VM is running with the following configuration

Re: [libvirt] virsh edit failed to take effect on KVM

2013-05-09 Thread Daniel P. Berrange
On Thu, May 09, 2013 at 11:49:05AM +, Gonglei (Arei) wrote: Hi all, we use the command virsh edit to modify the VM configuration information online on KVM Platform(libvirt-1.0.0 and qemu-1.4), but it does not take effect after reboot. However, it works fine on Xen Platform.

Re: [libvirt] [PATCH 29/40] Simplify the Xen domain stats/peek / node memory driver methods

2013-05-09 Thread Daniel P. Berrange
On Wed, May 08, 2013 at 05:33:13PM -0600, Jim Fehlig wrote: Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Make the Xen domain stats / peek and node memory driver methods unconditionally call the sub-drivers which are guaranteed to be open. Signed-off-by:

Re: [libvirt] [PATCH v3 00/34] Introduce VIR_STRDUP

2013-05-09 Thread Michal Privoznik
On 03.05.2013 16:53, Michal Privoznik wrote: Previously this aimed on dropping OOM report from almost everywhere (v1), then just prepare the ground (v2). Now, it just aims on introducing VIR_STRDUP and VIR_STRNDUP which do report OOM error. This will cause rebase conflicts, for sure. Sorry.

[libvirt] [PATCH v2 0/2] don't crash on a tpm device with no backends

2013-05-09 Thread Ján Tomko
v2: added tests v1: https://www.redhat.com/archives/libvir-list/2013-May/msg00651.html Ján Tomko (2): tests: files named '.*-invalid.xml' should fail validation conf: don't crash on a tpm device with no backends src/conf/domain_conf.c | 6 +

[libvirt] [PATCH v2 1/2] tests: files named '.*-invalid.xml' should fail validation

2013-05-09 Thread Ján Tomko
Currently, using an invalid XML in tests fails, because the schema test expects all of them to be valid. Treat files with -invalid.xml suffix as invalid and expect them to fail validation. --- tests/schematestutils.sh | 12 1 file changed, 12 insertions(+) diff --git

[libvirt] [PATCH v2 2/2] conf: don't crash on a tpm device with no backends

2013-05-09 Thread Ján Tomko
Print an error instead of crashing when a TPM device without a backend is specified. Add a test for tpm device with no backend, which should fail with a parse error. https://bugzilla.redhat.com/show_bug.cgi?id=961252 --- src/conf/domain_conf.c | 6 +

Re: [libvirt] [PATCH v2 1/2] tests: files named '.*-invalid.xml' should fail validation

2013-05-09 Thread Daniel P. Berrange
On Thu, May 09, 2013 at 02:18:12PM +0200, Ján Tomko wrote: Currently, using an invalid XML in tests fails, because the schema test expects all of them to be valid. Treat files with -invalid.xml suffix as invalid and expect them to fail validation. --- tests/schematestutils.sh | 12

Re: [libvirt] [PATCH v2 2/2] conf: don't crash on a tpm device with no backends

2013-05-09 Thread Daniel P. Berrange
On Thu, May 09, 2013 at 02:18:13PM +0200, Ján Tomko wrote: Print an error instead of crashing when a TPM device without a backend is specified. Add a test for tpm device with no backend, which should fail with a parse error. https://bugzilla.redhat.com/show_bug.cgi?id=961252 ---

Re: [libvirt] [PATCH v2 2/2] conf: don't crash on a tpm device with no backends

2013-05-09 Thread Ján Tomko
On 05/09/2013 02:20 PM, Daniel P. Berrange wrote: On Thu, May 09, 2013 at 02:18:13PM +0200, Ján Tomko wrote: Print an error instead of crashing when a TPM device without a backend is specified. Add a test for tpm device with no backend, which should fail with a parse error.

Re: [libvirt] [PATCH] iscsi: don't leak portal string when starting a pool

2013-05-09 Thread Ján Tomko
On 05/08/2013 09:31 PM, Eric Blake wrote: On 05/07/2013 02:02 AM, Ján Tomko wrote: --- src/storage/storage_backend_iscsi.c | 1 + 1 file changed, 1 insertion(+) ACK. Thanks, I've pushed it now. Jan -- libvir-list mailing list libvir-list@redhat.com

Re: [libvirt] [PATCH] don't mention disk controllers in generic controller errors

2013-05-09 Thread Ján Tomko
On 05/09/2013 12:25 PM, Osier Yang wrote: On 09/05/13 18:08, Ján Tomko wrote: The controller element supports non-disk controller types too. https://bugzilla.redhat.com/show_bug.cgi?id=960958 ACK Thank you, it's pushed now. Jan -- libvir-list mailing list libvir-list@redhat.com

[libvirt] [PATCH] Cope with missing swap cgroup controls

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com It is possible to build a kernel without swap cgroup controls present. This causes a fatal error when querying memory parameters. Treat missing swap controls as meaning unlimited. The fatal error remains if the user tries to actually change the limit.

[libvirt] [PATCH v2 00/11] Refactor Xen driver to support ACL work

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com The Xen driver currently is a really horrible mess, in particular with the way iterates over sub-drivers calling each one in turn, until one magically works. For each operation there is always a clear rule for which sub-driver must be used. Thus

[libvirt] [PATCH 01/11] Convert Xen domain lookup driver methods to use virDomainDefPtr

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Introduce use of a virDomainDefPtr in the domain lookup APIs to simplify introduction of ACL security checks. The virDomainPtr cannot be safely used, since the app may have supplied mis-matching name/uuid/id fields. eg the name points to domain X,

[libvirt] [PATCH 07/11] Convert Xen domain device hotplug driver methods to use virDomainDefPtr

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Introduce use of a virDomainDefPtr in the domain hotplug APIs to simplify introduction of ACL security checks. The virDomainPtr cannot be safely used, since the app may have supplied mis-matching name/uuid/id fields. eg the name points to domain X,

[libvirt] [PATCH 06/11] Convert Xen domain VCPU driver methods to use virDomainDefPtr

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Introduce use of a virDomainDefPtr in the domain VCPU APIs to simplify introduction of ACL security checks. The virDomainPtr cannot be safely used, since the app may have supplied mis-matching name/uuid/id fields. eg the name points to domain X, while

[libvirt] [PATCH 05/11] Convert Xen domain start/migration APIs to use virDomainDefPtr

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Introduce use of a virDomainDefPtr in the domain migrate start APIs to simplify introduction of ACL security checks. The virDomainPtr cannot be safely used, since the app may have supplied mis-matching name/uuid/id fields. eg the name points to domain

[libvirt] [PATCH 03/11] Convert Xen domain property driver methods to use virDomainDefPtr

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Introduce use of a virDomainDefPtr in the domain property APIs to simplify introduction of ACL security checks. The virDomainPtr cannot be safely used, since the app may have supplied mis-matching name/uuid/id fields. eg the name points to domain X,

[libvirt] [PATCH 11/11] Convert Xen domain core dump driver methods to use virDomainDefPtr

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Introduce use of a virDomainDefPtr in the domain coredump APIs to simplify introduction of ACL security checks. The virDomainPtr cannot be safely used, since the app may have supplied mis-matching name/uuid/id fields. eg the name points to domain X,

Re: [libvirt] [PATCH 01/11] Convert Xen domain lookup driver methods to use virDomainDefPtr

2013-05-09 Thread Michal Privoznik
On 09.05.2013 14:59, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Introduce use of a virDomainDefPtr in the domain lookup APIs to simplify introduction of ACL security checks. The virDomainPtr cannot be safely used, since the app may have supplied mis-matching

[libvirt] [PATCH 10/11] Convert Xen domain stats/peek driver methods to use virDomainDefPtr

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Introduce use of a virDomainDefPtr in the domain stats peek APIs to simplify introduction of ACL security checks. The virDomainPtr cannot be safely used, since the app may have supplied mis-matching name/uuid/id fields. eg the name points to domain X,

[libvirt] [PATCH] Disable some URI tests on older libxml2

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Older versions of libxml2 could not correctly parse certain URIs. This causes test failures. There's nothing libvirt can do about this, so disable the problem tests on old libxml2 versions Signed-off-by: Daniel P. Berrange berra...@redhat.com ---

[libvirt] [PATCH] Fix build of python bindings on Python 2.4

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com The PyDict_Next method on Python = 2.4 used 'int' instead of Py_ssize_t for the 'pos' parameter Signed-off-by: Daniel P. Berrange berra...@redhat.com --- python/libvirt-override.c | 4 1 file changed, 4 insertions(+) diff --git

[libvirt] [PATCH 02/11] Convert Xen domain lifecycle driver methods to use virDomainDefPtr

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Introduce use of a virDomainDefPtr in the domain lifecycle APIs to simplify introduction of ACL security checks. The virDomainPtr cannot be safely used, since the app may have supplied mis-matching name/uuid/id fields. eg the name points to domain X,

[libvirt] [PATCH 04/11] Convert Xen domain managed save driver methods to use virDomainDefPtr

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Introduce use of a virDomainDefPtr in the domain save APIs to simplify introduction of ACL security checks. The virDomainPtr cannot be safely used, since the app may have supplied mis-matching name/uuid/id fields. eg the name points to domain X, while

[libvirt] [PATCH] Replace 'goto err' with 'goto cleanup' in udev interface driver

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com The udev interface driver did not follow standard naming convention for goto labels. Signed-off-by: Daniel P. Berrange berra...@redhat.com --- src/interface/interface_backend_udev.c | 32 1 file changed, 16

[libvirt] [PATCH] Replace 'goto clean' with 'goto cleanup' in apparmor code

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Some of the apparmor code files did not follow the normal goto label naming pratices Signed-off-by: Daniel P. Berrange berra...@redhat.com --- src/security/security_apparmor.c | 34 ++--- src/security/virt-aa-helper.c| 66

Re: [libvirt] [PATCH] Disable some URI tests on older libxml2

2013-05-09 Thread Michal Privoznik
On 09.05.2013 15:01, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Older versions of libxml2 could not correctly parse certain URIs. This causes test failures. There's nothing libvirt can do about this, so disable the problem tests on old libxml2 versions

[libvirt] [PATCH 09/11] Convert Xen domain scheduler driver methods to use virDomainDefPtr

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Introduce use of a virDomainDefPtr in the domain scheduler APIs to simplify introduction of ACL security checks. The virDomainPtr cannot be safely used, since the app may have supplied mis-matching name/uuid/id fields. eg the name points to domain X,

[libvirt] [PATCH 08/11] Convert Xen domain autostart driver methods to use virDomainDefPtr

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Introduce use of a virDomainDefPtr in the domain autostart APIs to simplify introduction of ACL security checks. The virDomainPtr cannot be safely used, since the app may have supplied mis-matching name/uuid/id fields. eg the name points to domain X,

Re: [libvirt] [PATCH 01/11] Convert Xen domain lookup driver methods to use virDomainDefPtr

2013-05-09 Thread Daniel P. Berrange
On Thu, May 09, 2013 at 03:01:42PM +0200, Michal Privoznik wrote: On 09.05.2013 14:59, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Introduce use of a virDomainDefPtr in the domain lookup APIs to simplify introduction of ACL security checks. The virDomainPtr

Re: [libvirt] [PATCH] Fix build of python bindings on Python 2.4

2013-05-09 Thread Michal Privoznik
On 09.05.2013 15:01, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com The PyDict_Next method on Python = 2.4 used 'int' instead of Py_ssize_t for the 'pos' parameter Signed-off-by: Daniel P. Berrange berra...@redhat.com --- python/libvirt-override.c | 4 1

[libvirt] [PATCH] Skip virNWFilterTechDriver when validating API naming

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com The virNWFilterTechDriver struct is an internal only driver API with no public API equivalent. It should be skipped by the 'check-driverimpls' test case Signed-off-by: Daniel P. Berrange berra...@redhat.com --- src/check-driverimpls.pl | 3 ++- 1

[libvirt] [PATCH] Fix naming of methods in ESX storage backends to follow public APIs

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com The previous update of method naming missed the ESX storage backend files. Update them is that the driver impl methods follow the naming of the public API but with s/vir/esx/ Signed-off-by: Daniel P. Berrange berra...@redhat.com ---

[libvirt] [PATCH] Replace list of driver source files with variables

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Update the DRIVER_SOURCE_FILES variable to reference the other various XXX_SOURCES variables, instead of duplicating the filename lists. This results in a bunch of extra files being processed, but the test scripts can easily skip those Signed-off-by:

Re: [libvirt] [PATCH] Replace 'goto err' with 'goto cleanup' in udev interface driver

2013-05-09 Thread Michal Privoznik
On 09.05.2013 15:02, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com The udev interface driver did not follow standard naming convention for goto labels. Signed-off-by: Daniel P. Berrange berra...@redhat.com --- src/interface/interface_backend_udev.c | 32

Re: [libvirt] [PATCH] Replace 'goto clean' with 'goto cleanup' in apparmor code

2013-05-09 Thread Michal Privoznik
On 09.05.2013 15:02, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Some of the apparmor code files did not follow the normal goto label naming pratices Signed-off-by: Daniel P. Berrange berra...@redhat.com --- src/security/security_apparmor.c | 34

[libvirt] [PATCH 00/19] Support for access control

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com This series (which depends on the Xen refactoring patches) adds support for access control checks on all APIs that run inside libvirtd. The first patch defines the basic objects which can be checked and the permissions associated with each object. In

[libvirt] [PATCH 11/19] Add ACL checks into the Xen driver

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Insert calls to the ACL checking APIs in all Xen driver entrypoints. Signed-off-by: Daniel P. Berrange berra...@redhat.com --- src/xen/xen_driver.c | 217 +-- 1 file changed, 209 insertions(+), 8

[libvirt] [PATCH 06/19] Add ACL annotations to all RPC messages

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Introduce annotations to all RPC messages to declare what access control checks are required. There are two new annotations defined: @acl: object:permission @acl: object:permission:flagname Declare the access control requirements for the API. May

[libvirt] [PATCH 12/19] Add ACL checks into the libxl driver

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Insert calls to the ACL checking APIs in all libxl driver entrypoints. Signed-off-by: Daniel P. Berrange berra...@redhat.com --- src/libxl/libxl_driver.c | 187 ++- 1 file changed, 184 insertions(+), 3

[libvirt] [PATCH 14/19] Add ACL checks into the network driver

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Insert calls to the ACL checking APIs in all network driver entrypoints. Signed-off-by: Daniel P. Berrange berra...@redhat.com --- src/network/bridge_driver.c | 61 + 1 file changed, 61 insertions(+) diff

[libvirt] [PATCH 05/19] Add an SELinux access control driver

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Introduce an access control driver that uses the SELinux framework for validating API authorization. Each libvirt object is represented as a new class in SELinux policy, along with all permissions. The actual policy is not included here, it has to be

[libvirt] [PATCH 04/19] Add a policy kit access control driver

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Add an access control driver that uses the pkcheck command to check authorization requests. This is fairly inefficient, particularly for cases where an API returns a list of objects and needs to check permission for each object. It would be desirable

[libvirt] [PATCH 02/19] Set conn-driver before running driver connectOpen method

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com The access control checks in the 'connectOpen' driver method will require 'conn-driver' to be non-NULL. Set this before running the 'connectOpen' method and NULL-ify it again on failure. Signed-off-by: Daniel P. Berrange berra...@redhat.com ---

[libvirt] [PATCH 18/19] Add ACL checks into the secrets driver

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Insert calls to the ACL checking APIs in all secrets driver entrypoints. Signed-off-by: Daniel P. Berrange berra...@redhat.com --- src/secret/secret_driver.c | 31 +++ 1 file changed, 31 insertions(+) diff --git

[libvirt] [PATCH 13/19] Add ACL checks into the storage driver

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Insert calls to the ACL checking APIs in all storage driver entrypoints. Signed-off-by: Daniel P. Berrange berra...@redhat.com --- src/storage/storage_driver.c | 155 +-- 1 file changed, 151 insertions(+), 4

[libvirt] [PATCH 15/19] Add ACL checks into the interface driver

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Insert calls to the ACL checking APIs in all interface driver entrypoints. Signed-off-by: Daniel P. Berrange berra...@redhat.com --- src/interface/interface_backend_netcf.c | 114

[libvirt] [PATCH 10/19] Add ACL checks into the UML driver

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Insert calls to the ACL checking APIs in all UML driver entrypoints. Signed-off-by: Daniel P. Berrange berra...@redhat.com --- src/uml/uml_driver.c | 174 +++ 1 file changed, 162 insertions(+), 12

[libvirt] [PATCH 09/19] Add ACL checks into the LXC driver

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Insert calls to the ACL checking APIs in all LXC driver entrypoints. Signed-off-by: Daniel P. Berrange berra...@redhat.com --- src/lxc/lxc_driver.c | 219 --- 1 file changed, 207 insertions(+), 12

[libvirt] [PATCH 19/19] Add validation that all APIs contain ACL checks

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Add a script which parses the driver API code and validates that every API registered in a virNNNDriverPtr table contains an ACL check matching the API name. Signed-off-by: Daniel P. Berrange berra...@redhat.com --- src/Makefile.am | 22

[libvirt] [PATCH 07/19] Auto-generate helpers for checking access control rules

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Extend the 'gendispatch.pl' script to be able to generate three new types of file. - 'aclheader' - defines signatures of helper APIs for doing authorization checks. There is one helper API for each API requiring an auth check. Any @acl

[libvirt] [PATCH 03/19] Setup default access control manager in libvirtd

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Add a new 'access_drivers' config parameter to the libvirtd.conf configuration file. This allows admins to setup the default access control drivers to use for API authorization. The same driver is to be used by all internal drivers APIs

[libvirt] [PATCH 16/19] Add ACL checks into the node device driver

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Insert calls to the ACL checking APIs in all node device driver entrypoints. Signed-off-by: Daniel P. Berrange berra...@redhat.com --- src/node_device/node_device_driver.c | 36 1 file changed, 36 insertions(+)

[libvirt] [PATCH 17/19] Add ACL checks into the nwfilter driver

2013-05-09 Thread Daniel P. Berrange
From: Daniel P. Berrange berra...@redhat.com Insert calls to the ACL checking APIs in all nwfilter driver entrypoints. Signed-off-by: Daniel P. Berrange berra...@redhat.com --- src/nwfilter/nwfilter_driver.c | 26 ++ 1 file changed, 26 insertions(+) diff --git

Re: [libvirt] [PATCH] Skip virNWFilterTechDriver when validating API naming

2013-05-09 Thread Michal Privoznik
On 09.05.2013 15:12, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com The virNWFilterTechDriver struct is an internal only driver API with no public API equivalent. It should be skipped by the 'check-driverimpls' test case Signed-off-by: Daniel P. Berrange

Re: [libvirt] [PATCH] Replace list of driver source files with variables

2013-05-09 Thread Michal Privoznik
On 09.05.2013 15:12, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com Update the DRIVER_SOURCE_FILES variable to reference the other various XXX_SOURCES variables, instead of duplicating the filename lists. This results in a bunch of extra files being processed, but

Re: [libvirt] [PATCH 3/4] Validate the bios_date format for sysinfo

2013-05-09 Thread Martin Kletzander
On 05/09/2013 01:43 PM, John Ferlan wrote: On 05/09/2013 06:59 AM, Martin Kletzander wrote: On 04/30/2013 08:19 PM, John Ferlan wrote: --- src/conf/domain_conf.c | 24 1 file changed, 24 insertions(+) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c

Re: [libvirt] [PATCH 0/6 v3] Support NBD volumes with LXC containers

2013-05-09 Thread Daniel P. Berrange
On Fri, May 03, 2013 at 02:49:48PM +0100, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com A third version of: https://www.redhat.com/archives/libvir-list/2013-April/msg01539.html In v3 - Split patch 3 into 2 pieces - Added XML formatting tests - Fixed XML

Re: [libvirt] [PATCH] Cope with missing swap cgroup controls

2013-05-09 Thread Michal Privoznik
On 09.05.2013 14:55, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com It is possible to build a kernel without swap cgroup controls present. This causes a fatal error when querying memory parameters. Treat missing swap controls as meaning unlimited. The fatal error

Re: [libvirt] [PATCH 29/40] Simplify the Xen domain stats/peek / node memory driver methods

2013-05-09 Thread Jim Fehlig
Daniel P. Berrange wrote: Thanks for all the reviews so far ! I'm going to push the first 29 patches now. I've tested basic operations and things seem to be working sanely to me. Nice. I've done a fair bit of testing with the first 30 patches applied (including the tweeks to 10 and 24)

[libvirt] [PATCH] build: fix build with old polkit0

2013-05-09 Thread Jim Fehlig
Commit 979e9c56 missed one case of providing the timestamp parameter to virNetServerClientGetUNIXIdentity() when WITH_POLKIT0 is defined. --- Pushed under the build breaker rule. daemon/remote.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/daemon/remote.c

Re: [libvirt] [PATCH] Replace 'goto err' with 'goto cleanup' in udev interface driver

2013-05-09 Thread Daniel P. Berrange
On Thu, May 09, 2013 at 03:20:54PM +0200, Michal Privoznik wrote: On 09.05.2013 15:02, Daniel P. Berrange wrote: From: Daniel P. Berrange berra...@redhat.com The udev interface driver did not follow standard naming convention for goto labels. Signed-off-by: Daniel P. Berrange

Re: [libvirt] [PATCH 3/4] Validate the bios_date format for sysinfo

2013-05-09 Thread John Ferlan
On 05/09/2013 09:58 AM, Martin Kletzander wrote: On 05/09/2013 01:43 PM, John Ferlan wrote: On 05/09/2013 06:59 AM, Martin Kletzander wrote: On 04/30/2013 08:19 PM, John Ferlan wrote: --- src/conf/domain_conf.c | 24 1 file changed, 24 insertions(+) diff --git

Re: [libvirt] [PATCH 3/4] Validate the bios_date format for sysinfo

2013-05-09 Thread Eric Blake
On 05/09/2013 05:43 AM, John Ferlan wrote: On 05/09/2013 06:59 AM, Martin Kletzander wrote: On 04/30/2013 08:19 PM, John Ferlan wrote: I find it a bit harder to read. Wouldn't this be more nicer if we used sscanf()? Or we could take care a bit about the date and do it even shorter with

Re: [libvirt] [PATCH 4/4] Need better validation of sysinfo uuid

2013-05-09 Thread John Ferlan
On 05/09/2013 06:27 AM, Martin Kletzander wrote: On 04/30/2013 08:19 PM, John Ferlan wrote: If the sysinfo system table 'uuid' field is improperly formatted, then qemu will fail to start the guest with the error: virsh start dom error: Failed to start domain dom error: internal error

Re: [libvirt] an old bug reappear-TimeoutError

2013-05-09 Thread Eric Blake
On 05/08/2013 11:28 PM, yue wrote: hi, [charset=GBK is an unusual encoding, which in turn caused my mail reader to render your message oddly; these days, sending mail in UTF-8 is preferred] i encounter an error of libvirt, which is reported in 2011. i intended to update the ticket(spice

  1   2   >