$  Copyright(c) 2002 Sun Microsystems, Inc.
$  All rights reserved.
$
$ switch2test.msg
$


$ --------------------------------------------------
$ DEBUG:	0
$ --------------------------------------------------

$ --------------------------------------------------
$ VERBOSE:	1-1999
$ --------------------------------------------------

$ USAGE
2 "Usage:\nswitch2test [-o \"option=value|option=value|...\"]\n\n \
\tdev=<port:ip_address:fcaddr> \t(no default)\n \
\txfersize=<number>\t\t(default=100),\n \
\titerations=<number>\t\t(default=5000),\n \
\tuserpattern=<0xpattern>\t\t(default=7e7e7e7e),\n \
\tselectpattern=<user,critical,all> (default=critical)\n\
\tpasswd=<admin password(For 2 gig switches)/ root passsword(For 1 gig switches)> (default=none)\n\n\
NOTE: Must use \" \" around options.\n\
ie: switch2test -o \"dev=7:172.20.67.198:0|xfersize=250|passwd=mypassword\"\n



$ V_OPTIONS_LIST
3 "Called with options: %s"

$ CONNECTED
4 "Connected to %s"

$ TEST_PASSED
5 "Test Passed"

$ ORIG_PORT_COUNTS
6 "Get original port counters for port %d"


$ LAST_PORT_COUNTS
7 "Get port counters after testing for port %d"

$ PORT_COUNTS_OKAY
8 "Compare of port counters passed"

$ LOOPBACK_DETECTED
9 "Detected port to be in OFFLINE or Diagnostic mode"

$ PORT_TYPE
10 "Detected port type %s"

$ ONLINE_STARTED
11 "Online test with pattern 0x%08x"

$ EXTERNAL_PASSED
12 "External loopback test passed"

$ ENVIRON_OKAY
13 "Power, Fans and Temperature are okay"


$ SWITCH_MODEL_TYPE
14 "Switch Model type is: %s"

$ TESTING_PORT
15 "Starting test on port %d with version %s of switch2test"

$ WARNING_ADJUSTING_XFER_SIZE
4000 "Maximum transfer size for a FABRIC port is 200. Changing transfer size %d to 200"

$ WARNING_ADJUSTING_E_XFER_SIZE
4001 "Maximum transfer size for a E port port is 256. Changing transfer size %d to 256"

$ BAD_PASSWORD
6000 "No password was passed in. Please check command line options."

$ BAD_PORT_OPTION
6001 "Bad port was passed in. Please check command line options."

$ BAD_DEVICE_NAME
6002 "Bad device name was passed in. Please check command line options."

$ BAD_IP_OPTION
6003 "Bad IP name was passed in. Please check command line options."

$ BAD_XFER_OPTION
6004 "Bad transfer size was passed in. Please check command line options."

$ BAD_XFER_SIZE_OPTION
6005 "Invalid transfer size was passed in: %d. Size must be between 36 and 2112.\
Please check command line options."

$ BAD_PASSES_OPTION
6006 "Bad number of passes passed in. Please check command line options."

$ BAD_PATTERN_OPTION
6007 "Bad pattern passed in. Please check command line options."


$ BAD_CHOICE_OPTION
6008 "Bad pattern choice passed in. Please check command line options."

$ BAD_UNKNOWN_OPTION
6009 "Unknown option passed to test. Please check command line options."

$ FAILED_TO_CONNECT
6010 "Failed to connect to switch. Return code = %d"\
Probable_Cause(s):<Invalid IP address>\
<Bad Ethernet Connection>\
<No Power to switch>\
Recommended_Action(s):\
<Check command line options>\
<Check Ethernet Connection>\
<Check Power>\
<if the problem persists, contact authorized Sun service provider>

$ ORIG_PORT_COUNTS_ERR
6011 "Failed to get original port counts. Return code = %d"\
Probable_Cause(s):<Bad Switch>\
Recommended_Action(s):\
<Replace switch>

$ LAST_PORT_COUNTS_ERR
6012 "Failed to get port counts after testing. Return code = %d"\
Probable_Cause(s):<Bad Switch>\
Recommended_Action(s):\
<Replace switch>

$ ADDRESS_ERRORS
6013 "Detected Address Errors during testing. Original count = %d, after testing = %d"\
Probable_Cause(s):<Bad SFP>\
<Bad Fiber Cable>\
<Bad Switch>\
Recommended_Action(s):\
<Replace SFP>\
<Replace Fiber Cable>\
<Replace Switch>

$ INVALID_CRC_ERR
6014 "Detected Invalid CRC Errors during testing. Original count = %d, after testing = %d"\
Probable_Cause(s):<Bad SFP>\
<Bad Fiber Cable>\
<Bad Switch>\
Recommended_Action(s):\
<Replace SFP>\
<Replace Fiber Cable>\
<Replace Switch>

$ OFFLINE_SEQUENCE_ERROR
6015 "Detected Offline Sequences during testing. Original count = %d, after testing = %d"\
Probable_Cause(s):<Bad SFP>\
<Bad Fiber Cable>\
<Bad Switch>\
Recommended_Action(s):\
<Replace SFP>\
<Replace Fiber Cable>\
<Replace Switch>



$ PORT_ATTRIBUTES_FAILED
6016 "Failed to get port attributes. Return code = %d"\
Probable_Cause(s):<Bad Switch>\
<Ethernet problems>
Recommended_Action(s):\
<Replace switch>\
<Check Ethernet connections>

$ ONLINE_FAILED_START
6017 "Online loopback test failed to start. Return code = %d on pattern 0x%x"\
Probable_Cause(s):<Bad SFP>\
<Bad Fiber Cable>\
<Bad Switch>\
Recommended_Action(s):\
<Replace SFP>\
<Replace Fiber Cable>\
<Replace Switch>

$ ONLINE_TESTSTATUS_FAILED
6018 "Failed to get test status. Return code = %d"\
Probable_Cause(s):<Bad SFP>\
<Bad Fiber Cable>\
<Bad Switch>\
Recommended_Action(s):\
<Replace SFP>\
<Replace Fiber Cable>\
<Replace Switch>

$ ONLINE_TEST_FAILED
6019 "Online test failed. Return code = %s on pattern 0x%x"\
Probable_Cause(s):<Bad SFP>\
<Bad Fiber Cable>\
<Bad Switch>\
<Connected to a device that doesn't support ECHO commands>\
Recommended_Action(s):\
<Replace SFP>\
<Replace Fiber Cable>\
<Replace Switch>\
<Insert a loopback cable and rerun the test>

$ EXTERNAL_FAILED_START
6020 "Loopback test failed to start. Return code = %d"\
Probable_Cause(s):<Bad SFP>\
<Bad Fiber Cable>\
<Bad Switch>\
Recommended_Action(s):\
<Replace SFP>\
<Replace Fiber Cable>\
<Replace Switch>

$ EXTERNAL_FAILED
6021 "Loopback test failed to start"\
Probable_Cause(s):<Bad SFP>\
<Bad Fiber Cable>\
<Bad loopback/no loopback plug inserted>\
<Bad Switch>\
Recommended_Action(s):\
<Run linktest>\
<Replace SFP>\
<Replace Fiber Cable>\
<Replace/Insert loopback plug and test again>\
<Replace Switch>

$ ENVIRON_CALL_ERROR

$ ORIG_PORT_COUNTS_ERR
6022 "Failed to get environmental data. Return code = %d"\
Probable_Cause(s):<Bad Switch>\
Recommended_Action(s):\
<Replace switch>


$ BAD_POWER_SUPPLY
6023 "Detected a problem with power supply %d"\
Probable_Cause(s):<Uninstalled power supply>\
<Bad power supply>\
Recommended_Action(s):\
<Install power supply>\
<Replace power supply>

$ BAD_FAN
6024 "Detected a problem with fan %d"\
Probable_Cause(s):<Uninstalled fan>\
<Bad fan>\
Recommended_Action(s):\
<Install fan>\
<Replace fan>

$ GET_CONFIG_FAILED
6025 "Failed to get configuration data. Return code = %d"\
Probable_Cause(s):<Bad Switch>\
Recommended_Action(s):\
<Replace switch>


$ SET_CONFIG_FAILED
6026 "Failed to set configuration for loopback testing. Return code = %d"\
Probable_Cause(s):<Bad Switch>\
Recommended_Action(s):\
<Replace switch>

$ WRONG_PORT_MODE
6027 "Detected port to be in a diagnostic mode."\
Probable_Cause(s):<Port is configured to be in a diagnostic mode>\
<Bad SFP>\
<Bad port>\
Recommended_Action(s):\
<Configure port to be online>\
<Replace SFP>\
<Replace Switch>

$ WRONG_PORT_MODE_OFFLINE
6028 "Detected port to be offline."\
Probable_Cause(s):<Port is configured to be offline>\
<Bad SFP>\
<Bad Fiber channel Cable>\
<Bad port>\
Recommended_Action(s):\
<Configure port to be online>\
<Run linktest>\
<Replace SFP>\
<Replace Fiber Cable>\
<Replace Switch>


$ SWITCH_ATTRIB_CALL_ERROR
6029 "Failed to get switch configuration data. Return code = %d"\
Probable_Cause(s):<Bad Switch>\
Recommended_Action(s):\
<Replace switch>

$ SWITCH_NOT_ONLINE
6030 "The switch in not on an ONLINE mode, detected a mode of: %s"\
Probable_Cause(s):<Switch is not configured as online>\
<Bad Switch>\
Recommended_Action(s):\
<Configure the switch to ONLINE>\
<Replace switch>

$ FAILED_TO_CONNECT_LOGIN
6031 "Failed to connect to switch. Return code = %d"\
Probable_Cause(s):<Bad Password>\
Recommended_Action(s):\
<Check password>\
<Turn security off on switch>\
<if the problem persists, contact authorized Sun service provider>

$ PORT_ADMIN_OFFLINE
6032 "Detected that the port state is configured offline"\
Probable_Cause(s):<User configured this port to be offline>\
Recommended_Action(s):\
<Enable this port through the switch management tool.>\
<If the problem persists, contact authorized Sun service provider>


$ ONLINE_FAILED_START_RUNNING
6033 "Online loopback test failed to start. Return code = %d = Test in progress"\
Probable_Cause(s):<Test is already running>\
Recommended_Action(s):\
<Check for other tests running on switch>


$ DECODE_ERRORS
6034 "Detected Decode Errors during testing. Original count = %d, after testing = %d"\
Probable_Cause(s):<Bad SFP>\
<Bad Fiber Cable>\
<Bad Switch>\
Recommended_Action(s):\
<Replace SFP>\
<Replace Fiber Cable>\
<Replace Switch>



$ BAD_WARM_TEMP 
6035 "Detected a temperature problem with temperature sensor %d"\
Probable_Cause(s):<Poor air circulation>\
Recommended_Action(s):\
<Check air circulation>

$ BAD_OVER_TEMP 
6036 "Detected an overheating condition with temperature sensor %d"\
Probable_Cause(s):<Poor air circulation>\
Recommended_Action(s):\
<Check air circulation>



$ ONLINE_FAILED_START_RUNNING_BAD_FIRMWARE
6037 "Online loopback test failed to start. Return code = %d = Test in progress or firmware bug"\
Probable_Cause(s):<Test is already running>\
<This level of firmware - V1.5.0.7-0 - can report this error sometimes>\
Recommended_Action(s):\
<Check for other tests running on switch>\
<Check for a later version of switch firmware>

$ ONLINE_FAILED_START_ADMIN
6038 "Online loopback test failed to start due to admin login. Return code = %d on pattern 0x%x"\
Probable_Cause(s):<A user is already logged in as admin>\
Recommended_Action(s):\
<Check for a user being logged in as admin on the switch. Telnet into switch and type "show users">


