Changing the virtual SCSI queue depth

Increasing the virtual Small Computer Serial Interface (SCSI) queue depth might provide performance improvements for some virtual configurations. Understand the factors that are involved in determining a change to the virtual SCSI queue depth value.

The virtual SCSI queue depth value determines how many requests the disk head driver queues to the virtual SCSI client driver at any one time. For AIX® client logical partitions, you can change this value from the default value of 3 to a value in the range 1 - 256 by using the chdev command. For Linux® client logical partitions, you can change this value from the default value of 16 to a value in the range 1 - 256 by using the echo command. For IBM® i client logical partitions, the queue depth value is 32 and cannot be changed.

Increasing this value might improve the throughput of the disk in specific configurations. However, several factors must be considered. These factors include the value of the queue-depth attribute for all of the physical storage devices on the Virtual I/O Server being used as a virtual target device by the disk instance on the client logical partition, and the maximum transfer size for the virtual SCSI client adapter instance that is the parent device for the disk instance.

For AIX and Linux client logical partitions, the maximum transfer size for virtual SCSI client adapters is set by the Virtual I/O Server, which determines the value based on the resources available on the server and the maximum transfer size set for the physical storage devices on that server. Other factors include the queue depth and maximum transfer size of other devices that are involved in mirrored-volume-group or Multipath I/O (MPIO) configurations. Increasing the queue depth for some devices might reduce the resources available for other devices on that same shared adapter and decrease the throughput for those devices. For IBM i client logical partitions, the queue depth value is 32 and cannot be changed.

To change the queue depth for an AIX client logical partition, on the client logical partition, use the chdev command with the queue_depth=value attribute as in the following example:
chdev -l hdiskN -a "queue_depth=value"
hdiskN represents the name of a physical volume and value is the value that you assign in the range 1 - 256.
To change the queue depth for a Linux client logical partition on the client logical partition, use the echo command as in the following example:
echo 16 > /sys/devices/vio/30000003/host0/target0:0:1/0:0:1:0/queue_depth
By default, the value of the queue_depth attribute for a disk on the Linux operating system is 16.
To view the current setting for the queue_depth value, from the client logical partition issue the following command:
lsattr -El hdiskN