• Making RHEL 3 See Multiple LUNS

    For some reason RHEL 3 comes out of the box configured to see only the first Lun on a SCSI channel. This is usually not a problem, as the first Lun is all you care about, but in some instances, you will need to configure the SCSI module to see multiple Luns.

    In this case we are using an Adaptec DuraStor 6200S, which is set up to present the RAID controller as Lun 00, and the actual RAID array as Lun 01. Without any modifications to the system, we plug in in, and after a reboot check /proc/scsi/scsi. We can see the RAID controller, but since we can only see the first Lun on the channel, we never get to the array:

    Host: scsi2 Channel: 00 Id: 00 Lun: 00
    Vendor: Adaptec Model: DuraStor 6200S Rev: V100
    Type: Processor ANSI SCSI revision: 03

    The actual array would show up as “Channel: 00 Id: 00 Lun: 01″, but it’s not there. To resolve this, we have to first edit “/etc/modules.conf” and add the following line:

    options scsi_mod max_scsi_luns=128 scsi_allow_ghost_devices=1

    In our case, modules.conf looks like this after the modification:

    alias eth0 e1000
    alias eth1 e1000
    alias scsi_hostadapter megaraid2
    alias usb-controller usb-uhci
    alias usb-controller1 ehci-hcd
    alias scsi_hostadapter1 aic7xxx
    options scsi_mod max_scsi_luns=128 scsi_allow_ghost_devices=1

    Next we have to build a new initrd image. This is done with the “mkinitrd” command.

    WARNING: MAKE DARN SURE you build this against the right kernel (the kernel you want to use). If you are going to replace your current initrd image with the new one, you should make a back-up copy first. The -f option will force or overwrite the current initrd image file.

    cp /boot/initrd-2.4.21-47.ELsmp.img /boot/initrd-2.4.21-47.ELsmp.img.bak
    mkinitrd -f -v /boot/initrd-2.4.21-47.ELsmp.img 2.4.21-47.ELsmp

    Once this is done, you can reboot your machine, and check “/proc/scsi/scsi” to see confirm that it sees the second Lun. You should see something like this:

    Host: scsi2 Channel: 00 Id: 00 Lun: 00
    Vendor: Adaptec Model: DuraStor 6200S Rev: V100
    Type: Processor ANSI SCSI revision: 03

    Host: scsi2 Channel: 00 Id: 00 Lun: 01
    Vendor: Adaptec Model: DuraStor 6200S Rev: V100
    Type: Direct-Access ANSI SCSI revision: 03

    Hat Tip: Alan Baker for help figuring this out.
    UPDATE: RHEL 4 doest not have this problem.

    This entry was posted on Monday, October 16th, 2006 at 10:38 am and is filed under Data and Technology. You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.
  • 1 Comment

    Take a look at some of the responses we've had to this article.

    1. Al Baker rocks.

      That is all.

  • Leave a Reply

    Let us know what you thought.

  • Name (required):

    Email (required):

    Website:

    Message:

Visitors have tagged this post: t (110) - spiralbound net (28) - mkinitrd rhel (22) - scsi_allow_ghost_devices (20) - f (19) - RHEL mkinitrd (18) - scsi_allow_ghost_devices=1 (13) - alias (13) - scsi_mod max_scsi_luns (9) - rhel4 mkinitrd (9) - max_scsi_luns (9) - mkinitrd + scsi (8) - options scsi_mod max_scsi_luns (8) - linux multiple LUNs (7) - Multi LUN (7) - how to check luns in linux (7) - rhel3 lun (7) - mount lun (7) - multiple luns (6) - options scsi_mod max_scsi_luns=128 (6) - rhel3 multiple luns (6) - scsi-multi-lun (6) - mkinitrd rhel5 (6) - creating LUNs on RAID system (6) - rhel initrd (5) - max_scsi_luns RHEL (5) - linux multi lun (5) - mount lun in linux (5) - show luns linux (5) - MOUNT LUN LINUX (5) - rhel5 mkinitrd (5) - LUN rhel (5) - linux multiple lun (4) - RHEL3 + mkinitrd (4) - mkinitrd rhel3 (4) - rhel4 initrd (4) - RHeL 4 mkinitrd (4) - RHEL 3 USB support (4) - Host Channel Id Lun (4) - multiple scsi_hostadapter (3) - scsi_mod options (3) - rhel scsi lun (3) - options scsi_mod (3) - linux scsi multi lun (3) - multiple lun support (3) - rhel show luns (3) - mkinitrd rhel 4 (3) - max_scsi_luns mkinitrd (3) - adaptec multi lUN (3) - rhel usb disk (3) - max_scsi_luns RHEL 3 (3) - linux scsi multiple luns (3) - linux luns (3) - scsi_allow_ghost_devices rhel4 (3) - " luns in LINUX" (3) - linux usb multiple lun (3) - aic7xxx LUNs (3) - scsi multiple lun (3) - check lun linux (3) - mkinitrd scsi vmware (3) - edit initrd (3) - lun rhel3 (3) - linux show luns (3) - how to mount lun linux (3) - rhel lun (3) - rhel 5 add lun (3) - rhel show disks (3) - multi lun support (3) - linux mount LUN (3) - mkinitrd rhel 5 (3) - linux show lun (3) - Mount Network Drive RHEL (3) - how to check LUN in linux (3) - how to mount luns in linux (3) - usb to scsi multiple luns (3) - rhel3 mkinitrd (3) - solaris show luns (3) - Create Lun Linux (3) - solaris (2) - rhel (2) - all (2) - scsi_allow_ghost_devices RHEL 4 (2) - rhel 3 mkinitrd (2) - mkinitrd luns (2) - adaptec multiple luns (2) - RHEL AS 3 mkinitrd (2) - solaris 10 multi LUN (2) - rhel alias scsi_hostadapter (2) - solaris scsi multiple lun (2) - edit initrd rhel3 (2) - RHEL multi lun support (2) - RHEL Multiple LUNs (2) - RHEL3 max_scsi_luns (2) - linux kernel multiple lun support (2) - rhel scsi multi lun (2) - rhel4 initrd mounten (2) - rhel3 modules.conf (2) - multiple luns in RHEL (2) - rhel3 multiple lun (2) - rhel lun support (2) - configure lun in linux (2) - Multiple Lun Support Linux (2) - linux multiple lun support (2) - rhel4 modules.conf (2) - RHEL + RAID (2) - RHEL mount usb (2) - options scsi_mod scsi_allow_ghost_devices=1 (2) - configure LUN linux (2) - linux multi luns (2) - how to configure raid in rhel3 (2) - linux aic7xxx lun option (2) - solaris lun support (2) - usb storage module multiple lun (2) - rhel mount lun (2) - mkinitrd rhel4 (2) - max_scsi_luns modules.conf (2) - max_scsi_luns RHEL3 (2) - rhel multiple lun support (2) - linux max_scsi_luns (2) - how to check lun in solaris (2) - check max_scsi_luns (2) - creating luns in linux (2) - multiple disks on one usb only seeing one disk (2) - support multiple SCSI luns on Linux (2) - modules.conf max_scsi_luns (2) - how to configure multiple LUN support (2) - add lun rhel (2) - configuring LUNs in solaris (2) - max_scsi_luns rhel4 (2) - solaris only see first lun (2) - rhel3 scsi LUNS (2) - rhel5 multiple lun support (2) - rhel4 mkinitrd modules (2) - rhel linux cp overwrite (2) - increasing LUN support for RHEL 5 (2) - vmware multi lun (2) - rhel4 multilun (2) - LUN in Solaris (2) - mkinitrd rhel modules (2) - seeing luns on linux (2) - mkinitrd 2 4 21-47 (2) - multiple LUN solaris 10 (2) - RHEL4 enable multiple LUNS (2) - 2 luns linux mount (2) - rhel4 how to mkinitrd (2) - Durastor 6200s (2) - luns in rhel (2) - lun linux (2) - linux scsi multiple lun (2) - add lun to linux (2) -