Re: [libvirt] [PATCH]LXC: free dst before lxcDomainAttachDeviceDiskLive return

2013-09-26 Thread Chen Hanxiao
-Original Message- From: Daniel Veillard [mailto:veill...@redhat.com] Sent: Thursday, September 26, 2013 4:42 PM To: Chen Hanxiao Cc: libvir-list@redhat.com Subject: Re: [libvirt] [PATCH]LXC: free dst before lxcDomainAttachDeviceDiskLive return On Thu, Sep 26, 2013 at 02:01

[libvirt] [PATCH]LXC: fix a comment typo in lxc_controller.c

2013-09-26 Thread Chen Hanxiao
From: Chen Hanxiao chenhanx...@cn.fujitsu.com LXC: fix a comment typo in lxc_controller.c Signed-off-by: Chen Hanxiao chenhanx...@cn.fujitsu.com --- src/lxc/lxc_controller.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lxc/lxc_controller.c b/src/lxc/lxc_controller.c

[libvirt] [PATCH]util: Refresh virHook before checking its existence

2013-09-25 Thread Chen Hanxiao
From: Chen Hanxiao chenhanx...@cn.fujitsu.com We refresh the status of hook scripts only when start/stop libvirt, or reload its configuration. But the status of hooks scripts may be changed. We need to refresh its status before checking its existence. Signed-off-by: Chen Hanxiao chenhanx

[libvirt] [PATCH]util: Helper function for checking existence of hook files for specific driver

2013-09-25 Thread Chen Hanxiao
From: Chen Hanxiao chenhanx...@cn.fujitsu.com We refresh the status of hook scripts only when start/restart libvirt or reloads its configuration. But hooks scripts may be changed. This function will help to check its existence. And we do not need to start/restart libvirt if we add/remove hook

[libvirt] [PATCH]qemu: virDomainControllerFind may return 0 if controller found

2013-09-24 Thread Chen Hanxiao
From: Chen Hanxiao chenhanx...@cn.fujitsu.com The return value of virDomainControllerFind =0 means that the specific controller was found. But some functions invoke it and treat 0 as not found. This patch fix these incorrect invocation. Signed-off-by: Chen Hanxiao chenhanx...@cn.fujitsu.com

[libvirt] [Patch]LXC: Add support for attach/detach/update controller in config for LXC

2013-09-24 Thread Chen Hanxiao
From: Chen Hanxiao chenhanx...@cn.fujitsu.com Add support for attach/detach/update controller in config for LXC. Signed-off-by: Chen Hanxiao chenhanx...@cn.fujitsu.com --- src/lxc/lxc_driver.c | 30 ++ 1 file changed, 30 insertions(+) diff --git a/src/lxc

Re: [libvirt] [Patch]LXC: Add support for attach/detach/update controller in config for LXC

2013-09-24 Thread Chen Hanxiao
, September 24, 2013 6:13 PM To: Chen Hanxiao Cc: libvir-list@redhat.com Subject: Re: [libvirt] [Patch]LXC: Add support for attach/detach/update controller in config for LXC On Tue, Sep 24, 2013 at 05:32:28PM +0800, Chen Hanxiao wrote: From: Chen Hanxiao chenhanx...@cn.fujitsu.com Add

[libvirt] [PATCH]LXC: Check the existence of dir before resolving symlinks

2013-09-23 Thread Chen Hanxiao
From: Chen Hanxiao chenhanx...@cn.fujitsu.com If dir does not exist, raise a proper error in logs and don't let virFileResolveAllLinks throw itself's exceptions in logs, which may be misleading. Signed-off-by: Chen Hanxiao chenhanx...@cn.fujitsu.com --- src/lxc/lxc_container.c | 8 1

[libvirt] [PATCH]virsh: support readonly in attach-disk command

2013-09-18 Thread Chen Hanxiao
From: Chen Hanxiao chenhanx...@cn.fujitsu.com support readonly in attach-disk virsh command with option --readonly Signed-off-by: Chen Hanxiao chenhanx...@cn.fujitsu.com --- tools/virsh-domain.c | 7 +++ tools/virsh.pod | 5 +++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff

[libvirt] [PATCH]LXC: follow the unit style of /proc/meminfo

2013-09-17 Thread Chen Hanxiao
From: Chen Hanxiao chenhanx...@cn.fujitsu.com If we start libvirt_lxc with fuse complied, we could see an isolate /proc/meminfo based on fuse. Part of this were modified based on container's mem cgroup, with the unit style of KB; rest of them were copied from /proc/meminfo, with another unit

Re: [libvirt] [PATCH v2] Add some notes about security considerations when using LXC

2013-09-13 Thread Chen Hanxiao
-Original Message- From: Daniel P. Berrange [mailto:berra...@redhat.com] Sent: Wednesday, September 11, 2013 6:57 PM To: libvir-list@redhat.com Cc: Gao feng; Chen Hanxiao; Daniel P. Berrange Subject: [PATCH v2] Add some notes about security considerations when using LXC From

Re: [libvirt] [PATCH] tools: fix a judgment of equalling zero about an array's length

2013-09-13 Thread Chen Hanxiao
-Original Message- From: libvir-list-boun...@redhat.com [mailto:libvir-list-boun...@redhat.com] On Behalf Of lawrancejing Sent: Friday, September 13, 2013 10:00 AM To: libvir-list@redhat.com Cc: lawrancejing Subject: [libvirt] [PATCH] tools: fix a judgment of equalling zero about

Re: [libvirt] [PATCH v2] Add some notes about security considerations when using LXC

2013-09-12 Thread Chen Hanxiao
-Original Message- From: Daniel P. Berrange [mailto:berra...@redhat.com] Sent: Thursday, September 12, 2013 6:46 PM To: Chen Hanxiao Cc: libvir-list@redhat.com; 'Gao feng' Subject: Re: [PATCH v2] Add some notes about security considerations when using LXC On Thu, Sep 12, 2013

[libvirt] [PATCH v3]LXC: Helper function for checking permission of dir when userns enabled

2013-09-10 Thread Chen Hanxiao
From: Chen Hanxiao chenhanx...@cn.fujitsu.com If we enable userns, the process with uid/gid in idmap should have enough permission to access dir we provided for containers. Currently, the debug log is very implicit or misleading sometimes. This patch will help clarify this for us when using debug

Re: [libvirt] [PATCH]LXC doc: Add warns if net namespace not enabled

2013-09-10 Thread Chen Hanxiao
-Original Message- From: Daniel P. Berrange [mailto:berra...@redhat.com] Sent: Tuesday, September 10, 2013 5:20 PM To: Chen Hanxiao Cc: libvir-list@redhat.com Subject: Re: [libvirt] [PATCH]LXC doc: Add warns if net namespace not enabled On Mon, Sep 09, 2013 at 04:33:54PM +0800

Re: [libvirt] [PATCH] Add some notes about security considerations when using LXC

2013-09-10 Thread Chen Hanxiao
-Original Message- From: Daniel P. Berrange [mailto:berra...@redhat.com] Sent: Tuesday, September 10, 2013 6:44 PM To: libvir-list@redhat.com Cc: Chen Hanxiao; Daniel P. Berrange Subject: [PATCH] Add some notes about security considerations when using LXC From: Daniel P. Berrange

Re: [libvirt] [PATCH]LXC doc: Add warns if net namespace not enabled

2013-09-09 Thread Chen Hanxiao
ping... -Original Message- From: libvir-list-boun...@redhat.com [mailto:libvir-list-boun...@redhat.com] On Behalf Of Chen Hanxiao Sent: Tuesday, September 03, 2013 10:04 AM To: 'Daniel P. Berrange' Cc: libvir-list@redhat.com Subject: Re: [libvirt] [PATCH]LXC doc: Add warns if net

[libvirt] [PATCH] LXC:fix typo in lxc_container.c

2013-09-05 Thread Chen Hanxiao
From: Chen Hanxiao chenhanx...@cn.fujitsu.com fix typo in lxc_container.c Signed-off-by: Chen Hanxiao chenhanx...@cn.fujitsu.com --- src/lxc/lxc_container.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/lxc/lxc_container.c b/src/lxc/lxc_container.c index 8abaea0

Re: [libvirt] [PATCH]LXC doc: Add warns if net namespace not enabled

2013-09-02 Thread Chen Hanxiao
Hi Any comments? Thanks -Original Message- From: Chen Hanxiao [mailto:chenhanx...@cn.fujitsu.com] Sent: Friday, August 23, 2013 1:18 PM To: libvir-list@redhat.com Cc: chenhanx...@cn.fujitsu.com Subject: [libvirt][PATCH]LXC doc: Add warns if net namespace not enabled From

Re: [libvirt] [PATCH]LXC: force container to enable network namespace

2013-08-22 Thread Chen HanXiao
-Original Message- From: Daniel P. Berrange [mailto:berra...@redhat.com] Sent: Thursday, August 22, 2013 5:42 PM To: Gao feng Cc: Chen Hanxiao; libvir-list@redhat.com Subject: Re: [libvirt] [PATCH]LXC: force container to enable network namespace On Thu, Aug 22, 2013 at 09:23

[libvirt] [PATCH]LXC doc: Add warns if net namespace not enabled

2013-08-22 Thread Chen Hanxiao
From: Chen Hanxiao chenhanx...@cn.fujitsu.com If we don't enable network namespace, we could shutdown host by executing command 'shutdown' inside container. This patch will add some warnings in LXC docs and give some advice to readers. Signed-off-by: Chen Hanxiao chenhanx...@cn.fujitsu.com

[libvirt] [PATCH]LXC: force container to enable network namespace

2013-08-21 Thread Chen Hanxiao
From: Chen Hanxiao chenhanx...@cn.fujitsu.com If we don't enable network namespace, we could shutdown host inside container by command 'shutdown', which is unacceptable. This patch will force users to enable network namespace before they start container. Signed-off-by: Chen Hanxiao chenhanx

Re: [libvirt] [PATCH v2]LXC: Helper function for checking ownership of dir when userns enabled

2013-08-20 Thread Chen HanXiao
Hi Any comments? Thanks -Original Message- From: libvir-list-boun...@redhat.com [mailto:libvir-list-boun...@redhat.com] On Behalf Of Chen HanXiao Sent: Wednesday, August 14, 2013 9:30 AM To: 'Daniel P. Berrange' Cc: libvir-list@redhat.com Subject: Re: [libvirt] [PATCH v2

Re: [libvirt] [PATCH v2]LXC: Helper function for checking ownership of dir when userns enabled

2013-08-13 Thread Chen HanXiao
-Original Message- From: Daniel P. Berrange [mailto:berra...@redhat.com] Sent: Saturday, August 10, 2013 12:54 AM To: Chen Hanxiao Cc: libvir-list@redhat.com Subject: Re: [libvirt] [PATCH v2]LXC: Helper function for checking ownership of dir when userns enabled On Fri, Aug 09

[libvirt] [PATCH v2]LXC: Helper function for checking ownership of dir when userns enabled

2013-08-09 Thread Chen Hanxiao
From: Chen Hanxiao chenhanx...@cn.fujitsu.com If we enable userns, the ownership of dir we provided for containers should match the uid/gid in idmap. Currently, the debug log is very implicit or misleading sometimes. This patch will help clarify this for us when using debug log or virsh. v2

[libvirt] LXC: Helper function for checking ownership of dir when userns enabled

2013-08-08 Thread Chen Hanxiao
From: Chen Hanxiao chenhanx...@cn.fujitsu.com If we enable userns, the ownership of dir we provided for containers should match the uid/gid in idmap. Currently, the debug log is very implicit or misleading sometimes. This patch will help clarify this for us when using debug log or virsh

[libvirt] [PATCH]Support virtio-scsi disk XML with tag 'model'

2012-11-12 Thread Chen Hanxiao
From: ChenHanxiao chenhanx...@cn.fujitsu.com If we add a virtio-disk, we need to add a SCSI controller with model 'virtio-scsi'. This patch allows libvirt to analyze disks XML with tag 'model': disk type='block' device='disk' driver name='qemu' type='raw'/ source dev='/dev/sdb'/

Re: [libvirt] [PATCH]Support virtio-scsi disk XML with tag 'model'

2012-11-12 Thread Chen HanXiao
-Original Message- From: Daniel P. Berrange [mailto:berra...@redhat.com] Sent: Monday, November 12, 2012 6:31 PM To: Chen Hanxiao Cc: libvir-list@redhat.com Subject: Re: [libvirt] [PATCH]Support virtio-scsi disk XML with tag 'model' On Mon, Nov 12, 2012 at 05:18:41PM +0800, Chen

[libvirt] [RFC][PATCH] Revision for message payload encoding error when adding a large mount of virtio disks

2012-04-19 Thread Chen Hanxiao
From: Chen Hanxiao chenhanx...@cn.fujitsu.com When adding a large number of virtio storage devices to virtual machine by using 'virsh edit' command, there is a problem: When we added more than 190 virtio disks by 'virsh edit' command, we got a feedback as 'error: Unable to encode message payload

Re: [libvirt] [RFC][PATCH] Revision for message payload encoding error when adding a large mount of virtio disks

2012-04-19 Thread Chen HanXiao
On Thu, Apr 19, 2012 at 03:04:09PM +0200, Michal Privoznik wrote: On 19.04.2012 14:45, Richard W.M. Jones wrote: On Thu, Apr 19, 2012 at 02:25:16PM +0800, Chen Hanxiao wrote: * This is an arbitrary limit designed to stop the decoder from trying * to allocate unbounded amounts of memory

<    1   2   3   4   5   6