In the Megacli useful commands with examples, it shows a lot of popular commands show you how to manulapute LSI Mega RAID, such as, finding Adapter, Logical drive, Physical drive info, as well creating RAID. Here is a particular one just for RAID10.

1. Command syntax

MegaCli -CfgLdAdd -rX [E0:S0,E1:S1,...] [WT|WB] [NORA|RA] [Direct|Cached]
        [CachedBadBBU|NoCachedBadBBU] [-szXXX [-szYYY ...]]
        [-strpszM] [-Hsp[E0:S0,...]] [-AfterLdX] | [FDE|CtrlBased]  
        [-Default| -Automatic| -None| -Maximum| -MaximumWithoutCaching]
[-Cache] [-enblPI] [-Force]-aN

2.Get adapter ID (it's 0 in the example below), Enclosure ID, Slot ID:

#MegaCli64 -PDList -aALL | egrep 'Adapter|Enclosure|Slot'
Adapter #0
Enclosure Device ID: 252
Slot Number: 0
Enclosure position: N/A
Enclosure Device ID: 252
Slot Number: 1
Enclosure position: N/A
Enclosure Device ID: 252
Slot Number: 2
Enclosure position: N/A
Enclosure Device ID: 252
Slot Number: 3
Enclosure position: N/A
Enclosure Device ID: 252
Slot Number: 4
Enclosure position: N/A
Enclosure Device ID: 252
Slot Number: 5
Enclosure position: N/A
Enclosure Device ID: 252
Slot Number: 6
Enclosure position: N/A
Enclosure Device ID: 252
Slot Number: 7
Enclosure position: N/A
Enclosure Device ID: 252
Slot Number: 8
Enclosure position: N/A
Enclosure Device ID: 252
Slot Number: 9
Enclosure position: N/A

In above example, we get

Atapter ID    --> 0
Enclosure ID --> 252
Slot Number --> 0,1,2,3,4,5,6,7,8,9

3. Double check if drive are being used for Logical Drive

This command lists all Logical Drives

MegaCli64 -LDInfo -Lall -aALL

This command lists all Logical and its Physical drive info

MegaCli64 -LdPdInfo -aALL

4. Create a RAID0,1,5,6 array with MegaCli

Use the Adapter ID, Enclosure ID, and Slot number that found in step 1. Suppose disk slot 2,3,4,5,6,7,8,9 are not being used.

MegaCli64 -CfgLdAdd -r0 [252:2,252:3] -a0
MegaCli64 -CfgLdAdd -r1 [252:2,252:3] -a0
MegaCli64 -CfgLdAdd -r5 [252:2,252:3,252:4,252:5] -a0
MegaCli64 -CfgLdAdd -r6 [252:2,252:3,252:4,252:5,252:6] -a0

Note: to make RAID0, minimal 2 drives are required.
         to make RAID1, minimal 2 drives are required.
         to make RAID5, minimal 3 drives are required.
         to make RAID6, minimal 4 drives are required.

5. Create a RAID50,raid60 array with MegaCli

Use the Adapter ID, Enclosure ID, and Slot number that found in step 1. Suppose disk slot 2,3,4,5,6,7,8,9 are not being used.

The command is slightly different with the one created raid0.,raid1,raid5, and raid6. Because raid50,60 are netsted raid.

MegaCli64 -CfgLdAdd -r50 raid0[252:2,252:3,252:4] raid1[252:5,252:6,252:7] -a0
MegaCli64 -CfgLdAdd -r60 raid0[252:2,252:3,252:4,252:5] raid1[252:6,252:7,252:8,252,9] -a0
Note: to make RAID50, minimal 6 drives are required.
      to make RAID60, minimal 8 drives are required.

5. Show system summary

MegaCli64 -ShowSummary -aALL
                                     
System
    Operating System:  Linux version 2.6.32-504.23.4.el6.x86_64
    Driver Version: 06.803.01.00-rh1
    CLI Version: 8.07.14

Hardware
        Controller
                 ProductName       : ServeRAID M5015 SAS/SATA Controller(Bus 0, Dev 0)
                 SAS Address       : 500605b004a170a0
                 FW Package Version: 12.12.0-0098
                 Status            : Optimal
        BBU
                 BBU Type          : iBBU08
                 Status            : Healthy
        Enclosure
                 Product Id        : SGPIO           
                 Type              : SGPIO
                 Status            : OK

        PD
                Connector          : Port 0 - 3<Internal>: Slot 1
                Vendor Id          : IBM-ESXS
                Product Id         : ST9300653SS     
                State              : Online
                Disk Type          : SAS,Hard Disk Device
                Capacity           : 278.464 GB
                Power State        : Active
...