chicks-net / megamap

MegaRAID® Linux drive map
GNU General Public License v2.0
33 stars 16 forks source link

Feature suggestion: add support for mpt(x)sas via sas(x)ircu utilities #2

Open edrozenberg opened 9 years ago

edrozenberg commented 9 years ago

Hello,

The megacli utility doesn't support controllers using mpt(x)sas (SAS2008, SAS2308, SAS3008, etc). Instead, these controllers are supported by the LSI sas(x)ircu utilities (sas2ircu, sas3ircu). Perhaps megamap could make use of these ircu utilities to support more LSI adapters.

The ircu utils can blink drives and do a few other things.

http://www.lsi.com/downloads/Public/Host%20Bus%20Adapters/Host%20Bus%20Adapters%20Common%20Files/SAS_SATA_6G_P20/SAS2IRCU_P20.zip

https://www.lsi.com/downloads/Public/Host%20Bus%20Adapters/Host%20Bus%20Adapters%20Common%20Files/SAS_SATA_6G_P12/SAS2IRCU_User_Guide.pdf

http://www.lsi.com/downloads/Public/Host%20Bus%20Adapters/Host%20Bus%20Adapters%20Common%20Files/SAS_SATA_12G_P7/SAS3IRCU_P7.zip

https://www.lsi.com/downloads/Public/Host%20Bus%20Adapters/SAS3IRCU_UG.pdf

chicks-net commented 9 years ago

That's a good idea Ed. I'm happy to look into it more.

Before I go buy one of these cards would you mind providing the output of the right sas utility and ls -l /dev/disk/by-id?

Do you know of an easy way programmatically to detect which is installed? Do they use different kernel modules or would lspci output do it?

edrozenberg commented 9 years ago

Hello Christopher,

Please don't buy new hardware on my account or send me your Paypal and I'll contribute :)

Commands output (formatting for LIST is a bit different for sas2ircu vs sas3ircu):

sas2ircu list - https://gist.github.com/edrozenberg/7e45c70da682e01c13a9#file-sas2ircu-list sas2ircu 0 display - https://gist.github.com/edrozenberg/62322e0e98f2db83490b#file-sas2ircu-0-display

sas3ircu list - https://gist.github.com/edrozenberg/d9526426c7cca86326fe#file-sas3ircu-0-display sas3ircu 0 display - https://gist.github.com/edrozenberg/f5742f96bd0411ad298d#file-sas3ircu-list

ls -al /dev/disk/by-id - https://gist.github.com/edrozenberg/e5df3e585873105c13b1#file-ls-al-dev_disk_by-id

lspci|grep -i mpt
03:00.0 Serial Attached SCSI controller: LSI Logic / Symbios Logic SAS3008 PCI-Express Fusion-MPT SAS-3 (rev 02)
81:00.0 Serial Attached SCSI controller: LSI Logic / Symbios Logic SAS2308 PCI-Express Fusion-MPT SAS-2 (rev 05)

Compared to the generic kernel, I enable these when building in support for mpt sas. Maybe they're not all required:

CONFIG_MEGARAID_SAS=y
CONFIG_SCSI_MPT2SAS=y
CONFIG_SCSI_MPT3SAS=y
CONFIG_FUSION_SAS=y