[sheepdog] [PATCH v3] cluster: change the interface of distributed lock

2013-12-09 Thread Robin Dong
From: Robin Dong san...@taobao.com Using only lock_id as parameter of lock interface and reduce function to onlytwo: lock(uint64_t lock_id) unlock(uint64_t lock_id) The -lock will create and acquire the distributed lock and -unlock will release it. It is more convient for end

Re: [sheepdog] [PATCH v3] cluster: change the interface of distributed lock

2013-12-09 Thread Liu Yuan
On Mon, Dec 09, 2013 at 05:03:35PM +0800, Robin Dong wrote: From: Robin Dong san...@taobao.com Using only lock_id as parameter of lock interface and reduce function to onlytwo: lock(uint64_t lock_id) unlock(uint64_t lock_id) The -lock will create and acquire the

[sheepdog] [PATCH v4] cluster: change the interface of distributed lock

2013-12-09 Thread Robin Dong
From: Robin Dong san...@taobao.com Using only lock_id as parameter of lock interface and reduce function to only two: lock(uint64_t lock_id) unlock(uint64_t lock_id) The -lock will create and acquire the distributed lock and -unlock will release it which is more convient for end

Re: [sheepdog] [PATCH v4] cluster: change the interface of distributed lock

2013-12-09 Thread Liu Yuan
On Mon, Dec 09, 2013 at 05:18:30PM +0800, Robin Dong wrote: From: Robin Dong san...@taobao.com Using only lock_id as parameter of lock interface and reduce function to only two: lock(uint64_t lock_id) unlock(uint64_t lock_id) The -lock will create and acquire the

[sheepdog] [PATCH] sheep: add an option for selecting the output directory of sheep.log

2013-12-09 Thread Teruaki Ishizaki
Previously sheep.log was saved in the Sheepdog store directory, and used size of Sheepdog store directory included log file size. So, administrator couldn't do capacity planning simply. This patch adds an option for setting the output directory of sheep.log. Usage: $ sheep -L

Re: [sheepdog] [PATCH] sheepdog: check if '-o redundancy' is passed from user

2013-12-09 Thread Kevin Wolf
Am 08.12.2013 um 17:11 hat Liu Yuan geschrieben: This fix a segfault (that is caused by b3af018f3) of following command: $ qemu-img convert some_img sheepdog:some_img Cc: qemu-de...@nongnu.org Cc: Kevin Wolf kw...@redhat.com Cc: Stefan Hajnoczi stefa...@redhat.com Signed-off-by: Liu Yuan

Re: [sheepdog] [PATCH] bs_sheepdog.c: ensure that vdi names and tag names are null-terminated

2013-12-09 Thread FUJITA Tomonori
On Mon, 9 Dec 2013 14:00:41 +0900 Ryusuke Konishi konishi.ryus...@lab.ntt.co.jp wrote: In the current sheepdog driver, tag names and vdi names are truncated to 256 bytes if they are longer than the size. The request data will not be null-terminated if those names are truncated to the

Re: [sheepdog] [PATCH] sheep: add an option for selecting the output directory of sheep.log

2013-12-09 Thread Liu Yuan
On Mon, Dec 09, 2013 at 08:49:45PM +0900, Teruaki Ishizaki wrote: Previously sheep.log was saved in the Sheepdog store directory, and used size of Sheepdog store directory included log file size. So, administrator couldn't do capacity planning simply. This patch adds an option for setting

[sheepdog] [PATCH] tests/func: fix output in 'vdi object'

2013-12-09 Thread Liu Yuan
We don't set copies in struct sd_rsp any more so update the tests. Signed-off-by: Liu Yuan namei.u...@gmail.com --- dog/vdi.c|9 +-- tests/functional/028.out | 154 +++--- tests/functional/029.out | 140

[sheepdog] [PATCH 2/2] tests/func: add 080 to test strict mode

2013-12-09 Thread Liu Yuan
Signed-off-by: Liu Yuan namei.u...@gmail.com --- tests/functional/080 | 37 + tests/functional/080.out | 14 ++ tests/functional/group |1 + 3 files changed, 52 insertions(+) create mode 100755 tests/functional/080 create mode 100644

[sheepdog] [PATCH 1/2] sheep: introduce strict mode for write

2013-12-09 Thread Liu Yuan
We make sure we write the exact number of copies to honor the promise of the redundancy for strict mode. This means that after writing of targeted data, they are redundant as promised and can withstand the random node failures. For example, with a 4:2 policy, we need at least write to 6 nodes