[Sheepdog] add iscsi support

FUJITA Tomonori fujita.tomonori at lab.ntt.co.jp
Mon Oct 4 12:44:38 CEST 2010


Hello,

I implemented iscsi target support over sheepdog:

git://git.kernel.org/pub/scm/linux/kernel/git/tomo/tgt.git sheepdog

iSCSI target daemon (tgt) can provide qemu sheepdog image files as
SCSI logical units to iSCSI initiators.

You need to run tgt daemon on a host that sheep daemon runs on.

Shortly, what I try to do is converting a sheepdog storage cluster
into an iSCSI storage cluster (something like HP's lefthand).

I'm still thinking about how to handle node failure. That is, tgt
daemons needs to get the node failure information from sheep daemon
and one node in the cluster need to take over the volume that the
failed tgt daemon provided.

Currently, cow or snapshot vdi isn't supported. So you need to create
a qemu sheepdog image with the following patch:

http://lists.wpkg.org/pipermail/sheepdog/2010-October/000706.html

Anyone is interested?


the following example is for people that already use tgt:

fujita at rose:~$ ./git/sheepdog/collie/collie vm list
    Name            |Vdi size |Allocated| Shared  | Status
    ----------------+---------+---------+---------+------------
    test14          |   512 MB|   512 MB|   0.0 MB| not running
    
You can use sheepdog vdi name as a path like this:
    
tgtadm --op new --mode logicalunit --tid 1 --lun 1 -b test14 --bstype sheepdog

root at rose:~/git/tgt# tgtadm --op show --mode target
Target 1: iqn.2001-04.com.example:storage.sr.rose.sys1.xyz
    System information:
        Driver: iscsi
        State: ready
    I_T nexus information:
        I_T nexus: 1
            Initiator: iqn.2005-03.org.open-iscsi:e4441d4e4616
            Connection: 0
                IP Address: 10.76.0.30
    LUN information:
        LUN: 0
            Type: controller
            SCSI ID: IET     00010000
            SCSI SN: beaf10
            Size: 0 MB
            Online: Yes
            Removable media: No
            Readonly: No
            Backing store type: null
            Backing store path: None
            Backing store flags: 
        LUN: 1
            Type: disk
            SCSI ID: IET     00010001
            SCSI SN: beaf11
            Size: 537 MB
            Online: Yes
            Removable media: No
            Readonly: No
            Backing store type: sheepdog
            Backing store path: test14
            Backing store flags: 
    Account information:
    ACL information:
        ALL





More information about the sheepdog mailing list