When you use more than one tape drive (or tape stacker or medium changer) on a filer, Data ONTAP assigns the addresses on a first-come, first-served basis when the software is installed. However, if a filer shares tape drives, or if tape drives are moved around, the software-assigned addresses do not move with the physical devices. After reboot, these addresses are not necessarily reassigned in the same order.
If you use large or multi-filer configurations, or if your filers share backup tape devices, the filers may assign different names to the same tape drives. Tape aliasing enables you to make sure that the same name is always associated with the same tape drive.
Tape aliasing provides a correspondence between the logical names of backup devices (for example, st0 or mc1) and a name permanently assigned to a port or to a tape drive or medium changer.
Note
st0 and st00 are considered different logical names.
You can use tape aliases as arguments to the dump, restore, and snapmirror store commands.
Note
Logical and worldwide names are used only to access a device. Once accessed, the device returns all error messages using the physical path name.
The two kinds of names available for aliasing are physical path names (PPNs) and worldwide names (WWNs).
Physical path names (PPNs) are the numerical address sequences that Data ONTAP assigns to tape drives and tape libraries based on which SCSI-2/3 adapter or switch (specific location) they are connected to on the filer. PPNs are also known as electrical names.
PPNs of direct-attached devices use the following format:
host_adapter.device_id_lun
For example, the PPN 8.6 indicates that the host adapter number is 8, the device ID is 6, and the logical unit number (LUN) is 0.
Note
On disk drives, the LUN is always 0 and is therefore never shown. On tape drives and medium changers, the LUN is also not shown if it is 0.
PPNs of switch-attached devices use the following format:
switch:port_id.device_id_lun
For example, the PPN MY_SWITCH:5.3L2 indicates that the tape drive connected to port 5 of a switch called MY_SWITCH is set with SCSI ID 3 and has the LUN 2.
The LUN is determined by the drive itself. Both Fibre Channel and SCSI tape drives and libraries, as well as disks, have PPNs.
In the following example, the dump command is using the tape device name of a tape drive:
dump 0f /dev/nrst0a /vol/vol0
In the following example, the same dump command is using the PPN of the tape drive:
dump 0f /dev/nr.MY_SWITCH:5.6.a /vol/vol0
PPNs of tape drives and libraries do not change unless the name of the switch changes, the tape drive or library moves, or the tape drive or library is reconfigured. PPNs remain unchanged after reboot.
For example, if a tape drive named MY_SWITCH:5.3L2 is removed and a new tape drive with the same SCSI ID and LUN is connected to port 5 of switch MY_SWITCH, the new tape drive would be accessible via the name MY_SWITCH:5.3L2.
Tape drives and libraries are assigned worldwide names (WWNs) at the time of manufacture. WWNs are similar to the media access control (MAC) addresses on Ethernet cards. All Fibre Channel devices have WWNs, but SCSI-attached devices do not have WWNs and cannot be accessed by them.
Accessing a tape drive or library via the WWN allows multiple filers to track the same device. Depending on whether a tape drive is connected to a Fibre Channel switch or hub or is directly attached to a Fibre Channel adapter, different filers may have different PPNs for the same device. Using the WWN in these cases eliminates any confusion.
Also, if a switch is renamed or a tape drive is moved on the filer, the WWN of the tape drive or library does not change, and scripts or backup programs do not need to change the name of the tape drive or library to which they are backing up.
The WWN of a tape device uses the following format:
WWN[#:###:######:######]L##
# is a hexadecimal character and L is the LUN of the device. If the LUN is 0, it is not shown.
Each WWN consists of eight bytes, and the format for the WWN is not case-sensitive.
In the following example, the dump command uses the logical name of a tape drive:
dump 0f /dev/nrst0a /vol/vol0
In the following example, the same dump command uses the worldwide name of the tape drive:
dump 0f /dev/nr.WWN[2:000:00e08b:01523e].a /vol/vol0
To display existing aliases of tape drives, complete the following step:
To display information about tape drives and tape libraries (medium changers) to help you assign tape aliases, complete the following step.
| 1 |
storage show {tape | me} [{alias | PPN | WWN}]
alias is the logical name of the tape drive or medium changer. |
storage show tape
Tape Drive: MY_SWITCH:5.3L4
Description: Quantum DLT7000
Serial Number: 12345679
World Wide Name: WWN[2:333:444444:555555]L4
Alias Name(s): st0 st1 st2 st3
Tape Drive: MY_SWITCH:5.3L5
Description: Quantum DLT7000
Serial Number: 12345678
World Wide Name: WWN[2:777:888888:999999]L5
Alias Name(s): st10 st11 st12 st13
storage show tape st0
Tape Drive: MY_SWITCH:5.3L4
Description: Quantum DLT7000
Serial Number: 12345679
World Wide Name: WWN[2:333:444444:555555]L4
Alias Name(s): st0 st1 st2 st3
storage show tape MY_SWITCH:5.3L4
Tape Drive: MY_SWITCH:5.3L4
Description: Quantum DLT7000
Serial Number: 12345679
World Wide Name: WWN[2:333:444444:555555]L4
Alias Name(s): st0 st1 st2 st3
To assign an alias to a tape drive or medium changer, complete the following step.
storage alias st0 MY_SWITCH:5.3L3
storage alias mc80 WWN[2:4e3:38fe3f:758eab]
The tape device st0 is assigned the physical path name MY_SWITCH:5.3L3. The medium changer mc80 is assigned the worldwide name WWN[2:4e3:38fe3f:758eab].
To remove an alias from a tape drive or medium changer, complete the following step.
| 1 |
storage unalias {alias | -a | -m | -t}
alias is the logical name of the tape drive or medium changer from which you want to remove the alias. |
storage unalias st0
storage unalias mc80
The aliases are removed from the tape device st0 and from the medium changer mc80.
If you need to use the same set of tape drives to back up more than one filer, you can save the tape alias information in a file.
To propagate tape aliases to multiple filers, complete the following steps.
To ensure that multiple filers assign the same alias to a tape drive or medium changer, you can type the same set of storage alias commands on each filer.
Alternatively, UNIX users can use a shell script like the following to propagate the source script information to the filers.
#!/bin/sh
# Check for the source file
if [ "$#" != "1" ]
then
echo "Usage: $0 <source_file>"
exit 1
fi
if [ ! -r $1 ]
then
echo "Cannot open source file \"$1\""
exit 1
fi
while [ 1 ]
do
echo Hit ctrl-c to terminate program when all filers have been entered.
# Gather up filer and passwd from user
printf "File Server: "
read FILER
printf "Password: "
read PASSWD
stty -echo
stty echo
printf "\n"
# Now issue the commands in the source script to
# the remote filer.
while read cmd
do
echo Issuing command \"$cmd\" to filer $FILER
rsh $FILER -l root:$PASSWD "$cmd" < /dev/null
done < $1
printf "\n"
done
You can add Fibre-Channel-attached tape drives and libraries to filers dynamically (without taking the filers offline). When the new medium changer is added, the filer detects its presence and adds it to the configuration. If the medium changer is already referenced in the alias information, no new logical names are created. If the library is not referenced, the filer creates a new alias for the medium changer.
Copyright © 1994-2003, Network Appliance, Inc. All rights
reserved.
Part No. 210-00546
File: tape5.htm
Last updated: 12/02/03 18:26:25