NOTE: Please read all instructions carefully before running any of the main 
      FCO scripts.

NOTE: Backup all data on all disks being upgraded by this FCO. Backup any 
      required configuration data (such as SEVM / VxVM / SDS / SLVM or other
      disk management configs or other relevant data needed to recover from 
      a catastrophic failure). Keep this backup data available as a safety
      precaution.

NOTE: You must be root to run the scripts.

NOTE: Before following the instructions to run the FCO scripts, install the
      patch. 

To install the patch:

	a. Copy patch to any temp directory.
	b. Run the Create_fco.sh script. This will un-tar the scripts needed
	   to download new firmware.
	c. Read the rest of this README.111535-03 file  for further 
instructions. 

NOTE: Once FCO has been completed, the patch directory and all files and
      subdirectories under it may be removed.

	  If you want to run independant inquiry on T3 or Photon you can use the 
	  INQUIRY or INQUIRY_T3 commands. 

To run the script for NON-T3 drives do the following:

1. cd to 111535-03/fco directory under this patch

2. Run the script for NON-T3 drives using the following command:

#./main_photon.pl

3. If you replace a drive that has failed, rerun the script (if needed) to 
   update the firmware on the replaced drive(s). The script will allow you to
   download only to Seagate ST39103FC, ST318203FC, and ST136403FC Cheetah3
   drives. (See sample screen below)

NOTE: While running the download utility portion of the scripts, you will
      recieve an "Enter command:" prompt. Enter "p" (program), "?" (help",
      or "q" (quit).

4. Restore target configuration and data (if necessary), and verify proper
   operation of system.

To run the script for T3 drives do the following:

1. cd to 111535-03/fco directory under this patch

2. Before running the main_purple.pl script, create a telnet_session.dat 
   file. The data in this file should follow this format for each T3 being
   upgraded:
    
(IP address of target T3) (T3 root password)

for example:

10.4.42.125 pwd1
10.4.41.224 pwd2
10.4.36.189 pwd3

NOTE: Do not add any blank lines, comments, or additional spaces or tabs 
      before or after any of these lines. The file should contain ONLY the IP
      address, followed by a space, followed by the password. Do only one T3 
      per line.
      
NOTE: Passwords are required for all T3 arrays. If the T3 does not have one,
      assign one for the purposes of this upgrade and remove it after 
      completion of upgrade.

NOTE: The telnet addresses only should be of the current master T3 controller
      from where you are able to do a "sys list" command.

3. All other users should be logged out of the system except for your window 
   running the script. (See sample screen below)

4. Run the script for T3 drives using the following command:

#./main_purple.pl

5. Make sure to read the T3 cmdlog and syslogs, which are all stored under a
   111535-03/fco/logs directory AFTER the tests have completed to check for 
   any drive failures. Replace any drive noted in the logs.

6. If you replace a drive that has failed, rerun the script (if needed) to 
   update the firmware on the replaced drive(s). The script will allow you to
   download only to Seagate ST318203FC and ST136403FC Cheetah3 drives.
   
7. Restore target configuration and data (if necessary), and verify proper
   operation of system.

*******************************************************************************
*******************************************************************************
  SAMPLE T3 SCRIPT OUTPUT:
  
# ./main_purple.pl


#----- Starting Purple Script please do not run any other process
#----- while the script is running and make sure nobody else is
#----- logged in



#----- Initializing the system for detailed information
Start: Health Check Test


#----- Retrieving the telnet information to login to the Purples
#----- listed in the telnet_session.dat file
./e_rt/run_cmd.exp 10.4.42.125 fru list


#----- Doing disk inquiry of all drives in T3 at the Start of Test
.disk version u1d1-9

DISK  VENDOR  PRODUCT         REVISION  SERIAL_NO  FW_REV     ROM_REV
---------------------------------------------------------------------
u1d1  SEAGATE ST318203FSUN18G D94A      LRH80153   052204D9   00010001
u1d2  SEAGATE ST318203FSUN18G D94A      LRJ49461   052204D9   00010001
u1d3  SEAGATE ST318203FSUN18G D94A      LRH89258   052204D9   00010001
u1d4  SEAGATE ST318203FSUN18G D94A      LRJ08219   052204D9   00010001
u1d5  SEAGATE ST318203FSUN18G D94A      LRJ10227   052204D9   00010001
u1d6  SEAGATE ST318203FSUN18G D94A      LRJ44004   052204D9   00010001
u1d7  SEAGATE ST318203FSUN18G D94A      LRJ06234   052204D9   00010001
u1d8  SEAGATE ST318203FSUN18G D94A      LRJ50080   052204D9   00010001
u1d9  SEAGATE ST318203FSUN18G D94A      LRJ18616   052204D9   00010001
pass
qatest:/:<2>


#----- Performing Reads on all available drives


#----- Downloading Code to the T3 this will ftp the code to the T3
#----- and then download to the drives, pls. delete the code from the T3
#----- once the script is over
Download result = spawn /usr/bin/telnet 10.4.42.125 
Trying 10.4.42.125...
Connected to 10.4.42.125.
Escape character is '^]'.


pSOSystem (10.4.42.125)

Login: root
Password: 


T300 Release 1.18.00 2001/11/16 13:35:09 (10.4.42.125)
Copyright (C) 1997-2001 Sun Microsystems, Inc.
All Rights Reserved.

qatest:/:<1>.disk download u1d1 P18lp
 
Download result = spawn /usr/bin/telnet 10.4.42.125 
 


#----- Performing Reads again to check for failures on
#-----  all available drives


DISK  VENDOR  PRODUCT         REVISION  SERIAL_NO  FW_REV     ROM_REV
---------------------------------------------------------------------
u1d1  SEAGATE ST136403FSUN36G DF4A      LT076763   080704DF   Atmel AT49F2048
u1d2  SEAGATE ST136403FSUN36G DF4A      LT086885   080704DF   Atmel AT49F2048
u1d3  SEAGATE ST136403FSUN36G DF4A      LT088237   080704DF   Atmel AT49F2048
u1d4  SEAGATE ST136403FSUN36G DF4A      LT082702   080704DF   Atmel AT49F2048
u1d5  SEAGATE ST136403FSUN36G DF4A      LT088761   080704DF   Atmel AT49F2048
u1d6  SEAGATE ST136403FSUN36G DF4A      LT088959   080704DF   Atmel AT49F2048
u1d7  SEAGATE ST136403FSUN36G DF4A      LT075915   080704DF   Atmel AT49F2048
u1d8  SEAGATE ST136403FSUN36G DF4A      LT079149   080704DF   Atmel AT49F2048
u1d9  SEAGATE ST136403FSUN36G DF4A      LT087101   080704DF   Atmel AT49F2048


#----- Retrieving the syslog and cmdlog for T3
#----- The logs will be stored under logs directory


#----- Restoring system back to orignal state
End: Health Check Test


#----- End:  main_purple script
# 

*******************************************************************************
*******************************************************************************
  SAMPLE PHOTON SCRIPT OUTPUT:
  
# ./main_photon.pl


#----- Starting Photon Script please do not run any other process
#----- while the script is running and make sure nobody else is
#----- logged in



#----- Initializing the system for detailed information
Start: Health Check Test


#----- Generating list of fchannel drives connected to the system


#----- Performing random read operation 8k blk size 1000 ios
a_extdevlist =  /dev/rdsk/c1t0d0s2 /dev/rdsk/c1t1d0s2 /dev/rdsk/c1t2d0s2 
/dev/rdsk/c1t3d0s2 /dev/rdsk/c1t4d0s2 /dev/rdsk/c1t5d0s2 /dev/rdsk/c1t6d0s2 
/dev/rdsk/c1t16d0s2 /dev/rdsk/c1t17d0s2 /dev/rdsk/c1t18d0s2 /dev/rdsk/c1t19d0s2 
/dev/rdsk/c1t21d0s2 /dev/rdsk/c1t22d0s2 

 pp2 -x  8k -r 4194303b -p 1 -R 1000 /dev/rdsk/c1t0d0s2 /dev/rdsk/c1t1d0s2 
/dev/rdsk/c1t2d0s2 /dev/rdsk/c1t3d0s2 /dev/rdsk/c1t4d0s2

 pp2 -x  8k -r 4194303b -p 1 -R 1000 /dev/rdsk/c1t5d0s2 /dev/rdsk/c1t6d0s2 
/dev/rdsk/c1t16d0s2 /dev/rdsk/c1t17d0s2 /dev/rdsk/c1t18d0s2

 pp2 -x  8k -r 4194303b -p 1 -R 1000 /dev/rdsk/c1t19d0s2 /dev/rdsk/c1t21d0s2 
/dev/rdsk/c1t22d0s2 
Total elapsed time = 6 seconds
IOPs            = 833.3
Throughput      = 6826666 bytes/sec
Total elapsed time = 6 seconds
IOPs            = 500.0
Throughput      = 4096000 bytes/sec
Total elapsed time = 7 seconds
IOPs            = 714.3
Throughput      = 5851428 bytes/sec



#----- Downloading Code to the drives

 To download the firmware to the drives Drives :

 Either enter a range of drives or a single drive 

 or type program to download all cheetah 3 drives 

 Enter quit to quit download and proceed with the script :
Firmware Download Utility, V4.2

**************************  WARNING  **************************
NO OTHER ACTIVITY IS ALLOWED DURING FIRMWARE UPGRADE!!!
No other programs including any volume manager (e.g. Veritas,
SDS, or Vold) should be running.  Other host systems sharing
any I/O bus with this host must either be offline or
disconnected.  Any interruption (e.g. power loss) during
upgrade can result in damage to devices being upgraded.

Any disk to be upgraded should first have its data backed up.
***************************************************************

Searching for devices...

WARNING: Kernel device polling is enabled!

DISK DEVICES
Device           Rev   Product               
c1t0d0:          114A  ST136403F -- SUN36G 
c1t1d0:          114B  ST39103FC -- SUN9.0G 
c1t2d0:          D94A  ST136403F -- SUN36G 
c1t3d0:          114A  ST318203F -- SUN18G 
c1t4d0-c1t5d0:   114B  ST39103FC -- SUN9.0G 
c1t6d0:          114A  ST136403F -- SUN36G 
c1t16d0-c1t17d0: 114A  ST318203F -- SUN18G 
c1t18d0-c1t19d0: 114A  ST136403F -- SUN36G 
c1t21d0:         114A  ST318203F -- SUN18G 
c1t22d0:         114B  ST39103FC -- SUN9.0G 
Total Devices:  13


Enter command: p

WARNING: Kernel device polling disabled!
Upgrading devices...
Upgrading devices...

c1t22d0: Successful download
c1t1d0: Successful download
c1t5d0: Successful download
c1t4d0: Successful download
c1t17d0: Successful download
c1t3d0: Successful download
c1t16d0: Successful download
c1t21d0: Successful download
c1t2d0: Successful download
c1t0d0: Successful download
c1t6d0: Successful download
c1t18d0: Successful download
c1t19d0: Successful download
c1: recovery delay, 15 sec.
  c1t22d0:  Page 0x2 defaulted
  c1t5d0:  Page 0x2 defaulted
  c1t1d0:  Page 0x2 defaulted
  c1t4d0:  Page 0x2 defaulted
  c1t3d0:  Page 0x2 defaulted
  c1t17d0:  Page 0x2 defaulted
  c1t16d0:  Page 0x2 defaulted
  c1t21d0:  Page 0x2 defaulted
  c1t2d0:  Page 0x2 defaulted
  c1t0d0:  Page 0x2 defaulted
  c1t6d0:  Page 0x2 defaulted
  c1t19d0:  Page 0x2 defaulted
  c1t18d0:  Page 0x2 defaulted



DISK DEVICES
No devices found to upgrade!


Enter command: q

a_extdevlist =  /dev/rdsk/c1t0d0s2 /dev/rdsk/c1t1d0s2 /dev/rdsk/c1t2d0s2 
/dev/rdsk/c1t3d0s2 /dev/rdsk/c1t4d0s2 /dev/rdsk/c1t5d0s2 /dev/rdsk/c1t6d0s2 
/dev/rdsk/c1t16d0s2 /dev/rdsk/c1t17d0s2 /dev/rdsk/c1t18d0s2 /dev/rdsk/c1t19d0s2 
/dev/rdsk/c1t21d0s2 /dev/rdsk/c1t22d0s2

 pp2 -x  2k -r 4194303b -p 1 -R 1 /dev/rdsk/c1t0d0s2 /dev/rdsk/c1t1d0s2 
/dev/rdsk/c1t2d0s2 /dev/rdsk/c1t3d0s2 /dev/rdsk/c1t4d0s2
Total elapsed time = 0 seconds
IOPs            = Inf
Throughput      = Inf bytes/sec

 pp2 -x  2k -r 4194303b -p 1 -R 1 /dev/rdsk/c1t5d0s2 /dev/rdsk/c1t6d0s2 
/dev/rdsk/c1t16d0s2 /dev/rdsk/c1t17d0s2 /dev/rdsk/c1t18d0s2
Total elapsed time = 0 seconds
IOPs            = Inf
Throughput      = Inf bytes/sec

 pp2 -x  2k -r 4194303b -p 1 -R 1 /dev/rdsk/c1t19d0s2 /dev/rdsk/c1t21d0s2 
/dev/rdsk/c1t22d0s2 
Total elapsed time = 0 seconds
IOPs            = Inf
Throughput      = Inf bytes/sec


#----- Performing random read 2k blk 10 ios for any failures
a_extdevlist =  /dev/rdsk/c1t0d0s2 /dev/rdsk/c1t1d0s2 /dev/rdsk/c1t2d0s2 
/dev/rdsk/c1t3d0s2 /dev/rdsk/c1t4d0s2 /dev/rdsk/c1t5d0s2 /dev/rdsk/c1t6d0s2 
/dev/rdsk/c1t16d0s2 /dev/rdsk/c1t17d0s2 /dev/rdsk/c1t18d0s2 /dev/rdsk/c1t19d0s2 
/dev/rdsk/c1t21d0s2 /dev/rdsk/c1t22d0s2 

 pp2 -x  2k -r 4194303b -p 1 -R 10 /dev/rdsk/c1t0d0s2 /dev/rdsk/c1t1d0s2 
/dev/rdsk/c1t2d0s2 /dev/rdsk/c1t3d0s2 /dev/rdsk/c1t4d0s2

 pp2 -x  2k -r 4194303b -p 1 -R 10 /dev/rdsk/c1t5d0s2 /dev/rdsk/c1t6d0s2 
/dev/rdsk/c1t16d0s2 /dev/rdsk/c1t17d0s2 /dev/rdsk/c1t18d0s2

 pp2 -x  2k -r 4194303b -p 1 -R 10 /dev/rdsk/c1t19d0s2 /dev/rdsk/c1t21d0s2 
/dev/rdsk/c1t22d0s2
Total elapsed time = 0 seconds
IOPs            = Inf
Throughput      = Inf bytes/sec
Total elapsed time = 0 seconds
IOPs            = Inf
Throughput      = Inf bytes/sec
Total elapsed time = 0 seconds
IOPs            = Inf
Throughput      = Inf bytes/sec


#----- Spinning drives down and will spin up using read operation
Issue'ing spin down to /dev/rdsk/c1t0d0s2 
Issue'ing spin down to /dev/rdsk/c1t1d0s2 
Issue'ing spin down to /dev/rdsk/c1t2d0s2 
Issue'ing spin down to /dev/rdsk/c1t3d0s2 
Issue'ing spin down to /dev/rdsk/c1t4d0s2 
Issue'ing spin down to /dev/rdsk/c1t5d0s2 
Issue'ing spin down to /dev/rdsk/c1t6d0s2 
Issue'ing spin down to /dev/rdsk/c1t16d0s2 
Issue'ing spin down to /dev/rdsk/c1t17d0s2 
Issue'ing spin down to /dev/rdsk/c1t18d0s2 
Issue'ing spin down to /dev/rdsk/c1t19d0s2 
Issue'ing spin down to /dev/rdsk/c1t21d0s2 
Issue'ing spin down to /dev/rdsk/c1t22d0s2 


#----- Performing random read 16k blk 1000 ios for any failures
a_extdevlist =  /dev/rdsk/c1t0d0s2 /dev/rdsk/c1t1d0s2 /dev/rdsk/c1t2d0s2 
/dev/rdsk/c1t3d0s2 /dev/rdsk/c1t4d0s2 /dev/rdsk/c1t5d0s2 /dev/rdsk/c1t6d0s2 
/dev/rdsk/c1t16d0s2 /dev/rdsk/c1t17d0s2 /dev/rdsk/c1t18d0s2 /dev/rdsk/c1t19d0s2 
/dev/rdsk/c1t21d0s2 /dev/rdsk/c1t22d0s2

 pp2 -x  16k -r 4194303b -p 1 -R 1000 /dev/rdsk/c1t0d0s2 /dev/rdsk/c1t1d0s2 
/dev/rdsk/c1t2d0s2 /dev/rdsk/c1t3d0s2 /dev/rdsk/c1t4d0s2

 pp2 -x  16k -r 4194303b -p 1 -R 1000 /dev/rdsk/c1t5d0s2 /dev/rdsk/c1t6d0s2 
/dev/rdsk/c1t16d0s2 /dev/rdsk/c1t17d0s2 /dev/rdsk/c1t18d0s2

 pp2 -x  16k -r 4194303b -p 1 -R 1000 /dev/rdsk/c1t19d0s2 /dev/rdsk/c1t21d0s2 
/dev/rdsk/c1t22d0s2
Total elapsed time = 7 seconds
IOPs            = 714.3
Throughput      = 11702857 bytes/sec
Total elapsed time = 8 seconds
IOPs            = 625.0
Throughput      = 10240000 bytes/sec
Total elapsed time = 8 seconds
IOPs            = 625.0
Throughput      = 10240000 bytes/sec


#----- Issuing inquiry to all drives which have new downloaded code
1f0082 : Atmel AT49F2048 : /dev/rdsk/c1t0d0s2, ST136403FSUN36G, 144A, 
LT5160590000 
892275 : Intel 28F200BX-B : /dev/rdsk/c1t1d0s2, ST39103FCSUN9.0G, 144B, 
LS1013560000 
1f0082 : Atmel AT49F2048 : /dev/rdsk/c1t2d0s2, ST136403FSUN36G, 144A, 
LT4771540000 
892275 : Intel 28F200BX-B : /dev/rdsk/c1t3d0s2, ST318203FSUN18G, 144A, 
NM0169190000 
892275 : Intel 28F200BX-B : /dev/rdsk/c1t4d0s2, ST39103FCSUN9.0G, 144B, 
LS0805860000 
892275 : Intel 28F200BX-B : /dev/rdsk/c1t5d0s2, ST39103FCSUN9.0G, 144B, 
LS1024130000 
1f0082 : Atmel AT49F2048 : /dev/rdsk/c1t6d0s2, ST136403FSUN36G, 144A, 
LT4862470000 
892275 : Intel 28F200BX-B : /dev/rdsk/c1t16d0s2, ST318203FSUN18G, 144A, 
NM0260720000 
892275 : Intel 28F200BX-B : /dev/rdsk/c1t17d0s2, ST318203FSUN18G, 144A, 
NM0266490000 
1f0082 : Atmel AT49F2048 : /dev/rdsk/c1t18d0s2, ST136403FSUN36G, 144A, 
LT1803440000 
1f0082 : Atmel AT49F2048 : /dev/rdsk/c1t19d0s2, ST136403FSUN36G, 144A, 
LT1840740000 
892275 : Intel 28F200BX-B : /dev/rdsk/c1t21d0s2, ST318203FSUN18G, 144A, 
NM0261220000 
892275 : Intel 28F200BX-B : /dev/rdsk/c1t22d0s2, ST39103FCSUN9.0G, 144B, 
LS0960670000        


#----- Retrieving the messages file check under logs folder


#----- Restoring state 
End: Health Check Test


#----- End: main_photon script


*******************************************************************************
*******************************************************************************

