NCQ sata_max_queue_depth tunable

Previously, i did some analysis on NCQ in OpenSolaris. It turned out that to get good multi-stream sequential read performance, you had to disable NCQ via the tunable 'sata_func_enable'. Disabling NCQ actually does two things: 1) sets the number of concurrent I/Os to 1 and 2) changes what you send down protocol wise.

Turns out, the first is all we really need to get good performance for the multi-stream sequential read case, and doing the second actually exposes a bug on certain firmware of certain disks. So i highly recommend the newly added 'sata_max_queue_depth' tunable instead of 'sata_func_enable'. As a reminder, put the following in /etc/system and reboot:

set sata:sata_max_queue_depth = 0x1

An admin command to allow you to do this on the fly without rebooting would be another step forward, but no official plans on that just yet.

Thanks Pawel!

Comments:

What is the difference between NCQ and Command Tag Queueing?

For example, the very first thing we did in `fx` on sgi IRIX was to turn CTQ ON, as recommended by sgi engineers.

Posted by UX-admin on September 11, 2007 at 06:47 PM PDT #

Eric, could you confirm if the driver for the sata chipset need to support NCQ in some way?
I think your tests last time were just with the marvell88sx driver, but do you think you would see the same results with the ahci driver?
This bug:
http://bugs.opensolaris.org/view_bug.do?bug_id=6511021
...seems to imply that NCQ is not working with the ahci driver.

Posted by Nigel Smith on September 11, 2007 at 11:55 PM PDT #

hey UX-admin,

Perhaps they meant TCQ instead of CTQ? The wikipedia entry on NCQ has a nice description between NCQ (SATA), TCQ (PATA), and TCQ (SCSI):
http://en.wikipedia.org/wiki/Native_Command_Queuing

Posted by eric kustarz on September 12, 2007 at 01:33 AM PDT #

Nigel,

As far as i know, the marvell driver is the only SATA driver with NCQ support. Feel free to query on the storage discuss alias though. Lida should be able to clarify.

Posted by eric kustarz on September 12, 2007 at 01:36 AM PDT #

Post a Comment:
Comments are closed for this entry.
About

erickustarz

Search

Categories
Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today