@blondie63 You'll need to do some experimenting.
These are the commands that I think will be useful for you:
lspci
- this displays a list of PCI/PCIe devices attached to the computer. It has a number of options (check the man page), but you'll probably want to use lspci -s
, and lspci -s -v
grep
- this filters the output from a previous command, so just the lines with a desired text fragment are shown. grep -i
does case insensitive matching
lsmod
- this lists the kernel modules (ie drivers) currently loaded in your system
rmmod
- this unloads a kernel driver
modprobe
- this loads a kernel driver
So, I'd probably start with trying to confirm the driver being used for your LSI card.
Here's an example of using lspci to check the driver being used, but for a (different) card on my system. The principle should be the same for yours:
Bash:
# lspci
00:00.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Starship/Matisse Root Complex
00:00.2 IOMMU: Advanced Micro Devices, Inc. [AMD] Starship/Matisse IOMMU
00:01.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Starship/Matisse PCIe Dummy Host Bridge
00:01.1 PCI bridge: Advanced Micro Devices, Inc. [AMD] Starship/Matisse GPP Bridge
00:01.2 PCI bridge: Advanced Micro Devices, Inc. [AMD] Starship/Matisse GPP Bridge
(and a whole bunch more)
The list generated by lspci is often WAAAY too long, so use the
grep
command to filter out anything not containing the term you want (for example) "LSI":
Bash:
# lspci | grep -i LSI
02:00.0 Serial Attached SCSI controller: Broadcom / LSI SAS2308 PCI-Express Fusion-MPT SAS-2 (rev 05)
You're only really after the first part of the line, the
02:00.0
bit. That's the (PCIe) address of the LSI controller attached to my system.
You use that address with the
lspci -s
option, then add
-v
(aka "verbose info") which tells lspci to give more details.
Like this:
Bash:
# lspci -s 02:00.0 -v
02:00.0 Serial Attached SCSI controller: Broadcom / LSI SAS2308 PCI-Express Fusion-MPT SAS-2 (rev 05)
DeviceName: Integrated RAID
Subsystem: Dell SAS2308 PCI-Express Fusion-MPT SAS-2
Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx+
(...)
Capabilities: [190 v1] Dynamic Power Allocation <?>
Capabilities: [148 v1] Alternative Routing-ID Interpretation (ARI)
ARICap: MFVC- ACS-, Next Function: 0
ARICtl: MFVC- ACS-, Function Group: 0
Kernel driver in use: mpt3sas
Kernel modules: mpt3sas
The last two lines of the output show the kernel module/driver loaded for that device. So, in my case the
mpt3sas
driver is in use. Yours sounds like it'll be
megaraid
instead.
Next, I'd run the
lsmod
command to get the list of loaded kernel modules (and pipe that through
sort
for easier reading). It'll be a long list, so you'd probably want to use the
grep
thing again to filter out anything not containing (for example) "mpt".
Bash:
# lsmod | sort | grep -i mpt
mpt3sas 364544 8
raid_class 12288 1 mpt3sas
scsi_transport_sas 53248 1 mpt3sas
So we can see the
mpt3sas
kernel module is loaded on my system and it's used by the
raid_class
and
scsi_transport_sas
kernel modules.
I'd unload it by running this:
I'm not actually going to run it on my system though, as it would screw up my system. It actually uses those disks.
In your case, it'll probably be this instead:
Anyway, with that module unloaded if you run the lspci command again to show your device info, it should display a blank entry for the "Kernel modules" line.
You can then manually run the
modprobe
command to try loading the driver you want. In your case it'll probably be this:
If no errors are returned, then use the lspci command again to see if your card is using the new driver. And maybe the lsmod command again as well, just to see what mpt related modules are loaded (like I did above).
Oh, the scsi kernel modules/drivers that are available to load are in the
/usr/lib/modules/KERNEL_VERSION/kernel/drivers/scsi/
directory on your system. You should be able to get that list by running this:
# ls -la /usr/lib/modules/`uname -r`/kernel/drivers/scsi/
Hopefully that helps.