Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I have a SCSI controller (HP Smart Array 642), using cciss driver on Linux, which is connected to several SCSI disks. I am trying to optimize the communication between these devices and came to the place, that I should check how full is the cache of each disk.

Is it possible to get this value from the disk? Or maybe it is possible to get this value from the controller?

p.s. Want to notice that because the disks are behind the controller I can't use hdparm, for example.

share|improve this question

migrated from stackoverflow.com Apr 21 '13 at 5:50

This question came from our site for professional and enthusiast programmers.

2  
linux can't and shouldn't care what the specs of the disks behind the array are. it's up to the array controller to optimize things. you shouldn't be tryign to mess around with the disks directly, because that'd mean bypassing the controller and potentially destroying the array. –  Marc B Apr 20 '13 at 15:17
1  
This is what I am doing: I communicate with the disks by SCSI pass through commands and I don't care about the array. –  Vladimir Tikhomirov Apr 20 '13 at 15:36

2 Answers 2

You could frig with the firmware on the drives directly. scsirastools will let you issue mode page commands to the drives to modify their configuration. If you want to experiment with the drives take a look at the cache segmentation parameters and pre-fetch policies on Mode page 8 as a place to start.

I don't know if scsirastools will support pass through on your RAID controller. If it doesn't you might have to get an old adaptec 39320 or similar controller off Ebay and use that to fiddle with the mode pages. YMMV.

share|improve this answer
    
But if we are talking about pass through commands, for another RAID controller it will be completely different. –  Vladimir Tikhomirov Apr 23 '13 at 8:36

During research the buffer limitation for this controller was found in the Linux driver (cciss):

MAX_KMALLOC_SIZE(4096∗512)

That means that to get the fastest speed we need to fit the sending information in this 2MB buffer all the time. So, it seems that it is not a cache of the controller, but some important value, which influence on the speed of the sending process.

If we are talking about Data-Out commands, where we need to include buffer all the time, it is a nice idea to check the transfer length parameter, which influences on the buffer size. Of course, don't forget about the amount of disks, because this allocation memory relates to the controller.

Otherwise, the limitation in this situation is speed of the disk, but of course it depends on the controller, disks, buses and a lot of other parameters.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.