Copyright (c) 2009 Sun Microsystems, Inc. All Rights Reserved.
The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License. You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing.
See the License for the specific language governing permissions and limitations under the License. When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER,
with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
sd@target,lun:partition
To determine the disk drive type, use the SCSI/ATAPI inquiry command and read the volume label stored on block 0 of the drive. (The volume label describes the disk geometry and partitioning and must be present for the disk to be mounted by the system.) A volume label is not required for removable, re-writable or read-only media.
The x86 BIOS legacy requires a master boot record (MBR) and fdisk table in the first physical sector of the bootable media. If the x86 hard disk contains a Solaris disk label, it is located in the second 512-byte sector of the FDISK partition.
I/O requests to the raw device must be aligned on a 512-byte (DEV_BSIZE) boundary and all I/O request lengths must be in multiples of 512 bytes. Requests that do not meet these requirements will trigger an EINVAL error. There are no alignment or length restrictions on I/O requests to the block device.
When the DVD-ROM is opened, the eject button is disabled to prevent the manual removal of a disk until the last close() is called. No volume label is required for a DVD-ROM. If the DVD-ROM contains data recorded in a Solaris-aware file system format, it can be mounted using the appropriate Solaris file system support.
ZIP/JAZ media provide varied data capacity points; a single JAZ drive can store up to 2 GBytes of data, while a ZIP-250 can store up to 250MBytes of data. ZIP/JAZ drives can be read-from or written-to using the appropriate drive.When a ZIP/JAZ drive is opened, the eject button is disabled to prevent the manual removal of a disk until the last close() is called. No volume label is required for a ZIP/JAZ drive. If the ZIP/JAZ drive contains data recorded in a Solaris-aware file system format, it can be mounted using the appropriate Solaris file system support.
Not all device drivers make per-partition IO statistics available for reporting. sd and ssd(4D) per-partition statistics are enabled by default but may be disabled in their configuration files.
Permission denied
The partition was opened exclusively by another thread
The argument features a bad address
Invalid argument
The device does not support the requested ioctl function
During opening, the device did not exist. During close, the drive unlock failed
The device is read-only
Resource temporarily unavailable
A signal was caught during the execution of the ioctl() function
Insufficient memory
Insufficient access permission
An I/O error occurred. Refer to notes for details on copy-protected DVD-ROM media.
The default value is 1, which causes partition IO statistics to be maintained. Set this value to zero to prevent the driver from recording partition statistics. This slightly reduces the CPU overhead for IO, minimizes the amount of sar(1) data collected and makes these statistics unavailable for reporting by iostat(8) even though the -p/-P option is specified. Regardless of this setting, disk IO statistics are always maintained.
The supplied value is passed as the qfull-retries capability value of the HBA driver. See scsi_ifsetcap(9F) for details.
The supplied value is passed as the qfull-retry interval capability value of the HBA driver. See scsi_ifsetcap(9F) for details.
The default value is 1, which allows resetting to occur. Set this value to 0 (zero) to prevent the sd driver from calling scsi_reset(9F) with a second argument of RESET_TARGET when in error-recovery mode. This scsi_reset(9F) call may prompt the HBA driver to send a SCSI Bus Device Reset message. The scsi_reset(9F) call with a second argument of RESET_TARGET may result from an explicit request via the USCSICMD ioctl. Some high-availability multi-initiator systems may wish to prohibit the Bus Device Reset message; to do this, set the allow-bus-device-reset property to 0.
Controls the binding of the driver to non self-identifying SCSI target optical devices. (See scsi(5)). The default value is 1, which causes sd to bind to DTYPE_OPTICAL devices (as noted in scsi(5)). Setting this value to 0 prevents automatic binding. The default behavior for the SPARC-based sd driver prior to Solaris 9 was not to bind to optical devices.
Boolean type, when set to False, it indicates that the disk does not support power condition field in the START STOP UNIT command.
In addition to the above properties, some device-specific tunables can be configured in sd.conf using the sd-config-list global property. The value of this property is a list of duplets. The formal syntax is:
sd-config-list = <duplet> [, <duplet> ]* ; where <duplet>:= "<vid+pid>" , "<tunable-list>" and <tunable-list>:= <tunable> [, <tunable> ]*; <tunable> = <name> : <value> The <vid+pid> is the string that is returned by the target device on a SCSI inquiry command. The <tunable-list> contains one or more tunables to apply to all target devices with the specified <vid+pid>. Each <tunable> is a <name> : <value> pair. Supported tunable names are: delay-busy: when busy, nsecs of delay before retry. retries-timeout: retries to perform on an IO timeout.mmc-gesn-polling
For optical drives compliant with MMC-3 and supporting the GET EVENT STATUS NOTIFICATION command, this command is used for periodic media state polling, usually initiated by the DKIOCSTATE dkio(4I) ioctl. To disable the use of this command, set this boolean property to false. In that case, either the TEST UNIT READY or zero-length WRITE(10) command is used instead.
The following is an example of a global sd-config-list property: sd-config-list = "SUN T4", "delay-busy:600, retries-timeout:6", "SUN StorEdge_3510", "retries-timeout:3";
Driver configuration file
Block files
Raw files
Where: cn
controller n
SCSI target id n (0-6)
SCSI LUN n (0-7 normally; some HBAs support LUNs to 15 or 32. See the specific manpage for details)
partition n (0-7)
raw files
Where: pn
Where n=0 the node corresponds to the entire disk.
ANSI Small Computer System Interface-2 (SCSI-2)
ATA Packet Interface for CD-ROMs, SFF-8020i
Mt.Fuji Commands for CD and DVD, SFF8090v3
Error for Command:<command name> Error Level: Fatal Requested Block: <n> Error Block: <m> Vendor:'<vendorname>' Serial Number:'<serial number>' Sense Key:<sense key name>ASC: 0x<a> (<ASC name>), ASCQ: 0x<b>, FRU: 0x<c>
The command indicated by <command name> failed. The Requested Block is the block where the transfer started and the Error Block is the block that caused the error. Sense Key, ASC, and ASCQ information is returned by the target in response to a request sense command.
The drive is not ready because no caddy has been inserted.
A REQUEST SENSE command completed with a check condition. The original command will be retried a number of times.
There is a discrepancy between the label and what the drive returned on the READ CAPACITY command.
The request sense data was less than expected.
The REQUEST SENSE command did not transfer any data.
The drive was reserved by another initiator.
The host adapter has failed to transport a command to the target for the reason stated. The driver will either retry the command or, ultimately, give up.
The REQUEST SENSE data included an invalid sense.
<n> The drive is not ready.
A failure to switch back to read mode 1.
The disk label is corrupted.
The disk label is corrupted.
The disk label is corrupted.
The drive returned busy during a number of retries.
The drive is powered down or died
A retry on a Unit Attention condition failed.
The geometry of the drive could not be established.
There was a residue after the command completed normally.
A bp with consistent memory could not be allocated.
A bp with consistent memory could not be allocated.
A bp with consistent memory could not be allocated.
A bp with consistent memory could not be allocated.
Free memory pool exhausted.
Free memory pool exhausted.
Free memory pool exhausted.
The disk label is corrupted.
A packet could not be allocated during dumping.
Drive went offline; probably powered down.
Driver attempted to retry a command and experienced a transport error.
Driver attempted to retry a command and experienced a transport error.
Illegal request size.
Driver attempted to submit a request sense command and failed.
Host adapter driver was unable to accept a command.
Failure to read disk label.
Drive went offline; probably powered down.