[sheepdog] [PATCH v4 0/7] add basic multi-disk support
MORITA Kazutaka
morita.kazutaka at lab.ntt.co.jp
Tue Mar 12 08:15:45 CET 2013
At Tue, 12 Mar 2013 14:00:14 +0800,
Liu Yuan wrote:
>
> From: Liu Yuan <tailai.ly at taobao.com>
>
> v4:
> - some macro name changes
> - init 'ret' in purge_directory()
> - static define some structures
>
> v3:
> - use pstrcpy instead of memcpy
> - s/RAID/MD
> - refine the test group comment
>
> v2:
> - rename raid.c as md.c
> - remove big macro for rmdir_r and purge_directory
> - add md group for tests
>
> This patch set implements the basic multi-disk support that aims to manage
> multiple disks in one node.
>
> The basic idea of this MD is implement RAID-0 like mechanism that distributes
> sheep objects on the local disks without parity or replicating, which instead
> relies on the sheepdog's replicated storage to recover the lost objects on the
> faulty disk.
>
> The md module use a private consistent hash ring per sheep for object
> distributing, which allow md layer completely transparent to sheep node
> managent. This means that hot plug/unplug the disk (include faulty disks) to the
> local sheep won't cause many object movements between the nodes.
>
> This series just implement basic object distribution control of md module. The
> missing part is internal object recovery between local disks inside the node and
> collie command to hot plug/unplug the disk into the sheep daemon, which is meant
> to be written by the next series.
>
> To enable md:
> $ sheep /path/to/meta-store,/path/to/disk1,/path/to/disk2[,...]
>
> We need pass meta-store, which holds sheep's meta information like epoch, config
> as the first parameter.
>
> $ sheep /path/to/store # works the same as before, which doesn't enable md at all.
> Liu Yuan (7):
> md: add dummy md proper
> util: add a helper to purge directory
> sheep, farm: adapt to md support
> sheep: teach stat_sheep to be md friendly
> tests: teach tests to test md feature
> plain: refine init() interface
> tests: add md group to group tests that is md capable
>
> include/util.h | 2 +
> lib/util.c | 30 +++++-
> sheep/Makefile.am | 4 +-
> sheep/farm/farm.c | 70 +++++--------
> sheep/farm/trunk.c | 57 +++++------
> sheep/group.c | 2 +-
> sheep/md.c | 273 +++++++++++++++++++++++++++++++++++++++++++++++++++
> sheep/ops.c | 44 +++------
> sheep/plain_store.c | 147 ++++++++++++---------------
> sheep/sheep.c | 12 ++-
> sheep/sheep_priv.h | 22 +++--
> sheep/store.c | 61 ++++++++----
> tests/check | 9 ++
> tests/common.rc | 6 +-
> tests/group | 91 ++++++++---------
> 15 files changed, 556 insertions(+), 274 deletions(-)
> create mode 100644 sheep/md.c
Applied, thanks!
Kazutaka
More information about the sheepdog
mailing list