7.2 Worldwide Identifiers (WWID)


7.2 Worldwide Identifiers (WWID)

In the previous section, we discussed the device special file naming change and why it changed from the b-t-l naming convention of previous Tru64 UNIX releases. We said that we would tell you how unique cluster-wide naming was accomplished in the next section, and here we are. Unique device special file names are accomplished by using a SCSI worldwide identifier (WWID) to identify storage devices on a standalone system or in a cluster.

Every device is assigned a name the first time it is detected by the operating system. The name starts with a base name (dsk, cdrom, tape, etc.) followed by a number. The numbering begins with zero. Once the device has been recognized, it can be relocated to another bus or another target, etc., and the name remains the same. A WWID is a unique identifier, not unlike a serial number, that most SCSI devices should have. There are exceptions, however, and these include how Tru64 UNIX identifies units from HSZ RAID controllers and older SCSI devices.

7.2.1 WWID formats

Currently, ten WWID formats are defined in the camdb.h header file located in the /usr/sys/include/io/cam directory. The maximum defined size for a WWID is currently 276 bytes (the size of the wwid_dec_unique and wwid_serial_num structures).

Note

The wwid_decoder program can be used to decode the WWID header. The WWID header is the hexadecimal value found after the "SCSI-WWID" in the "name" attribute of a device. This header contains the following information:

  • The type of the WWID.

  • The length of the WWID.

  • Whether or not the WWID is ASCII.

The wwid_decoder program can be downloaded from the TruCluster Server Handbook Web site (see Appendix B for the URL). The following example illustrates the wwid_decoder program.

Get the WWID header from hwmgr(8). First, get the HWID of a storage device.

 # hwmgr –view devices  HWID:    Device Name             Mfg        Model             Location ---------------------------------------------------------------------------------------     4:    /dev/kevm    30:    /dev/disk/floppy0c                 3.5in floppy      fdi0-unit-0    40:    /dev/disk/dsk0c         COMPAQ     BB009235B6        bus-2-targ-0-lun-0    41:    /dev/disk/dsk1c         COMPAQ     BB009235B6        bus-2-targ-1-lun-0    45:    /dev/disk/cdrom0c       COMPAQ     CRD-8402B         bus-0-targ-0-lun-0 

Second, get the WWID header.

 # hwmgr -get attribute -a name -id 41 41:    name = SCSI-WWID:0c000008:0000-0e11-0012-5205 

Finally, run the wwid_decoder.

 # wwid_decoder 0c000008 IEEE EUI (64-bit):   Uses the wwid_p83_ieee64 structure in /usr/sys/include/io/cam/camdb.h.   This is a Page 0x83, ID type 2 (IEEE) WWID -- length is 8 bytes. 

Let's return to the WWID issue and the HSZ RAID controllers. What's the big deal? Well, since a unit can be a number of physical devices, it was determined that units from HSZ RAID controllers would be defined by the combination of the HSZ's serial number concatenated to the unit number. Here's an example.

The first thing we need to do is get a HWID from a device attached to an HSZ.

 # hwmgr -view devices -dsf dsk13  HWID:   Device Name            Mfg       Model          Location ------------------------------------------------------------------------------     81:  /dev/disk/dsk13c       DEC       HSZ70          bus-4-targ-3-lun-3 

Next, we get the attributes for the device that is identified by HWID 81. Note: we are using the cut(1) command to trim off everything but the actual WWID for the device.

 # hwmgr -get attribute –a name -id 81 | cut –d = -f2 81: SCSI-WWID:0910003c:"DEC HSZ70 ZG81110558ZG81110725:d00t00003l00003" 

Figure 7-2 shows the composition of a WWID for a device that is connected to an HSZ controller.

click to expand
Figure 7-2: WWID for the HSZ explained

Let's see what the wwid_decoder program says about the WWID.

 # wwid_decoder 0910003c HSZ Algorithm:    Uses wwid_hsz_this_other structure in /usr/sys/include/io/cam/camdb.h.    This is an HSZ Algorithm WWID (ascii) -- length is 60 bytes. 

As pointed out in the figure and confirmed by the output above, this is an HSZ WWID, which is an ASCII WWID of 60 bytes in length. Notice that the "ZG81110558ZG81110725" portion of the WWID is the serial numbers of the two HSZ controllers concatenated together. Let's see if we can verify this fact. From the console on the HSZ, type "show this". The output will show the serial number of each HSZ controller.

 HSZ70> show this Controller:        HSZ70 ZG81110558 Firmware V77Z-0, Hardware H01        Configured for dual-redundancy with ZG81110725           In dual-redundant configuration ... 

The "this" controller's serial number is "ZG81110558", and the "other" controller's serial number is "ZG81110725".




TruCluster Server Handbook
TruCluster Server Handbook (HP Technologies)
ISBN: 1555582591
EAN: 2147483647
Year: 2005
Pages: 273

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net