TopL TopM TopR
MiddleL

Configuring Tape Devices on AIX with NPIV and VIOS

This quick tip provides some insight into what to expect when configuring tape drives on AIX with Virtual Fibre Channel adapters, the Virtual I/O Server (VIOS), and NPIV.

In this environment, the 8GB Fibre Channel (FC) adapters (Feature Code 5735) have been assigned to the Virtual I/O Servers. A single dual-port 8GB FC adapter is assigned to each VIOS. These adapters are dedicated for use with tape only. The tape library in question is an IBM TS3310.

The AIX LPARs were initially configured with Virtual FC adapters for connectivity to FC SAN disk (XIV). As shown in the lspath output below, fcs0 through fcs3 are used exclusively for access to disk only.

# lsdev -Cc adapter | grep fcs
fcs0 Available 30-T1 Virtual Fibre Channel Client Adapter
fcs1 Available 31-T1 Virtual Fibre Channel Client Adapter
fcs2 Available 32-T1 Virtual Fibre Channel Client Adapter
fcs3 Available 33-T1 Virtual Fibre Channel Client Adapter
  
# lspath
Enabled hdisk0  fscsi0
Enabled hdisk0  fscsi0
Enabled hdisk0  fscsi0
Enabled hdisk0  fscsi0
Enabled hdisk0  fscsi1
Enabled hdisk0  fscsi1
Enabled hdisk0  fscsi1
Enabled hdisk0  fscsi1
Enabled hdisk0  fscsi2
Enabled hdisk0  fscsi2
Enabled hdisk0  fscsi2
Enabled hdisk0  fscsi2
Enabled hdisk0  fscsi3
Enabled hdisk0  fscsi3
Enabled hdisk0  fscsi3
Enabled hdisk0  fscsi3
..etc.. for the other disks on the system

In order for us to connect to our tape drives (of which there were four in total in the TS3310), we configured four additional virtual FC adapters for the LPAR.

 First we ensured that the physical adapters were available and had fabric connectivity. On both VIOS, we used the lsnports command to determine the state of the adapters and their NPIV capability. As shown in the following output, the physical adapter’s fcs4 and fcs5 were both available and NPIV ready (i.e. there was a 1 in the fabric column. If it was zero then the adapter may not be connected to an NPIV capable SAN).

$ lsnports
name             physloc                        fabric tports aports swwpns  awwpns
fcs0             U78A0.001.DNWK4W9-P1-C3-T1          1     64     52   2048    1988
fcs1             U78A0.001.DNWK4W9-P1-C3-T2          1     64     52   2048    1988
fcs2             U5877.001.0084548-P1-C1-T1          1     64     61   2048    2033
fcs3             U5877.001.0084548-P1-C1-T2          1     64     61   2048    2033
fcs4             U5877.001.0084548-P1-C2-T1          1     64     64   2048    2048
fcs5             U5877.001.0084548-P1-C2-T2          1     64     64   2048    2048

When I initially checked the state of the adapters on both VIOS, I encountered the following output from lsnports

$ lsnports
name             physloc                        fabric tports aports swwpns  awwpns
fcs0             U78A0.001.DNWK4W9-P1-C3-T1          1     64     52   2048    1988
fcs1             U78A0.001.DNWK4W9-P1-C3-T2          1     64     52   2048    1988
fcs2             U5877.001.0084548-P1-C1-T1          1     64     61   2048    2033
fcs3             U5877.001.0084548-P1-C1-T2          1     64     61   2048    2033
fcs4             U5877.001.0084548-P1-C2-T1          0     64     64   2048    2048 

As you can see, only the fcs4 adapter was discovered, fcs5 was missing and the fabric value for fcs4 was 0. Both of these issues were the result of physical connectivity issues to the SAN. The cables were unplugged and/or they had a loopback adapter plugged into the interface. There was an error in the error report indicating link errors on fcs4 but not for fcs5.

$ errlog
IDENTIFIER TIMESTAMP  T C RESOURCE_NAME  DESCRIPTION
7BFEEA1F   0502104011 T H fcs4           LINK ERROR

Once the ports were physically connected to the SAN switches, I removed the entry for fcs4 from the ODM (as shown below) and then ran cfgmgr on the VIOS.

$ r oem
oem_setup_env
# rmdev -dRl fcs4
fcnet4 deleted
sfwcomm4 deleted
fscsi4 deleted
fcs4 deleted
# cfgmgr
# exit
$

Then both fcs4 and fcs5 were discovered and configured correctly.

$ lsnports
name             physloc                        fabric tports aports swwpns  awwpns
fcs0             U78A0.001.DNWK4W9-P1-C3-T1          1     64     52   2048    1988
fcs1             U78A0.001.DNWK4W9-P1-C3-T2          1     64     52   2048    1988
fcs2             U5877.001.0084548-P1-C1-T1          1     64     61   2048    2033
fcs3             U5877.001.0084548-P1-C1-T2          1     64     61   2048    2033
fcs4             U5877.001.0084548-P1-C2-T1          1     64     64   2048    2048
fcs5             U5877.001.0084548-P1-C2-T2          1     64     64   2048    2048

Our next step was to configure the new virtual FC host adapters on the VIOS and the new virtual FC adapters on the client LPAR. Below is a conceptual diagram of how the LPAR would connect to the tape drives.

Gibson-June14-2010.jpg

 

As you can see, each VIO server has a single two port FC adapter which is dedicated for tape. These adapter ports appear as fcs4 and fcs5 on each VIO server (vio1 and vio2).

The AIX LPAR (tsm1) has additional Virtual FC adapters, dedicated for tape as well. These adapters appear as fcs4, fcs5, fcs6 and fcs7.

The plan was for fcs4 on tsm1 to map to fcs4 on vio1, fcs5 to map to fcs5 on vio1 and fcs6 to map to fcs4 on vio2 and fcs7 to map to fcs5 on vio2.

The virtual adapter slot configuration was as follows:

LPAR: tsm1                      VIOS: vio1
U8233.E8B.06XXXXX-V4-C34-T1 >   U8233.E8B.06XXXXX-V1-C60         
U8233.E8B.06XXXXX-V4-C35-T1 >   U8233.E8B.06XXXXX-V1-C61        
  
LPAR: tsm1                      VIOS: vio2
U8233.E8B.06XXXXX-V4-C36-T1 >   U8233.E8B.06XXXXX-V2-C60         
U8233.E8B.06XXXXX-V4-C37-T1 >   U8233.E8B.06XXXXX-V2-C61

We created two new virtual FC host adapters on vio1 and two new virtual FC host adapters on vio2. This was done by updating the LPARs profile (on the HMC) with the new adapters and then adding them with a DLPAR operation on each VIOS. Once we had run the cfgdev command on each VIOS, to bring in the new virtual FC host adapters, next we needed to map them to the physical FC ports.

Using the vfcmap command on each of the VIOS, we mapped the physical ports to the virtual host adapters as follows:

1.     Map tsm1 vfchost30 adapter to physical FC adapter fcs4 on vio1.

$ vfcmap –vadpater vfchost30 –fcp fcs4

2.     Map tsm1 vfchost31 adapter to physical FC adapter fcs5 on vio1.

$ vfcmap –vadapter vfchost31 – fcp fcs5

3.     Map tsm1 vfchost30 adapter to physical FC adapter fcs4 on vio2.

$ vfcmap –vadapter vfchost30 – fcp fcs4

4.     Map tsm1 vfchost31 adapter to physical FC adapter fcs5 on vio2.

$ vfcmap –vadapter vfchost31 –fcp fcs5

Next we used DLPAR (using the following procedure) to update the client LPAR with four new virtual FC adapters. After running the cfgmgr command on the LPAR, we confirmed we had four new virtual FC adapters. We ensured that we saved the LPARs current configuration, as outlined in the procedure.

# lsdev –Cc adapter  grep fcs
fcs0       Available 30-T1       Virtual Fibre Channel Client Adapter
fcs1       Available 31-T1       Virtual Fibre Channel Client Adapter
fcs2       Available 32-T1       Virtual Fibre Channel Client Adapter
fcs3       Available 33-T1       Virtual Fibre Channel Client Adapter
fcs4       Available 34-T1       Virtual Fibre Channel Client Adapter
fcs5       Available 35-T1       Virtual Fibre Channel Client Adapter
fcs6       Available 36-T1       Virtual Fibre Channel Client Adapter
fcs7       Available 33-T1       Virtual Fibre Channel Client Adapter

On both VIOS, we confirmed that the physical to virtual mapping on the FC adapters was correct using the lsmap –all –npiv command. Also checking that client LPAR had successfully logged into the SAN by noting the Status: LOGGED_IN entry in the lsmap output for each adapter.

vio1:
Name          Physloc                            ClntID ClntName       ClntOS
------------- ---------------------------------- ------ -------------- -------
vfchost30     U8233.E8B.06XXXXX-V1-C60                4 tsm1           AIX
  
Status:LOGGED_IN
FC name:fcs4                    FC loc code:U5877.001.0084548-P1-C2-T1
Ports logged in:1
Flags:a<LOGGED_IN,STRIP_MERGE>
VFC client name:fcs4            VFC client DRC:U8233.E8B.06XXXXX-V4-C34-T1
  
Name          Physloc                            ClntID ClntName       ClntOS
------------- ---------------------------------- ------ -------------- -------
vfchost31     U8233.E8B.06XXXXX-V1-C61                4 tsm1           AIX
  
Status:LOGGED_IN
FC name:fcs5                    FC loc code:U5877.001.0084548-P1-C2-T2
Ports logged in:1
Flags:a<LOGGED_IN,STRIP_MERGE>
VFC client name:fcs5            VFC client DRC:U8233.E8B.06XXXXX-V4-C35-T1
  
  
vio2:
Name          Physloc                            ClntID ClntName       ClntOS
------------- ---------------------------------- ------ -------------- -------
vfchost30     U8233.E8B.06XXXXX-V2-C60                4 tsm1           AIX
  
Status:LOGGED_IN
FC name:fcs4                    FC loc code:U5877.001.0084548-P1-C5-T1
Ports logged in:1
Flags:a<LOGGED_IN,STRIP_MERGE>
VFC client name:fcs6            VFC client DRC:U8233.E8B.06XXXXX-V4-C36-T1
  
Name          Physloc                            ClntID ClntName       ClntOS
------------- ---------------------------------- ------ -------------- -------
vfchost31     U8233.E8B.06XXXXX-V2-C61                4 tsm1           AIX
  
Status:LOGGED_IN
FC name:fcs5                    FC loc code:U5877.001.0084548-P1-C5-T2
Ports logged in:1
Flags:a<LOGGED_IN,STRIP_MERGE>
VFC client name:fcs7            VFC client DRC:U8233.E8B.06XXXXX-V4-C37-T1

We were able to capture the WWPNs for the new adapters at this point. This information was required in order to zone the tape drives to the system.

# for i in 4 5 6 7
> do
> echo fcs$i
> lscfg -vpl fcs$i | grep Net
> echo
> done
fcs4
        Network Address.............C0507603A2920088
  
fcs5
        Network Address.............C0507603A292008A
  
fcs6
        Network Address.............C0507603A292008C
  
fcs7
        Network Address.............C0507603A292008E

The IBM Atape device drivers were installed prior to zoning in the TS3310 tape drives.

# lslpp -l | grep -i atape
  Atape.driver              12.2.4.0  COMMITTED  IBM AIX Enhanced Tape and

Then, once the drives had been zoned to the new WWPNs, we ran cfgmgr on the AIX LPAR to configure the tape drives.

# lsdev -Cc tape
#
# cfgmgr
# lsdev -Cc tape
rmt0 Available 34-T1-01-PRI IBM 3580 Ultrium Tape Drive (FCP)
rmt1 Available 34-T1-01-PRI IBM 3580 Ultrium Tape Drive (FCP)
rmt2 Available 35-T1-01-ALT IBM 3580 Ultrium Tape Drive (FCP)
rmt3 Available 35-T1-01-ALT IBM 3580 Ultrium Tape Drive (FCP)
rmt4 Available 36-T1-01-PRI IBM 3580 Ultrium Tape Drive (FCP)
rmt5 Available 36-T1-01-PRI IBM 3580 Ultrium Tape Drive (FCP)
rmt6 Available 37-T1-01-ALT IBM 3580 Ultrium Tape Drive (FCP)
rmt7 Available 37-T1-01-ALT IBM 3580 Ultrium Tape Drive (FCP)
smc0 Available 34-T1-01-PRI IBM 3576 Library Medium Changer (FCP)
smc1 Available 35-T1-01-ALT IBM 3576 Library Medium Changer (FCP)
smc2 Available 37-T1-01-ALT IBM 3576 Library Medium Changer (FCP)

Our new tape drives were now available on our AIX system. These drives were to be used with Tivoli Storage Manager (TSM).

Please refer to the following links for more information relating to virtual Fibre Channel configuration in a VIOS environment and TSM support for NPIV and tape.

IBM PowerVM Virtualization Managing and Monitoring

   http://www.redbooks.ibm.com/abstracts/sg247590.html

PowerVM – Dynamically adding a Virtual Fibre Channel adapter to a client partition

http://www.aixmind.com/?p=798

IBM Tivoli Storage Manager for AIX Server Requirements and Support

http://www-01.ibm.com/support/docview.wss?uid=swg21052220

IBM Tivoli Storage FlashCopy Manager, Version 2.2: Supported storage subsystems

http://publib.boulder.ibm.com/infocenter/tsminfo/v6r2/topic/com.ibm.itsm.fcm.unx.doc/c_fcmu_ovr_supstorage.html

Using NPIV in TSM Client with Storage Agent installed

http://www.ibm.com/developerworks/wikis/display/tivolistoragemanager/Using+NPIV+in+TSM+Client+with+Storage+Agent+installed


Chris Gibson
 is an AIX enterprise systems engineer for Southern Cross Computer Systems. Follow him on Twitter: 
@cgibbo.

Popular tags: , ,

Comments

Was it good for you, too?Join the discussion » ,but you need to login first before you make comments.

     

    Other Recent Comments

    1. Re: Easy Ways to Trace VSCSI Configuration with AIX

      No Anthony, it's not so obvious. As you see, I've removed first paths and after that I changed vscsi...

      --Andrey Klyachkin

    2. Re: Easy Ways to Trace VSCSI Configuration with AIX

      Thanks, Andrey. Your test shows that if one path is down, then its corresponding VSCSI adapter isn't...

      --Anthony English

    3. Re: Easy Ways to Trace VSCSI Configuration with AIX

      Test with rmpath/cvai:# lspath -l hdisk1 -F parentvscsi0vscsi1# lspath -l hdisk0 -F parentvscsi0vscs...

      --Andrey Klyachkin

    4. Re: IBM Reveals PowerLinux Details and Pricing

      Thanks for the tip, Bill -- much appreciated! (I must say, though, we'll have to wrangle a few Power...

      --Chris Maxcer

    5. Re: IBM Reveals PowerLinux Details and Pricing

      http://www.ibm.com/developerworks/group/tpl

      --Bill Buros

    Google Links

    Sponsored Links

    Featured Links

    MiddleR
    BottomL BottomM BottomR

    © Penton Media, Inc.