[Stgt-devel] [PATCH] tgt-admin: support persistent device binding

FUJITA Tomonori fujita.tomonori
Mon Jul 28 13:50:00 CEST 2008


On Mon, 28 Jul 2008 14:37:52 +0300
"Eli Dorfman" <dorfman.eli at gmail.com> wrote:

> >> Signed-off-by: Doron Shoham <dorons at voltaire.com>
> >> ---
> >>  doc/manpages/tgt-admin.8 |    3 ++
> >>  scripts/tgt-admin        |   64 ++++++++++++++++++++++++++++++++++-----------
> >>  2 files changed, 51 insertions(+), 16 deletions(-)
> >>
> >> diff --git a/doc/manpages/tgt-admin.8 b/doc/manpages/tgt-admin.8
> >> index 97d6484..5598932 100644
> >> --- a/doc/manpages/tgt-admin.8
> >> +++ b/doc/manpages/tgt-admin.8
> >> @@ -85,6 +85,9 @@ example for a configuration file:
> >>  <target iqn.2007-02.com.example:san.xen1>
> >>     backing-store /dev/san/xen1-disk1 # LUN1
> >>     direct-store /dev/san/xen1-disk2 # LUN2
> >> +   # for persistent binding use scsi serial number
> >> +   backing-store 00c0ffd508d70048ed1dbc4704000000 #LUN3
> >> +   direct-store 00c0ffd508d70048ed1dbc4704000001 # LUN4
> >
> > I'm not sure about direct-store thing at all. They are
> > confusing. direct-store is backing-store.
> 
> basically you are right, but we need a way to export real physical
> serial number to the initiator so that we can use multipath.
> The direct-store attribute is used to allow exporting real physical
> device with its properties like: serial number, vendor, etc
> 
> we also need away to export a virtual device with explicit device
> properties (serial number, vendor, etc) and not use the auto generated
> deadbeaf ids.

I know that.


> maybe use the following format :
> <target xyz>
>     <backing-store /dev/sdb>
>           properties  custom # use properties specified below or
> default (generate the deadbeaf id) or direct (get real serial number)
>           serial-number 12345678
>           vendor myvendor
>     </backing-store>
> </target>
> 
> what do you think?

Hmm, 'properties custom' looks unnecessary for me. If a device file of
a disk drive is used as backing-store and none of the properties are
specified, we can use the physical properties.

And if an administrator wants to use a disk drive as backing-store, he
should use /dev/disk/by-id/* files instead of changeable /dev/sd* files.

Except for those, it looks sane for me.

Well, I don't like a XML format but I can live with it if people are
happy about that.



More information about the stgt mailing list