Re: can't add members to non-default ALUA groups

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Nicholas,

Thanks a lot, it does exactly what I need.

Best regards,


Yuri


On Thu, 06 Feb 2014 14:56:04 -0800
"Nicholas A. Bellinger" <nab@xxxxxxxxxxxxxxx> wrote:

> Hi Yuri,
> 
> On Wed, 2014-02-05 at 15:33 +0400, Yuri Arapov wrote:
> > Hi list,
> > 
> > I'm working on Fibre Channel LIO setup featuring MPIO and ALUA.
> > 
> > My idea is to export the same backstore object as different LUNs
> > of two different FC targets, then create two ALUA groups and make
> > those two LUNs be members of my custom ALUA groups.
> > 
> > So I created my backstore object (fileio_0/file0), and exported
> > it as LUNs of two FC targets:
> > 
> > /> ls qla2xxx/21:00:00:0e:1e:15:e3:40/luns
> > o-
> > luns ......................................................................
> > [2 LUNs] o-
> > lun0 ..................................................
> > [iblock/disk0 (/dev/ram0)] o-
> > lun1 ................................... [fileio/file0
> > (/root/target-backstore-0)] /> ls
> > qla2xxx/21:00:00:0e:1e:15:e3:41/luns o-
> > luns ......................................................................
> > [2 LUNs] o- lun0 ...................................
> > [fileio/file0 (/root/target-backstore-0)] o-
> > lun1 ..................................................
> > [iblock/disk1 (/dev/ram1)] Then I created two ALUA groups "north"
> > and "south":
> > 
> > tcm_node --addaluatpgwithmd fileio_0/file0 north 1
> > tcm_node --addaluatpgwithmd fileio_0/file0 south 2
> > 
> > (See complete setup "tcm_dump.txt" attached to this mail.)
> > 
> 
> So this first step is correct, but note it's only creating the
> 'north' and 'south' ALUA target port groups for the fileio_0/file0
> backend device, and not doing the actual association of an FC
> fabric LUN to either one.
> 
> > 
> > Now when I check for group members I don't see any in my custom
> > ALUA groups:
> > 
> > tcm_node --listtgptgps fileio_0/file0
> > \------> south  Target Port Group ID: 2
> >          Active ALUA Access Type(s): Implict and Explict
> >          Primary Access State: Active/Optimized
> >          Primary Access Status: Altered by Implict ALUA
> >          Preferred Bit: 0
> >          Active/NonOptimized Delay in milliseconds: 100
> >          Transition Delay in milliseconds: 0
> >          \------> TG Port Group Members
> >              No Target Port Group Members
> > \------> north  Target Port Group ID: 1
> >          Active ALUA Access Type(s): Implict and Explict
> >          Primary Access State: Active/Optimized
> >          Primary Access Status: Altered by Implict ALUA
> >          Preferred Bit: 0
> >          Active/NonOptimized Delay in milliseconds: 100
> >          Transition Delay in milliseconds: 0
> >          \------> TG Port Group Members
> >              No Target Port Group Members
> > \------> default_tg_pt_gp  Target Port Group ID: 0
> >          Active ALUA Access Type(s): Implict and Explict
> >          Primary Access State: Active/Optimized
> >          Primary Access Status: Altered by Implict ALUA
> >          Preferred Bit: 0
> >          Active/NonOptimized Delay in milliseconds: 100
> >          Transition Delay in milliseconds: 0
> >          \------> TG Port Group Members
> >              qla2xxx/naa.2100000e1e15e340/tpgt_1/lun_1
> >              qla2xxx/naa.2100000e1e15e341/tpgt_1/lun_0
> > 
> > As I checked all the "members" files
> > in /sys/kernel/config/target/core/ directory are read-only, so I
> > wasn't able to modify them by hand.
> > 
> > 
> > So my question is how can I add members to my own custom ALUA
> > groups?
> > 
> > 
> 
> The easiest way to do this with FC is to explicitly set the ALUA
> target port group for a fabric LUN directly in configfs, like so:
> 
>   echo $ALUA_TG_PT_GP_NAME
> > /sys/kernel/config/target/qla2xxx/$FC_WWPN/tpgt_1/lun/$LUN_ID/alua_tg_pt_gp
> 
> and then you can verify the new association with:
> 
>   cat /sys/kernel/config/target/qla2xxx/$FC_WWPN/tpgt_1/lun/$LUN_ID/alua_tg_pt_gp
> 
> Note these will automatically reinstated upon target restart after a
> targetcli 'saveconfig'.
> 
> --nab
> 


-- 
Yuri Arapov <yarapov@xxxxxxxxxxxxxxx>
--
To unsubscribe from this list: send the line "unsubscribe target-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux SCSI]     [Kernel Newbies]     [Linux SCSI Target Infrastructure]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Device Mapper]

  Powered by Linux