[Qemu-devel] [PATCH v2 1/2] sheepdog: don't update inode when create_and_write fails

2012-12-16 Thread Liu Yuan
From: Liu Yuan tailai...@taobao.com For the error case such as SD_RES_NO_SPACE, we shouldn't update the inode bitmap to avoid the scenario that the object is allocated but wasn't created at the server side. This will result in VM's IO error on the failed object. Cc: MORITA Kazutaka morita.kazut

[Qemu-devel] [PATCH v2 2/2] sheepdog: pass oid directly to send_pending_req()

2012-12-16 Thread Liu Yuan
From: Liu Yuan tailai...@taobao.com Cc: MORITA Kazutaka morita.kazut...@lab.ntt.co.jp Cc: Kevin Wolf kw...@redhat.com Signed-off-by: Liu Yuan tailai...@taobao.com --- block/sheepdog.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/block/sheepdog.c b/block/sheepdog.c index

[Qemu-devel] [PATCH] sheepdog: show error message for halt status

2013-03-18 Thread Liu Yuan
From: Liu Yuan tailai...@taobao.com Sheepdog (neither quorum nor unsafe mode) will refuse to serve IO requests when number of alive nodes is less than that of copies specified by users. This will return 0x19 to QEMU client which currently doesn't recognize it. This patch adds an error

[Qemu-devel] [PATCH] rbd: fix compile error

2013-03-24 Thread Liu Yuan
From: Liu Yuan tailai...@taobao.com Commit 787e4a85 [block: Add options QDict to bdrv_file_open() prototypes] didn't update rbd.c accordingly. Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Liu Yuan tailai...@taobao.com --- block/rbd.c |3 ++- 1 file

[Qemu-devel] [PATCH v2 0/7] md: add hot-plug and hot-unplug support

2013-03-28 Thread Liu Yuan
From: Liu Yuan tailai...@taobao.com v2: - fix object stale purging for md This is the final part for MD. With this patch set, We even allow group plug, group unplug and disks/node failure during (un)plugging. Also add disk information function for collie. Liu Yuan (7): md: add support

[Qemu-devel] [PATCH v2 2/7] tests/055: test simultaneous multiple disk failures on the same node

2013-03-28 Thread Liu Yuan
From: Liu Yuan tailai...@taobao.com Signed-off-by: Liu Yuan tailai...@taobao.com --- tests/055 |7 +++ tests/055.out |8 2 files changed, 15 insertions(+) diff --git a/tests/055 b/tests/055 index 4c3bfb9..6b99552 100755 --- a/tests/055 +++ b/tests/055 @@ -42,6 +42,13

[Qemu-devel] [PATCH v2 3/7] net: enlarge connect_to_addr() scope

2013-03-28 Thread Liu Yuan
From: Liu Yuan tailai...@taobao.com This is a prepare patch. Signed-off-by: Liu Yuan tailai...@taobao.com --- include/net.h|8 sheep/sockfd_cache.c |8 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/include/net.h b/include/net.h index a68c880

[Qemu-devel] [PATCH v2 5/7] collie: add new commands to manipulate multi-disks

2013-03-28 Thread Liu Yuan
From: Liu Yuan tailai...@taobao.com Three command added: $ collie node md info # show information about md of {this node, all nodes} $ collie node md plug path1,{path2,...} # plug disk(s) into node $ collie node md unplug path1,{path2,...} # unplug disk(s) into node Signed-off-by: Liu Yuan

[Qemu-devel] [PATCH v2 1/7] md: add support for simultaneous disk failure on the same node

2013-03-28 Thread Liu Yuan
From: Liu Yuan tailai...@taobao.com Don't panic out, instead we simply remove this disk for this nested disk failures. Signed-off-by: Liu Yuan tailai...@taobao.com --- sheep/md.c | 66 +++- 1 file changed, 48 insertions(+), 18 deletions

[Qemu-devel] [PATCH v2 6/7] sheep: remove duplicate recovery complete notification

2013-03-28 Thread Liu Yuan
From: Liu Yuan tailai...@taobao.com Signed-off-by: Liu Yuan tailai...@taobao.com --- sheep/ops.c | 14 +- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/sheep/ops.c b/sheep/ops.c index 3839437..204befd 100644 --- a/sheep/ops.c +++ b/sheep/ops.c @@ -624,7 +624,19

[Qemu-devel] [PATCH v2 4/7] md: add hot-plug and hot-unplug support

2013-03-28 Thread Liu Yuan
From: Liu Yuan tailai...@taobao.com We allow group plug, group unplug and disks failure during (un)plugging. Also add disk information function for collie. Signed-off-by: Liu Yuan tailai...@taobao.com --- collie/collie.c |2 +- include/internal_proto.h | 16 +++ include

[Qemu-devel] [PATCH v2 7/7] tsets: add 057 to test md hot-plug and hot-unplug

2013-03-28 Thread Liu Yuan
From: Liu Yuan tailai...@taobao.com Signed-off-by: Liu Yuan tailai...@taobao.com --- tests/057 | 57 + tests/057.out | 55 +++ tests/group |1 + 3 files changed, 113

Re: [Qemu-devel] [PATCH v2 0/7] md: add hot-plug and hot-unplug support

2013-03-28 Thread Liu Yuan
On 03/29/2013 01:42 PM, Liu Yuan wrote: From: Liu Yuan tailai...@taobao.com v2: - fix object stale purging for md This is the final part for MD. With this patch set, We even allow group plug, group unplug and disks/node failure during (un)plugging. Also add disk information function

Re: [Qemu-devel] [PATCH 1/2] sheepdog: adopting protocol update for VDI locking

2014-08-07 Thread Liu Yuan
Cc: Liu Yuan namei.u...@gmail.com Cc: MORITA Kazutaka morita.kazut...@lab.ntt.co.jp Signed-off-by: Hitoshi Mitake mitake.hito...@lab.ntt.co.jp --- block/sheepdog.c | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/block/sheepdog.c b/block/sheepdog.c index 8d9350c

Re: [Qemu-devel] [PATCH 2/2] sheepdog: improve error handling for a case of failed lock

2014-08-07 Thread Liu Yuan
-by: Valerio Pachera siri...@gmail.com Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Cc: Liu Yuan namei.u...@gmail.com Cc: MORITA Kazutaka morita.kazut...@lab.ntt.co.jp Signed-off-by: Hitoshi Mitake mitake.hito...@lab.ntt.co.jp --- block/sheepdog.c | 4 1 file

[Qemu-devel] [PATCH] cluster/zookeeper: add log information for zk auto-recoonect

2014-08-08 Thread Liu Yuan
Reported-by: Valerio Pachera siri...@gmail.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- sheep/group.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sheep/group.c b/sheep/group.c index 06a80bd..08e3884 100644 --- a/sheep/group.c +++ b/sheep/group.c @@ -979,7 +979,7

Re: [Qemu-devel] [PATCH 2/2] sheepdog: improve error handling for a case of failed lock

2014-08-08 Thread Liu Yuan
On Fri, Aug 08, 2014 at 03:17:59PM +0900, Hitoshi Mitake wrote: At Fri, 8 Aug 2014 13:31:39 +0800, Liu Yuan wrote: On Thu, Aug 07, 2014 at 04:28:40PM +0900, Hitoshi Mitake wrote: Recently, sheepdog revived its VDI locking functionality. This patch updates sheepdog driver of QEMU

Re: [Qemu-devel] [PATCH 1/2] sheepdog: adopting protocol update for VDI locking

2014-08-08 Thread Liu Yuan
On Fri, Aug 08, 2014 at 03:12:17PM +0900, Hitoshi Mitake wrote: At Fri, 8 Aug 2014 13:20:39 +0800, Liu Yuan wrote: On Thu, Aug 07, 2014 at 04:28:39PM +0900, Hitoshi Mitake wrote: The update is required for supporting iSCSI multipath. It doesn't affect behavior of QEMU driver

Re: [Qemu-devel] [PATCH 1/2] sheepdog: adopting protocol update for VDI locking

2014-08-10 Thread Liu Yuan
On Mon, Aug 11, 2014 at 11:17:33AM +0900, Hitoshi Mitake wrote: At Fri, 8 Aug 2014 15:49:37 +0800, Liu Yuan wrote: On Fri, Aug 08, 2014 at 03:12:17PM +0900, Hitoshi Mitake wrote: At Fri, 8 Aug 2014 13:20:39 +0800, Liu Yuan wrote: On Thu, Aug 07, 2014 at 04:28:39PM +0900

Re: [Qemu-devel] [PATCH 1/2] sheepdog: adopting protocol update for VDI locking

2014-08-10 Thread Liu Yuan
On Mon, Aug 11, 2014 at 11:34:56AM +0800, Liu Yuan wrote: On Mon, Aug 11, 2014 at 11:17:33AM +0900, Hitoshi Mitake wrote: At Fri, 8 Aug 2014 15:49:37 +0800, Liu Yuan wrote: On Fri, Aug 08, 2014 at 03:12:17PM +0900, Hitoshi Mitake wrote: At Fri, 8 Aug 2014 13:20:39 +0800, Liu

Re: [Qemu-devel] [PATCH v4 2/2] block/quorum: add simple read pattern support

2014-08-11 Thread Liu Yuan
On Thu, Jul 17, 2014 at 01:18:56PM +0800, Liu Yuan wrote: This patch adds single read pattern to quorum driver and quorum vote is default pattern. For now we do a quorum vote on all the reads, it is designed for unreliable underlying storage such as non-redundant NFS to make sure data

Re: [Qemu-devel] [PATCH v4 2/2] block/quorum: add simple read pattern support

2014-08-11 Thread Liu Yuan
On Mon, Aug 11, 2014 at 02:31:43PM +0200, Benoît Canet wrote: The Thursday 17 Jul 2014 à 13:18:56 (+0800), Liu Yuan wrote : This patch adds single read pattern to quorum driver and quorum vote is default pattern. For now we do a quorum vote on all the reads, it is designed

Re: [Qemu-devel] [PATCH v4 2/2] block/quorum: add simple read pattern support

2014-08-14 Thread Liu Yuan
On Tue, Aug 12, 2014 at 10:41:28AM +0800, Liu Yuan wrote: On Mon, Aug 11, 2014 at 02:31:43PM +0200, Benoît Canet wrote: The Thursday 17 Jul 2014 à 13:18:56 (+0800), Liu Yuan wrote : This patch adds single read pattern to quorum driver and quorum vote is default pattern. For now

Re: [Qemu-devel] [PATCH v3 0/2] sheepdog driver update related to VDI locking feature

2014-08-14 Thread Liu Yuan
Hitoshi Mitake (2): sheepdog: adopting protocol update for VDI locking sheepdog: improve error handling for a case of failed lock block/sheepdog.c | 10 +- 1 file changed, 9 insertions(+), 1 deletion(-) Reviewed-by: Liu Yuan namei.u...@gmail.com

Re: [Qemu-devel] [PATCH v4 2/2] block/quorum: add simple read pattern support

2014-08-14 Thread Liu Yuan
On Thu, Aug 14, 2014 at 01:09:32PM +0200, Benoît Canet wrote: The Thursday 17 Jul 2014 à 13:18:56 (+0800), Liu Yuan wrote : This patch adds single read pattern to quorum driver and quorum vote is default pattern. For now we do a quorum vote on all the reads, it is designed

[Qemu-devel] [PATCH v5 0/2] add read-pattern for block qourum

2014-08-14 Thread Liu Yuan
: Benoit Canet ben...@irqsave.net Cc: Eric Blake ebl...@redhat.com Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com Liu Yuan (2): qapi: add read-pattern enum for quorum block/quorum: add simple read pattern support block/quorum.c

[Qemu-devel] [PATCH v5 2/2] block/quorum: add simple read pattern support

2014-08-14 Thread Liu Yuan
,vote-threshold=1 [1] http://en.wikipedia.org/wiki/Distributed_Replicated_Block_Device Cc: Benoit Canet ben...@irqsave.net Cc: Eric Blake ebl...@redhat.com Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- block/quorum.c | 176

[Qemu-devel] [PATCH v5 1/2] qapi: add read-pattern enum for quorum

2014-08-14 Thread Liu Yuan
Cc: Eric Blake ebl...@redhat.com Reviewed-by: Eric Blake ebl...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- qapi/block-core.json | 20 +++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/qapi/block-core.json b/qapi/block-core.json index e378653

Re: [Qemu-devel] [PATCH v5 2/2] block/quorum: add simple read pattern support

2014-08-18 Thread Liu Yuan
On Fri, Aug 15, 2014 at 03:59:04PM +0200, Benoît Canet wrote: The Friday 15 Aug 2014 à 13:05:17 (+0800), Liu Yuan wrote : This patch adds single read pattern to quorum driver and quorum vote is default pattern. For now we do a quorum vote on all the reads, it is designed

[Qemu-devel] [PATCH] sheepdog: fix clone operation by 'qemu-img create -b'

2014-01-03 Thread Liu Yuan
...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- block/sheepdog.c | 16 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/block/sheepdog.c b/block/sheepdog.c index ba451a9..843a4a5 100644 --- a/block/sheepdog.c +++ b

[Qemu-devel] [PATCH] sheepdog: fix NULL dereference in sd_create

2014-06-16 Thread Liu Yuan
...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- block/sheepdog.c | 1 + 1 file changed, 1 insertion(+) diff --git a/block/sheepdog.c b/block/sheepdog.c index 1fa1939..47a8b5a 100644 --- a/block/sheepdog.c +++ b/block/sheepdog.c @@ -1761,6 +1761,7 @@ static int sd_create(const char *filename

[Qemu-devel] [PATCH] sheepdog: fix 'qemu-img map'

2014-01-21 Thread Liu Yuan
-off-by: Liu Yuan namei.u...@gmail.com --- block/sheepdog.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/block/sheepdog.c b/block/sheepdog.c index b94ab6e..61aead0 100644 --- a/block/sheepdog.c +++ b/block/sheepdog.c @@ -2442,11 +2442,12 @@ sd_co_get_block_status

Re: [Qemu-devel] [PATCH 16/22] sheepdog: implement .bdrv_detach/attach_aio_context()

2014-05-05 Thread Liu Yuan
to be implemented to move the socket fd handler from the old to the new AioContext. Cc: MORITA Kazutaka morita.kazut...@lab.ntt.co.jp Cc: Liu Yuan namei.u...@gmail.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com --- block/sheepdog.c | 118

Re: [Qemu-devel] [PATCH v2 1/2] sheepdog: fix vdi object update after live snapshot

2014-06-03 Thread Liu Yuan
On Tue, Jun 03, 2014 at 01:54:21PM +0900, Hitoshi Mitake wrote: sheepdog driver should decide a write request is COW or not based on inode object which is active when the write request is issued. Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Cc: Liu Yuan namei.u

Re: [Qemu-devel] [PATCH v2 1/2] sheepdog: fix vdi object update after live snapshot

2014-06-04 Thread Liu Yuan
On Tue, Jun 03, 2014 at 11:58:21PM +0900, Hitoshi Mitake wrote: On Tue, Jun 3, 2014 at 9:41 PM, Liu Yuan namei.u...@gmail.com wrote: On Tue, Jun 03, 2014 at 01:54:21PM +0900, Hitoshi Mitake wrote: sheepdog driver should decide a write request is COW or not based on inode object which

Re: [Qemu-devel] [sheepdog] [PATCH v3 0/2] bugfixes of sheepdog driver for a case of live snapshot

2014-06-06 Thread Liu Yuan
+ 1 files changed, 29 insertions(+), 20 deletions(-) -- sheepdog mailing list sheep...@lists.wpkg.org http://lists.wpkg.org/mailman/listinfo/sheepdog This series looks good to me. Acked-by: Liu Yuan namei.u...@gmail.com

[Qemu-devel] [PATCH] configure: make libnfs not_found message more user friendly

2014-07-09 Thread Liu Yuan
Cc: Kevin Wolf kw...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- configure | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure b/configure index 7dd43fd..684fcdf 100755 --- a/configure +++ b/configure @@ -3996,7 +3996,7 @@ if test $libnfs

[Qemu-devel] [PATCH] block/quorum: add simple read pattern support

2014-07-10 Thread Liu Yuan
,vote-threshold=1 [1] http://en.wikipedia.org/wiki/Distributed_Replicated_Block_Device Cc: Benoit Canet ben...@irqsave.net Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- block/quorum.c | 174

[Qemu-devel] [PATCH] block/quorum: make quorum_getlength error message user friendly

2014-07-11 Thread Liu Yuan
-system-x86_64: -drive if=virtio,driver=quorum...: Could not refresh total \ sector count: Invalid argument Cc: Benoit Canet ben...@irqsave.net Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- block/quorum.c | 3 ++- 1 file

[Qemu-devel] [PATCH v2] configure: make libnfs not_found message user friendly

2014-07-11 Thread Liu Yuan
Cc: Kevin Wolf kw...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- configure | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure b/configure index 7dd43fd..78e7baf 100755 --- a/configure +++ b/configure @@ -3996,7 +3996,7 @@ if test $libnfs

Re: [Qemu-devel] [PATCH] block/quorum: add simple read pattern support

2014-07-11 Thread Liu Yuan
On Fri, Jul 11, 2014 at 12:56:53PM +0200, Benoît Canet wrote: The Friday 11 Jul 2014 à 11:01:22 (+0800), Liu Yuan wrote : This patch adds single read pattern to quorum driver and quorum vote is default pattern. For now we do a quorum vote on all the reads, it is designed

Re: [Qemu-devel] [PATCH] block/quorum: add simple read pattern support

2014-07-11 Thread Liu Yuan
On Fri, Jul 11, 2014 at 08:06:36AM -0600, Eric Blake wrote: On 07/10/2014 09:01 PM, Liu Yuan wrote: This patch adds single read pattern to quorum driver and quorum vote is default pattern. For now we do a quorum vote on all the reads, it is designed for unreliable underlying storage

Re: [Qemu-devel] [PATCH] block/quorum: make quorum_getlength error message user friendly

2014-07-11 Thread Liu Yuan
On Fri, Jul 11, 2014 at 12:26:58PM +0200, Kevin Wolf wrote: Am 11.07.2014 um 09:34 hat Liu Yuan geschrieben: When start quorum driver with 2 different sized images, we get: qemu-system-x86_64: -drive if=virtio,driver=quorum...: Could not refresh total \ sector count: Input/output

[Qemu-devel] [PATCH v2] block/quorum: add simple read pattern support

2014-07-14 Thread Liu Yuan
,vote-threshold=1 [1] http://en.wikipedia.org/wiki/Distributed_Replicated_Block_Device Cc: Benoit Canet ben...@irqsave.net Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- v2: - rename single as 'fifo' - rename

Re: [Qemu-devel] [PATCH v2] block/quorum: add simple read pattern support

2014-07-14 Thread Liu Yuan
On Mon, Jul 14, 2014 at 09:33:59PM -0600, Eric Blake wrote: On 07/14/2014 09:19 PM, Liu Yuan wrote: This patch adds single read pattern to quorum driver and quorum vote is default pattern. This patch generalize the above 2 nodes case in the N nodes. That is, vm - write to all

[Qemu-devel] [PATCH v3 2/2] qapi: add read-pattern support for quorum

2014-07-15 Thread Liu Yuan
Cc: Eric Blake ebl...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- qapi/block-core.json | 19 ++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/qapi/block-core.json b/qapi/block-core.json index e378653..22491bc 100644 --- a/qapi/block-core.json +++ b

[Qemu-devel] [PATCH v3 1/2] block/quorum: add simple read pattern support

2014-07-15 Thread Liu Yuan
,vote-threshold=1 [1] http://en.wikipedia.org/wiki/Distributed_Replicated_Block_Device Cc: Benoit Canet ben...@irqsave.net Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- block/quorum.c | 181

[Qemu-devel] [PATCH v3 0/2] add read-pattern for block qourum

2014-07-15 Thread Liu Yuan
-pattern=single,vote-threshold=1 [1] http://en.wikipedia.org/wiki/Distributed_Replicated_Block_Device Liu Yuan (2): block/quorum: add simple read pattern support qapi: add read-pattern support for quorum block/quorum.c | 181 +-- qapi/block

Re: [Qemu-devel] [PATCH v3 2/2] qapi: add read-pattern support for quorum

2014-07-15 Thread Liu Yuan
On Tue, Jul 15, 2014 at 06:22:14AM -0600, Eric Blake wrote: On 07/15/2014 12:34 AM, Liu Yuan wrote: Cc: Eric Blake ebl...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- qapi/block-core.json | 19 ++- 1 file changed, 18 insertions(+), 1 deletion(-) diff

Re: [Qemu-devel] [PATCH v3 2/2] qapi: add read-pattern support for quorum

2014-07-15 Thread Liu Yuan
On Wed, Jul 16, 2014 at 10:22:20AM +0800, Liu Yuan wrote: On Tue, Jul 15, 2014 at 06:22:14AM -0600, Eric Blake wrote: On 07/15/2014 12:34 AM, Liu Yuan wrote: Cc: Eric Blake ebl...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- qapi/block-core.json | 19

[Qemu-devel] [PATCH v4 0/2] add read-pattern for block qourum

2014-07-16 Thread Liu Yuan
, Enable single read pattern on 2 children, -drive driver=quorum,children.0.file.filename=0.qcow2,\ children.1.file.filename=1.qcow2,read-pattern=fifo,vote-threshold=1 [1] http://en.wikipedia.org/wiki/Distributed_Replicated_Block_Device Liu Yuan (2): qapi: add read-pattern support for quorum

[Qemu-devel] [PATCH v4 2/2] block/quorum: add simple read pattern support

2014-07-16 Thread Liu Yuan
,vote-threshold=1 [1] http://en.wikipedia.org/wiki/Distributed_Replicated_Block_Device Cc: Benoit Canet ben...@irqsave.net Cc: Eric Blake ebl...@redhat.com Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- block/quorum.c | 179

[Qemu-devel] [PATCH v4 1/2] qapi: add read-pattern enum for quorum

2014-07-16 Thread Liu Yuan
Cc: Eric Blake ebl...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- qapi/block-core.json | 20 +++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/qapi/block-core.json b/qapi/block-core.json index e378653..42033d9 100644 --- a/qapi/block-core.json

[Qemu-devel] [PATCH] block/quorum: implement .bdrv_co_get_block_status

2014-07-17 Thread Liu Yuan
- allow drive-mirror to create sprase mirror on images like qcow2 - allow qemu-img map to work as expected on quorum driver Cc: Benoit Canet ben...@irqsave.net Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- block/quorum.c

Re: [Qemu-devel] [PATCH] block/quorum: implement .bdrv_co_get_block_status

2014-07-20 Thread Liu Yuan
On Fri, Jul 18, 2014 at 03:35:57PM +0200, Paolo Bonzini wrote: Il 17/07/2014 13:50, Liu Yuan ha scritto: - allow drive-mirror to create sprase mirror on images like qcow2 - allow qemu-img map to work as expected on quorum driver Cc: Benoit Canet ben...@irqsave.net Cc: Kevin Wolf kw

[Qemu-devel] [PATCH v6 1/2] qapi: add read-pattern enum for quorum

2014-08-18 Thread Liu Yuan
Cc: Eric Blake ebl...@redhat.com Reviewed-by: Eric Blake ebl...@redhat.com Reviewed-by: Benoît Canet benoit.ca...@nodalink.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- qapi/block-core.json | 20 +++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/qapi/block

[Qemu-devel] [PATCH v6 0/2] add read-pattern for block qourum

2014-08-18 Thread Liu Yuan
://en.wikipedia.org/wiki/Distributed_Replicated_Block_Device Cc: Benoit Canet ben...@irqsave.net Cc: Eric Blake ebl...@redhat.com Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Liu Yuan (2): qapi: add read-pattern enum for quorum block/quorum: add simple read pattern support block

[Qemu-devel] [PATCH v6 2/2] block/quorum: add simple read pattern support

2014-08-18 Thread Liu Yuan
,vote-threshold=1 [1] http://en.wikipedia.org/wiki/Distributed_Replicated_Block_Device Cc: Benoit Canet ben...@irqsave.net Cc: Eric Blake ebl...@redhat.com Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- block/quorum.c | 177

Re: [Qemu-devel] [PATCH v5 2/2] block/quorum: add simple read pattern support

2014-08-21 Thread Liu Yuan
On Mon, Aug 18, 2014 at 01:59:28PM +0800, Liu Yuan wrote: On Fri, Aug 15, 2014 at 03:59:04PM +0200, Benoît Canet wrote: The Friday 15 Aug 2014 à 13:05:17 (+0800), Liu Yuan wrote : This patch adds single read pattern to quorum driver and quorum vote is default pattern. For now

Re: [Qemu-devel] [PATCH v6 0/2] add read-pattern for block qourum

2014-08-24 Thread Liu Yuan
On Mon, Aug 18, 2014 at 05:41:03PM +0800, Liu Yuan wrote: v6: - fix a unused warning introduced by last version Hi Stefan and Kevin, Benoît Canet has added Reviewed-by tag to both patches, could one of you pick this patch set? Thanks Yuan

Re: [Qemu-devel] [PATCH v6 0/2] add read-pattern for block qourum

2014-08-28 Thread Liu Yuan
On Mon, Aug 25, 2014 at 10:46:21AM +0800, Liu Yuan wrote: On Mon, Aug 18, 2014 at 05:41:03PM +0800, Liu Yuan wrote: v6: - fix a unused warning introduced by last version Hi Stefan and Kevin, Benoît Canet has added Reviewed-by tag to both patches, could one of you pick

[Qemu-devel] [PATCH] sheepdog: fix a core dump while do auto-reconnecting

2014-08-28 Thread Liu Yuan
`!xcb_xlib_threads_sequence_lost' failed. Aborted (core dumped) Cc: qemu-devel@nongnu.org Cc: Markus Armbruster arm...@redhat.com Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- block/sheepdog.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion

[Qemu-devel] [PATCH v2] sheepdog: fix a core dump while do auto-reconnecting

2014-08-28 Thread Liu Yuan
: Assertion `!xcb_xlib_threads_sequence_lost' failed. Aborted (core dumped) Cc: qemu-devel@nongnu.org Cc: Markus Armbruster arm...@redhat.com Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Reviewed-by: Markus Armbruster arm...@redhat.com Signed-off-by: Liu Yuan namei.u

Re: [Qemu-devel] [PATCH v6 0/2] add read-pattern for block qourum

2014-08-28 Thread Liu Yuan
On Thu, Aug 28, 2014 at 11:33:08AM +0100, Stefan Hajnoczi wrote: On Mon, Aug 18, 2014 at 05:41:03PM +0800, Liu Yuan wrote: v6: - fix a unused warning introduced by last version v5: - simplify a for loop in quorum_aio_finalize() v4: - swap the patch order - update comment

[Qemu-devel] [PATCH] block: kill tail whitespace in block.c

2014-08-31 Thread Liu Yuan
Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- block.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/block.c b/block.c index e9380f6..c12b8de 100644 --- a/block.c +++ b/block.c @@ -2239,7 +2239,7

[Qemu-devel] [PATCH 1/8] block/quorum: initialize qcrs.aiocb for read

2014-09-01 Thread Liu Yuan
This is required by quorum_aio_cancel() Cc: Eric Blake ebl...@redhat.com Cc: Benoit Canet ben...@irqsave.net Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- block/quorum.c | 23 --- 1 file changed, 12

[Qemu-devel] [PATCH 4/8] block/quorum: add quorum_aio_release() helper

2014-09-01 Thread Liu Yuan
Cc: Eric Blake ebl...@redhat.com Cc: Benoit Canet ben...@irqsave.net Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- block/quorum.c | 12 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/block

[Qemu-devel] [PATCH 0/8] add basic recovery logic to quorum driver

2014-09-01 Thread Liu Yuan
to control sync bandwidth more smoothly - add auto-reconnection mechanism to other protocol (if not support yet) - add tests Cc: Eric Blake ebl...@redhat.com Cc: Benoit Canet ben...@irqsave.net Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Liu Yuan (8): block/quorum

[Qemu-devel] [PATCH 5/8] quorum: fix quorum_aio_cancel()

2014-09-01 Thread Liu Yuan
kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- block/quorum.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/block/quorum.c b/block/quorum.c index 9e056d6..b9eeda3 100644 --- a/block/quorum.c +++ b/block/quorum.c

[Qemu-devel] [PATCH 2/8] block: add driver operation callbacks

2014-09-01 Thread Liu Yuan
. Cc: Eric Blake ebl...@redhat.com Cc: Benoit Canet ben...@irqsave.net Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- block.c | 7 +++ include/block/block.h | 7 +++ include/block/block_int.h | 3

[Qemu-devel] [PATCH 8/8] quorum: add basic device recovery logic

2014-09-01 Thread Liu Yuan
any problem. Cc: Eric Blake ebl...@redhat.com Cc: Benoit Canet ben...@irqsave.net Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- block/quorum.c | 189 - trace-events

[Qemu-devel] [PATCH 3/8] block/sheepdog: propagate disconnect/reconnect events to upper driver

2014-09-01 Thread Liu Yuan
This is the reference usage how we propagate connection state to upper tier. Cc: Eric Blake ebl...@redhat.com Cc: Benoit Canet ben...@irqsave.net Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- block/sheepdog.c | 9

[Qemu-devel] [PATCH 6/8] block/quorum: add broken state to BlockDriverState

2014-09-01 Thread Liu Yuan
and threshold, we can easily mimic the DRVD behavior with following configuration: read-pattern=fifo,threshold=1 will two children. Cc: Eric Blake ebl...@redhat.com Cc: Benoit Canet ben...@irqsave.net Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Liu Yuan

[Qemu-devel] [PATCH 7/8] block: add two helpers

2014-09-01 Thread Liu Yuan
These helpers are needed by later quorum sync device logic. Cc: Eric Blake ebl...@redhat.com Cc: Benoit Canet ben...@irqsave.net Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Liu Yuan namei.u...@gmail.com --- block.c | 10 ++ include

Re: [Qemu-devel] [PATCH 2/8] block: add driver operation callbacks

2014-09-01 Thread Liu Yuan
On Mon, Sep 01, 2014 at 10:28:54AM +0200, Benoît Canet wrote: The Monday 01 Sep 2014 à 15:43:08 (+0800), Liu Yuan wrote : Driver operations are defined as callbacks passed from block upper drivers to lower drivers and are supposed to be called by lower drivers. Requests handling

Re: [Qemu-devel] [PATCH 3/8] block/sheepdog: propagate disconnect/reconnect events to upper driver

2014-09-01 Thread Liu Yuan
On Mon, Sep 01, 2014 at 10:31:47AM +0200, Benoît Canet wrote: The Monday 01 Sep 2014 à 15:43:09 (+0800), Liu Yuan wrote : This is the reference usage how we propagate connection state to upper tier. Cc: Eric Blake ebl...@redhat.com Cc: Benoit Canet ben...@irqsave.net Cc: Kevin Wolf kw

Re: [Qemu-devel] [PATCH 5/8] quorum: fix quorum_aio_cancel()

2014-09-01 Thread Liu Yuan
On Mon, Sep 01, 2014 at 10:35:27AM +0200, Benoît Canet wrote: The Monday 01 Sep 2014 à 15:43:11 (+0800), Liu Yuan wrote : For a fifo read pattern, we only have one running aio (possible other cases that has less number than num_children in the future) I have trouble understanding this part

Re: [Qemu-devel] [PATCH 6/8] block/quorum: add broken state to BlockDriverState

2014-09-01 Thread Liu Yuan
On Mon, Sep 01, 2014 at 10:57:43AM +0200, Benoît Canet wrote: The Monday 01 Sep 2014 à 15:43:12 (+0800), Liu Yuan wrote : This allow VM continues to process even if some devices are broken meanwhile with proper configuration. We mark the device broken when the protocol tier notify back

Re: [Qemu-devel] [PATCH 2/8] block: add driver operation callbacks

2014-09-01 Thread Liu Yuan
On Mon, Sep 01, 2014 at 11:28:22AM +0200, Benoît Canet wrote: The Monday 01 Sep 2014 à 17:19:19 (+0800), Liu Yuan wrote : On Mon, Sep 01, 2014 at 10:28:54AM +0200, Benoît Canet wrote: The Monday 01 Sep 2014 à 15:43:08 (+0800), Liu Yuan wrote : Driver operations are defined as callbacks

Re: [Qemu-devel] [PATCH 8/8] quorum: add basic device recovery logic

2014-09-01 Thread Liu Yuan
On Mon, Sep 01, 2014 at 11:37:20AM +0200, Benoît Canet wrote: The Monday 01 Sep 2014 à 15:43:14 (+0800), Liu Yuan wrote : For some configuration, quorum allow VMs to continue while some child devices are broken and when the child devices are repaired and return back, we need to sync

Re: [Qemu-devel] [PATCH 5/8] quorum: fix quorum_aio_cancel()

2014-09-01 Thread Liu Yuan
On Mon, Sep 01, 2014 at 11:32:04AM +0200, Benoît Canet wrote: The Monday 01 Sep 2014 à 17:26:09 (+0800), Liu Yuan wrote : On Mon, Sep 01, 2014 at 10:35:27AM +0200, Benoît Canet wrote: The Monday 01 Sep 2014 à 15:43:11 (+0800), Liu Yuan wrote : For a fifo read pattern, we only have one

Re: [Qemu-devel] [PATCH 0/8] add basic recovery logic to quorum driver

2014-09-10 Thread Liu Yuan
On Sun, Sep 07, 2014 at 05:12:31PM +0200, Benoît Canet wrote: The Monday 01 Sep 2014 à 15:43:06 (+0800), Liu Yuan wrote : This patch set mainly add mainly two logics to implement device recover - notify qourum driver of the broken states from the child driver(s) - dirty track and sync

Re: [Qemu-devel] [PATCH 0/8] add basic recovery logic to quorum driver

2014-09-10 Thread Liu Yuan
On Wed, Sep 03, 2014 at 12:19:14AM +0200, Benoît Canet wrote: The Monday 01 Sep 2014 à 15:43:06 (+0800), Liu Yuan wrote : Liu, Do you think this could work with qcow2 file backed by NFS servers ? It depends on which client we use. If we use Linux NFS client by 'posix file' protocol, I

Re: [Qemu-devel] [PATCH v4] sheepdog: selectable object size support

2015-02-05 Thread Liu Yuan
On Wed, Feb 04, 2015 at 01:54:19PM +0900, Teruaki Ishizaki wrote: (2015/02/02 15:52), Liu Yuan wrote: On Tue, Jan 27, 2015 at 05:35:27PM +0900, Teruaki Ishizaki wrote: Previously, qemu block driver of sheepdog used hard-coded VDI object size. This patch enables users to handle block_size_shift

Re: [Qemu-devel] [PATCH v4] sheepdog: selectable object size support

2015-02-08 Thread Liu Yuan
On Fri, Feb 06, 2015 at 04:57:55PM +0900, Teruaki Ishizaki wrote: (2015/02/06 11:18), Liu Yuan wrote: On Wed, Feb 04, 2015 at 01:54:19PM +0900, Teruaki Ishizaki wrote: (2015/02/02 15:52), Liu Yuan wrote: On Tue, Jan 27, 2015 at 05:35:27PM +0900, Teruaki Ishizaki wrote: Previously, qemu block

Re: [Qemu-devel] [PATCH v4] sheepdog: selectable object size support

2015-02-11 Thread Liu Yuan
On Thu, Feb 12, 2015 at 10:51:25AM +0900, Teruaki Ishizaki wrote: (2015/02/10 20:12), Liu Yuan wrote: On Tue, Jan 27, 2015 at 05:35:27PM +0900, Teruaki Ishizaki wrote: Previously, qemu block driver of sheepdog used hard-coded VDI object size. This patch enables users to handle block_size_shift

Re: [Qemu-devel] [PATCH v4] sheepdog: selectable object size support

2015-02-11 Thread Liu Yuan
On Thu, Feb 12, 2015 at 11:33:16AM +0900, Teruaki Ishizaki wrote: (2015/02/12 11:19), Liu Yuan wrote: On Thu, Feb 12, 2015 at 10:51:25AM +0900, Teruaki Ishizaki wrote: (2015/02/10 20:12), Liu Yuan wrote: On Tue, Jan 27, 2015 at 05:35:27PM +0900, Teruaki Ishizaki wrote: Previously, qemu block

[Qemu-devel] [PATCH v2] sheepdog: fix confused return values

2015-02-17 Thread Liu Yuan
From: Liu Yuan liuy...@cmss.chinamobile.com These functions mix up -1 and -errno in return values and would might cause trouble error handling in the call chain. This patch let them return -errno and add some comments. Cc: qemu-devel@nongnu.org Cc: Markus Armbruster arm...@redhat.com Cc: Kevin

Re: [Qemu-devel] [PATCH] sheepdog: fix confused return values

2015-02-17 Thread Liu Yuan
On Mon, Feb 16, 2015 at 12:56:04PM +0100, Kevin Wolf wrote: Am 13.02.2015 um 04:45 hat Liu Yuan geschrieben: From: Liu Yuan liuy...@cmss.chinamobile.com These functions mix up -1 and -errno in return values and would might cause trouble error handling in the call chain. This patch

Re: [Qemu-devel] [sheepdog] [PATCH v4] sheepdog: selectable object size support

2015-02-12 Thread Liu Yuan
On Thu, Feb 12, 2015 at 05:13:55PM +0900, Hitoshi Mitake wrote: At Thu, 12 Feb 2015 15:42:17 +0800, Liu Yuan wrote: On Thu, Feb 12, 2015 at 04:28:01PM +0900, Hitoshi Mitake wrote: At Thu, 12 Feb 2015 15:00:49 +0800, Liu Yuan wrote: On Thu, Feb 12, 2015 at 03:19:21PM +0900

Re: [Qemu-devel] [PATCH v4] sheepdog: selectable object size support

2015-02-12 Thread Liu Yuan
On Fri, Feb 13, 2015 at 10:33:04AM +0900, Teruaki Ishizaki wrote: (2015/02/12 11:55), Liu Yuan wrote: On Thu, Feb 12, 2015 at 11:33:16AM +0900, Teruaki Ishizaki wrote: (2015/02/12 11:19), Liu Yuan wrote: On Thu, Feb 12, 2015 at 10:51:25AM +0900, Teruaki Ishizaki wrote: (2015/02/10 20:12), Liu

Re: [Qemu-devel] [sheepdog] [PATCH v4] sheepdog: selectable object size support

2015-02-11 Thread Liu Yuan
On Thu, Feb 12, 2015 at 03:19:21PM +0900, Hitoshi Mitake wrote: At Tue, 10 Feb 2015 18:35:58 +0800, Liu Yuan wrote: On Tue, Feb 10, 2015 at 06:56:33PM +0900, Teruaki Ishizaki wrote: (2015/02/10 17:58), Liu Yuan wrote: On Tue, Feb 10, 2015 at 05:22:02PM +0900, Teruaki Ishizaki wrote

Re: [Qemu-devel] [sheepdog] [PATCH v4] sheepdog: selectable object size support

2015-02-11 Thread Liu Yuan
On Thu, Feb 12, 2015 at 04:28:01PM +0900, Hitoshi Mitake wrote: At Thu, 12 Feb 2015 15:00:49 +0800, Liu Yuan wrote: On Thu, Feb 12, 2015 at 03:19:21PM +0900, Hitoshi Mitake wrote: At Tue, 10 Feb 2015 18:35:58 +0800, Liu Yuan wrote: On Tue, Feb 10, 2015 at 06:56:33PM +0900

Re: [Qemu-devel] [PATCH] sheepdog: Fix misleading error messages in sd_snapshot_create()

2015-02-12 Thread Liu Yuan
)); goto cleanup; } Reviewed-by: Liu Yuan namei.u...@gmail.com

Re: [Qemu-devel] [PATCH] sheepdog: fix confused return values

2015-02-12 Thread Liu Yuan
On Fri, Feb 13, 2015 at 11:45:42AM +0800, Liu Yuan wrote: From: Liu Yuan liuy...@cmss.chinamobile.com These functions mix up -1 and -errno in return values and would might cause trouble error handling in the call chain. This patch let them return -errno and add some comments. Reported

[Qemu-devel] [PATCH] sheepdog: fix confused return values

2015-02-12 Thread Liu Yuan
From: Liu Yuan liuy...@cmss.chinamobile.com These functions mix up -1 and -errno in return values and would might cause trouble error handling in the call chain. This patch let them return -errno and add some comments. Reported-by: Markus Armbruster arm...@redhat.com Signed-off-by: Liu Yuan

Re: [Qemu-devel] [PATCH v4] sheepdog: selectable object size support

2015-02-01 Thread Liu Yuan
On Tue, Jan 27, 2015 at 05:35:27PM +0900, Teruaki Ishizaki wrote: Previously, qemu block driver of sheepdog used hard-coded VDI object size. This patch enables users to handle block_size_shift value for calculating VDI object size. When you start qemu, you don't need to specify additional

Re: [Qemu-devel] [PATCH v4] sheepdog: selectable object size support

2015-02-09 Thread Liu Yuan
On Tue, Jan 27, 2015 at 05:35:27PM +0900, Teruaki Ishizaki wrote: Previously, qemu block driver of sheepdog used hard-coded VDI object size. This patch enables users to handle block_size_shift value for calculating VDI object size. When you start qemu, you don't need to specify additional

Re: [Qemu-devel] [PATCH v4] sheepdog: selectable object size support

2015-02-09 Thread Liu Yuan
On Tue, Feb 10, 2015 at 11:10:51AM +0800, Liu Yuan wrote: On Tue, Jan 27, 2015 at 05:35:27PM +0900, Teruaki Ishizaki wrote: Previously, qemu block driver of sheepdog used hard-coded VDI object size. This patch enables users to handle block_size_shift value for calculating VDI object size

Re: [Qemu-devel] [PATCH v4] sheepdog: selectable object size support

2015-02-10 Thread Liu Yuan
On Tue, Feb 10, 2015 at 05:22:02PM +0900, Teruaki Ishizaki wrote: (2015/02/10 12:10), Liu Yuan wrote: On Tue, Jan 27, 2015 at 05:35:27PM +0900, Teruaki Ishizaki wrote: Previously, qemu block driver of sheepdog used hard-coded VDI object size. This patch enables users to handle block_size_shift

<    1   2   3   4   >