Important Update: Cohesity Products Knowledge Base Articles
All Cohesity Knowledge Base Articles are now managed via the Cohesity Support Portal: https://support.cohesity.com/s/searchunify. The Knowledge Base articles available here will not reflect the latest information or may no longer be accessible.
Troubleshooting hardware with Backup Exec for Windows Servers using the SCSI Trace Utility (tracer.exe).
Troubleshooting hardware with Backup Exec for Windows Servers using the SCSI Trace Utility (tracer.exe).
Solution
Backup Exec for Windows Servers comes with a SCSI Trace utility. This utility can be used to troubleshoot suspected tape hardware issues in the Backup Exec environment.
Tracer works by performing a low-level SCSI trace of the SCSI bus on a server and records the SCSI commands sent to and from all of the devices on the SCSI bus. The SCSI commands captured by tracer.exe are an industry standard for all SCSI devices. The information gathered by the SCSI trace utility can be used to narrow down the cause of a particular problem and determine whether or not there is a hardware fault.
Tracer logs SCSI commands sequentially. Each event is logged containing the SCSI Target, SCSI command type, and SCSI driver result.
The above command is an Inquiry command, which responded with a good SCSI status and a successful driver result.
Example of an unsuccessful SCSI command (Figure 3):
Figure 3:
The above command is a Test Unit Ready command, which is a SCSI command that queries the device to see if the device is ready for read and write operations. In this case, there is a SCSI reservation conflict preventing such an operation. The SCSI Status also indicates that there is an IO Device Error. The cause of this conflict would on the hardware level.
SCSI commands
This is list of the most common SCSI commands used by Backup Exec when communicating with tape drives and libraries (Figure 4:):
Figure 4:
| CDB | COMMAND | Description |
|---|---|---|
| 00h | TEST UNIT READY | Queries device to see if it is ready for data transfers. |
| 01h | REWIND | Rewinds the medium. |
| 03h | REQUEST SENSE | Requests that the device transfer sense data to the host. |
| 05h | READ BLOCK LIMITS | Reports the maximum block length limit. |
| 07h | INITIALIZE ELEMENT STATUS | Forces an inventory operation. |
| 08h | READ | Reads the medium. |
| 0Ah | WRITE | Writes to the medium. |
| 0Ch | ROTATE MAILSLOT COMMAND | Opens or closes the mailslot. |
| 10h | WRITE FILEMARKS | Writes filesmarks, such as end of data, onto medium. |
| 11h | SPACE | Provides a variety of positioning functions. |
| 12h | INQUIRY | Returns basic device information and inquiry data. |
| 15h | MODE SELECT(6) | Sets device parameters in a mode page. |
| 16h | RESERVE UNIT | Reserves the unit. |
| 17h | RELEASE UNIT | Releases the unit. |
| 19h | ERASE | Erases the medium. |
| 1Ah | MODE SENSE(6) | Returns current device parameters from mode pages. |
| 1Bh | LOAD UNLOAD | Tells the target to load or unload the media in the tape cartridge. |
| 1Eh | PREVENT ALLOW MEDIUM REMOVAL | Enables or disables the unloading of the tape cartridge. |
| 2Bh | LOCATE (Seek to a position) | Uses the identifier from a READ POSITION to position back to this same logical position. |
| 34h | READ POSITION | Read a position identifier, or SCSI Logical Block Address. |
| 3Bh | WRITE BUFFER | Diagnostic function for testing the device data buffer, DMA engine, SCSI bus interface hardware, and SCSI bus integrity. |
| 3Ch | READ BUFFER | Diagnostic function for testing the device data buffer, DMA engine, SCSI bus interface hardware, and SCSI bus integrity. |
| 4Ch | LOG SELECT | Allows the host to manage statistical information maintained by the device about its own hardware or the installed media. |
| 4Dh | LOG SENSE | Allows the initiator to modify and initialize parameters within the logs supported by the device. |
| 55h | MODE SELECT(10) | Sets device parameters in a mode page. |
| 5Ah | MODE SENSE(10) | Returns current device parameters from mode pages. |
| A5h | MOVE MEDIUM | Used to move cartridges from the tape drive to the library. |
| A6h | EXCHANGE MEDIUM | Used to move cartridges from the tape drive to the library. |
| B8h | READ ELEMENT STATUS | Returns the status tables of its elements to the initiator. |
Errors and Check Conditions
Check conditions are errors that occur when a SCSI command completes successfully, but returns an error. Detailed information regarding the error is contained within the response from the SCSI within a field known as the Sense Data. These events are marked as a 'C #####' under the 'Check' column in tracer.
Error responses occur when SCSI commands do not complete their intended operation due to an error. Like Check Conditions, these errors normally contain additional sense key data that contains information regarding the condition that caused the failure. These errors are marked as an 'E' under the 'Check' column in tracer.
The following is an example of an expected check condition (Figure 5):
Figure 5:
The driver result from the above SCSI command was STATUS_IO_DEVICE_ERROR. The Additional Sense Code ( ASC) indicates that the drive is not ready due the condition MEDIUM_NOT_PRESENT, which means there is not a tape in the drive. While this is considered a SCSI 'error,' it does not constitute any fault with the hardware.
The following is an example of a check condition that occurred due to faulty hardware (Figure 6):
Figure 6:
The following is an example of a SCSI command that resulted in an error (Figure 7):
Figure 7:
Filtering Tracer Events
Tracer can be filtered to show you only events from a certain device, a certain command, or commands that resulted in a check condition. To enable filters, go to Tools > Filters (Figure 8):
Figure 8:
For Example, to view all errors and check conditions, select the box 'Command resulted in check condition.' Furthermore, if you have multiple devices connected to your server, you can filter just the device you are troubleshooting by selecting 'Event is from one of these targets.'