In SCSI computer storage, computers and storage devices use a client-server model of communication. The computer is a client which requests the storage device to perform a service, e.g., to read or write data. The SCSI command architecture was originally defined for parallel SCSI buses but has been carried forward with minimal change for use with Fibre Channel, iSCSI, Serial Attached SCSI, and other transport layers.
In the SCSI protocol, the initiator sends a SCSI command information unit to the target device. Data information units may then be transferred between the computer and device. Finally, the device sends a response information unit to the computer.
SCSI commands are sent in a command descriptor block (CDB), which consists of a one byte operation code (opcode) followed by five or more bytes containing command-specific parameters. Upon receiving and processing the CDB the device will return a status code byte and other information.
The rest of this article contains a list of SCSI commands, sortable in opcode or description alphabetical order. In the published SCSI standards, commands are designated as "mandatory," "optional" or "vendor-unique." Only the mandatory commands are required of all devices. There are links to detailed descriptions for the more common SCSI commands. Some opcodes produce different, though usually comparable, effects in different device types; for example, opcode 0x01 recalibrates a disk drive by seeking back to physical sector zero, but rewinds the medium in a tape drive.
Originally the most significant 3 bits of a SCSI opcode specified the length of the CDB. However, when variable-length CDBs were created this correspondence was changed, and the entire opcode must be examined to determine the CDB length. The lengths are as follows:
Opcode (hex ) | Length |
---|---|
00h to 1Fh | 6 |
20h to 5Fh | 10 |
60h to 7Dh | reserved |
7Eh | variable (more than 16 bytes) |
7Fh | extended (variable length; may contain one or more CDBs) |
80h to 9Fh | 16 |
A0h to BFh | 12 |
C0h to FFh | vendor specific |
When a command is defined in multiple CDB sizes, the length of the CDB is given in parentheses after the command name, e.g., READ(6) and READ(10).
Code | Command |
---|---|
00 | TEST UNIT READY |
01 | REWIND |
03 | REQUEST SENSE |
04 | FORMAT |
05 | READ BLOCK LIMITS |
07 | REASSIGN BLOCKS |
07 | INITIALIZE ELEMENT STATUS |
08 | READ(6) |
0A | WRITE(6) |
0B | SEEK(6) |
0F | READ REVERSE(6) |
10 | WRITE FILEMARKS(6) |
11 | SPACE(6) |
12 | INQUIRY |
13 | VERIFY(6) |
14 | RECOVER BUFFERED DATA |
15 | MODE SELECT(6) |
16 | RESERVE(6) |
17 | RELEASE(6) |
18 | COPY |
19 | ERASE (6) |
1A | MODE SENSE (6) |
1B | START STOP UNIT |
1B | LOAD UNLOAD |
1C | RECEIVE DIAGNOSTIC RESULTS |
1D | SEND DIAGNOSTIC |
1E | PREVENT ALLOW MEDIUM REMOVAL |
23 | READ FORMAT CAPACITIES |
25 | READ CAPACITY(10) |
28 | READ(10) |
29 | READ GENERATION |
2A | WRITE(10) |
2B | SEEK(10) |
2B | LOCATE(10) |
2C | ERASE(10) |
2D | READ UPDATED BLOCK |
2E | WRITE AND VERIFY(10) |
2F | VERIFY(10) |
33 | SET LIMITS(10) |
34 | PRE-FETCH(10) |
34 | READ POSITION |
35 | SYNCHRONIZE CACHE(10) |
36 | LOCK UNLOCK CACHE(10) |
37 | READ DEFECT DATA(10) |
37 | INITIALIZE ELEMENT STATUS WITH RANGE |
38 | MEDIUM SCAN |
39 | COMPARE |
3A | COPY AND VERIFY |
3B | WRITE BUFFER |
3C | READ BUFFER |
3D | UPDATE BLOCK |
3E | READ LONG(10) |
3F | WRITE LONG(10) |
40 | CHANGE DEFINITION |
41 | WRITE SAME(10) |
42 | UNMAP |
43 | READ TOC/PMA/ATIP |
44 | REPORT DENSITY SUPPORT |
45 | PLAY AUDIO(10) |
46 | GET CONFIGURATION |
47 | PLAY AUDIO MSF |
48 | SANITIZE |
4A | GET EVENT STATUS NOTIFICATION |
4B | PAUSE/RESUME |
4C | LOG SELECT |
4D | LOG SENSE |
50 | XDWRITE(10) |
51 | XPWRITE(10) |
51 | READ DISC INFORMATION |
52 | XDREAD(10) |
53 | XDWRITEREAD(10) |
54 | SEND OPC INFORMATION |
55 | MODE SELECT(10) |
56 | RESERVE(10) |
57 | RELEASE(10) |
58 | REPAIR TRACK |
5A | MODE SENSE(10) |
5B | CLOSE TRACK/SESSION |
5C | READ BUFFER CAPACITY |
5D | SEND CUE SHEET |
5E | PERSISTENT RESERVE IN |
5F | PERSISTENT RESERVE OUT |
7E | extended CDB |
7F | variable length CDB |
80 | XDWRITE EXTENDED(16) |
80 | WRITE FILEMARKS(16) |
81 | READ REVERSE(16) |
83 | Third-party Copy OUT commands |
84 | Third-party Copy IN commands |
85 | ATA PASS-THROUGH(16) |
86 | ACCESS CONTROL IN |
87 | ACCESS CONTROL OUT |
88 | READ(16) |
89 | COMPARE AND WRITE |
8A | WRITE(16) |
8B | ORWRITE |
8C | READ ATTRIBUTE |
8D | WRITE ATTRIBUTE |
8E | WRITE AND VERIFY(16) |
8F | VERIFY(16) |
90 | PRE-FETCH(16) |
91 | SYNCHRONIZE CACHE(16) |
91 | SPACE(16) |
92 | LOCK UNLOCK CACHE(16) |
92 | LOCATE(16) |
93 | WRITE SAME(16) |
93 | ERASE(16) |
9D | SERVICE ACTION BIDIRECTIONAL |
9E | SERVICE ACTION IN(16) |
9F | SERVICE ACTION OUT(16) |
A0 | REPORT LUNS |
A1 | ATA PASS-THROUGH(12) |
A2 | SECURITY PROTOCOL IN |
A3 | MAINTENANCE IN |
A4 | MAINTENANCE OUT |
A4 | REPORT KEY |
A5 | MOVE MEDIUM |
A5 | PLAY AUDIO 12 |
A6 | EXCHANGE MEDIUM |
A7 | MOVE MEDIUM ATTACHED |
A8 | READ(12) |
A9 | SERVICE ACTION OUT(12) |
AA | WRITE(12) |
AB | SERVICE ACTION IN(12) |
AC | ERASE(12) |
AD | READ DVD STRUCTURE |
AE | WRITE AND VERIFY(12) |
AF | VERIFY(12) |
B0 | SEARCH DATA HIGH(12) |
B1 | SEARCH DATA EQUAL(12) |
B2 | SEARCH DATA LOW(12) |
B3 | SET LIMITS(12) |
B4 | READ ELEMENT STATUS ATTACHED |
B5 | SECURITY PROTOCOL OUT |
B6 | SEND VOLUME TAG |
B7 | READ DEFECT DATA(12) |
B8 | READ ELEMENT STATUS |
B9 | READ CD MSF |
BA | REDUNDANCY GROUP (IN) |
BB | REDUNDANCY GROUP (OUT) |
BC | SPARE (IN) |
BD | SPARE (OUT) |
BE | VOLUME SET (IN) |
BF | VOLUME SET (OUT) |
Parallel ATA (PATA), originally AT Attachment, also known as ATA or IDE is a standard interface designed for IBM PC-compatible computers. It was first developed by Western Digital and Compaq in 1986 for compatible hard drives and CD or DVD drives. The connection is used for storage devices such as hard disk drives, floppy disk drives, and optical disc drives in computers.
Disk storage is a general category of storage mechanisms where data is recorded by various electronic, magnetic, optical, or mechanical changes to a surface layer of one or more rotating disks. A disk drive is a device implementing such a storage mechanism. Notable types are the hard disk drive (HDD) containing a non-removable disk, the floppy disk drive (FDD) and its removable floppy disk, and various optical disc drives (ODD) and associated optical disc media.
Small Computer System Interface is a set of standards for physically connecting and transferring data between computers and peripheral devices. The SCSI standards define commands, protocols, electrical, optical and logical interfaces. The SCSI standard defines command sets for specific peripheral device types; the presence of "unknown" as one of these types means that in theory it can be used as an interface to almost any device, but the standard is highly pragmatic and addressed toward commercial requirements. The initial Parallel SCSI was most commonly used for hard disk drives and tape drives, but it can connect a wide range of other devices, including scanners and CD drives, although not all controllers can handle all devices.
In computing, booting is the process of starting a computer as initiated via hardware such as a button or by a software command. After it is switched on, a computer's central processing unit (CPU) has no software in its main memory, so some process must load software into memory before it can be executed. This may be done by hardware or firmware in the CPU, or by a separate processor in the computer system.
Internet Small Computer Systems Interface or iSCSI is an Internet Protocol-based storage networking standard for linking data storage facilities. iSCSI provides block-level access to storage devices by carrying SCSI commands over a TCP/IP network. iSCSI facilitates data transfers over intranets and to manage storage over long distances. It can be used to transmit data over local area networks (LANs), wide area networks (WANs), or the Internet and can enable location-independent data storage and retrieval.
In computing, a block, sometimes called a physical record, is a sequence of bytes or bits, usually containing some whole number of records, having a maximum length; a block size. Data thus structured are said to be blocked. The process of putting data into blocks is called blocking, while deblocking is the process of extracting data from blocks. Blocked data is normally stored in a data buffer, and read or written a whole block at a time. Blocking reduces the overhead and speeds up the handling of the data stream. For some devices, such as magnetic tape and CKD disk devices, blocking reduces the amount of external storage required for the data. Blocking is almost universally employed when storing data to 9-track magnetic tape, NAND flash memory, and rotating media such as floppy disks, hard disks, and optical discs.
Modbus is a data communications protocol originally published by Modicon in 1979 for use with its programmable logic controllers (PLCs). Modbus has become a de facto standard communication protocol and is now a commonly available means of connecting industrial electronic devices.
In computer storage, a logical unit number, or LUN, is a number used to identify a logical unit, which is a device addressed by the SCSI protocol or by Storage Area Network protocols that encapsulate SCSI, such as Fibre Channel or iSCSI.
In computer data storage, a SCSI initiator is the endpoint that initiates a SCSI session, that is, sends a SCSI command. The initiator usually does not provide any Logical Unit Numbers (LUNs).
The USB mass storage device class is a set of computing communications protocols, specifically a USB Device Class, defined by the USB Implementers Forum that makes a USB device accessible to a host computing device and enables file transfers between the host and the USB device. To a host, the USB device acts as an external hard drive; the protocol set interfaces with a number of storage devices.
In computing, channel I/O is a high-performance input/output (I/O) architecture that is implemented in various forms on a number of computer architectures, especially on mainframe computers. In the past, channels were generally implemented with custom devices, variously named channel, I/O processor, I/O controller, I/O synchronizer, or DMA controller.
In SCSI standards for transferring data between computers and peripheral devices, often computer storage, commands are sent in a Command Descriptor Block (CDB).
Most recent SCSI enclosure products support a protocol called SCSI Enclosure Services (SES). The initiator can communicate with the enclosure using a specialized set of SCSI commands to access power, cooling, and other non-data characteristics.
Parallel SCSI is the earliest of the interface implementations in the SCSI family. SPI is a parallel bus; there is one set of electrical connections stretching from one end of the SCSI bus to the other. A SCSI device attaches to the bus but does not interrupt it. Both ends of the bus must be terminated.
In computer storage, disk buffer is the embedded memory in a hard disk drive (HDD) or solid state drive (SSD) acting as a buffer between the rest of the computer and the physical hard disk platter or flash memory that is used for storage. Modern hard disk drives come with 8 to 256 MiB of such memory, and solid-state drives come with up to 4 GB of cache memory.
Count key data (CKD) is a direct-access storage device (DASD) data recording format introduced in 1964, by IBM with its IBM System/360 and still being emulated on IBM mainframes. It is a self-defining format with each data record represented by a Count Area that identifies the record and provides the number of bytes in an optional Key Area and an optional Data Area. This is in contrast to devices using fixed sector size or a separate format track.
SCSI / ATA Translation (SAT) is a set of standards developed by the T10 subcommittee, defining how to communicate with ATA devices through a SCSI application layer. The standard attempts to be consistent with the SCSI architectural model, the SCSI Primary Commands, and the SCSI Block Commands standards.
iSCSI conformance testing is testing to determine whether an iSCSI Initiator/Target meets the iSCSI standard.
The IBM System/360 architecture is the model independent architecture for the entire S/360 line of mainframe computers, including but not limited to the instruction set architecture. The elements of the architecture are documented in the IBM System/360 Principles of Operation and the IBM System/360 I/O Interface Channel to Control Unit Original Equipment Manufacturers' Information manuals.
Object storage is a computer data storage that manages data as objects, as opposed to other storage architectures like file systems which manages data as a file hierarchy, and block storage which manages data as blocks within sectors and tracks. Each object typically includes the data itself, a variable amount of metadata, and a globally unique identifier. Object storage can be implemented at multiple levels, including the device level, the system level, and the interface level. In each case, object storage seeks to enable capabilities not addressed by other storage architectures, like interfaces that are directly programmable by the application, a namespace that can span multiple instances of physical hardware, and data-management functions like data replication and data distribution at object-level granularity.