in case somebody gets stuck as i was - here are detailed instruction and the CORRECT ORDER in which the needed kernel modules HAVE to be loaded in order for the megacli to work properly...

big thanks to Christoph Schug....

Christoph Schug wrote:
On Mon, Jun 02, 2008, kalin m wrote:

thanks Vince... i didnt wanted to install the linux base because a lot of kids will be running some 'cool' boards or blogs that probably have cool linux holes too. but just for the hell of it and for he purpose to get to the controller i did. it took a while to find the it's not on the freebsd site and not on the LSI site (anymore) either.. anyway after a lot of rpm downloads and patching and variable changing and fs mountings i get this:

# /usr/local/sbin/megacli -adpCount
                                   ERROR:Could not detect controller.

Controller Count: 0.

From my experience there are some pitfalls when using the
sysutils/linux-megacli port. First of all you need the mfi_linux.ko
kernel module loaded. Moreover, this module has to be loaded _before_
the Linux ABI stuff (linux.ko, linprocfs.ko, linsysfs.ko). So starting
with a pretty sane list of loaded kernel modules ...

| # kldstat | Id Refs Address Size Name
|    1    3 0xffffffff80100000 6eeea8   kernel
|    2    1 0xffffffff807ef000 14d0     accf_http.ko
|    3    1 0xffffffffb449f000 1fce     nullfs.ko
| # kldload mfi_linux.ko
| # kldload linprocfs.ko linsysfs.ko
| # kldstat | Id Refs Address Size Name
|    1   15 0xffffffff80100000 6eeea8   kernel
|    2    1 0xffffffff807ef000 14d0     accf_http.ko
|    3    1 0xffffffffb449f000 1fce     nullfs.ko
|    7    1 0xffffffffb44a1000 3af      mfi_linux.ko
|    8    3 0xffffffffb44a2000 18a6a    linux.ko
|    9    1 0xffffffffb44bb000 350c     linprocfs.ko
|   10    1 0xffffffffb469a000 9d3      linsysfs.ko
| # mount -t linprocfs linproc /compat/linux/proc
| # mount -t linsysfs  linsys  /compat/linux/sys
| # cat /compat/linux/sys/class/scsi_host/host*/proc_name
|   megaraid_sas
|   megaraid_sas

In case you haven't loaded mfi_linux.ko before the other Linux ABI
stuff, you will see '(null)' entries here instead of 'megaraid_sas'.
Furthermore, the compat.linux.osrelease sysctl should be set to 2.6.12.

| # sysctl -w compat.linux.osrelease=2.6.12
|   compat.linux.osrelease: 2.4.2 -> 2.6.12

If everything is fine, you should be able to query your RAID controller:

| # megacli -LDInfo -LALL -aALL | grep ^State:
|   State: Optimal
|   State: Optimal

This has been tested on a Dell PowerEdge 2970 with both an PERC5/i and
PERC5/e controller running FreeBSD 7.0/amd64.

| # pciconf -lv | grep ^mfi
|   [EMAIL PROTECTED]:8:14:0:       class=0x010400 card=0x1f031028 
chip=0x00151028 rev=0x00 hdr=0x00
|   [EMAIL PROTECTED]:15:14:0:      class=0x010400 card=0x1f011028 
chip=0x00151028 rev=0x00 hdr=0x00


_______________________________________________ mailing list
To unsubscribe, send any mail to "[EMAIL PROTECTED]"

Reply via email to