Jump to content
XPEnology Community

LSI SAS2008 - Make disk order follow enclosure places


exodius

Recommended Posts

This is the part I regret a bit lately, who used to stick to only the HBA controller.
HBA is a bit concerned about having to consider heat dissipation in the PC.
Also, some users claim that SATA controllers are more reliable than low-cost HBAs.
Recently, there was a system partition error problem due to incorrect use of H200 in DSM7 DS3622xs+, and this problem has been improved with the advice of @pocopico.
There is still a backup XPENOLOGY that uses DSM6, DS918+, and H310, but it has recently encountered a system partition error and has been discontinued.
I am considering updating to DSM7 DS3622xs+ or using Sata controller.

Edited by Peter Suh
Link to comment
Share on other sites

 

8 hours ago, phone guy said:

always see them as disk #2 #3 and #4

 

Its my impression that, on older platforms (DS3615/918/3617/32622/DVA3221),  there is no way to configure the slot#. The disks are represented to the GUI by their device name. eg. sda will always be 1st drive. sde the fifth and so on. So the disks are getting their slot on a sequencial way. Here the SataPortMap, DiskidxMap and sata_remap comes to assist.  

 

So on my system with mptsas (LSI 3Gb/sas HBA)

 

ls -l /sys/block/sd[a-z]/device
lrwxrwxrwx 1 root root 0 May 12 03:13 /sys/block/sdc/device -> ../../../2:0:0:0
lrwxrwxrwx 1 root root 0 May 12 03:13 /sys/block/sdd/device -> ../../../2:0:1:0
lrwxrwxrwx 1 root root 0 May 12 03:13 /sys/block/sde/device -> ../../../2:0:2:0
lrwxrwxrwx 1 root root 0 May 12 03:13 /sys/block/sdf/device -> ../../../2:0:3:0
lrwxrwxrwx 1 root root 0 May 12 03:13 /sys/block/sdg/device -> ../../../2:0:4:0
lrwxrwxrwx 1 root root 0 May 12 03:13 /sys/block/sdh/device -> ../../../2:0:5:0
lrwxrwxrwx 1 root root 0 May 12 03:13 /sys/block/sdi/device -> ../../../2:0:6:0
lrwxrwxrwx 1 root root 0 May 12 03:13 /sys/block/sdj/device -> ../../../2:0:7:0

 

I need to test on my test VM to see if there is a way to fix that.

 

 

On newer platforms with Device tree files the slot number is hardcoded into the model.dtb file and enforced into a specific place on the system. So every HBA port number will be represented on a specific port. 

 

 

Edited by pocopico
  • Like 1
Link to comment
Share on other sites

17 hours ago, pocopico said:

there is no way to configure the slot#. The disks are represented to the GUI by their device name. eg. sda will always be 1st drive. sde the fifth and so on. So the disks are getting their slot on a sequencial way. Here the SataPortMap, DiskidxMap and sata_remap comes to assist. 

That must be because of the HBA?  I have used tcrp on 2 baremetal nas boxes, a western digital nas box and a terramaster nas box, one with 4 bay slots and one with 5 bay slots, each is running dsm7.1.  Those 2 baremetal boxes correctly identify disks inserted into the correct slot.  In other words, when I put a drive in slot 3, it shows graphically in slot 3 of dsm. It does not group them together like it does on the HBA card. This is true on both systems.  I guess in that sense, sata controllers work better?

 

 

  • Like 1
Link to comment
Share on other sites

I tried this before (with 2 DSM6/jun's Loader/LSI HBA systems),

and serched around workarounds, but no luck.

 

So, I wrote a script to confirm mapped drive location.

https://gist.github.com/benok/c117badbfb6af744578d48e2ab1d4d4f

(Just periodically do heavy access to specified drive)

 

But I've encountered one of my array enclosure's LED got broken(no light). it's not so reliable, though.

 

You should write down each Drive's S/N and paste to your caddies.

I think it must be done with LSI controllers.

 

Link to comment
Share on other sites

  • 1 month later...
В 17.04.2022 в 23:50, exodius сказал:

go into option 9, pagetype 1, pagenumber 8

modify offset 0x0c to 02 (bit 1 = Enclosure/Slot mapping mode)

Thank you for this guide!

 

I have LSI Logic SAS2308 D1 (according to lsi util). It is PERC H710P crossflashed to IT mode.

When im trying to change NVRAM, lsiutil says "Failed to write changes!".

Writing "Current" is ok, but it not helps(

 

 

UPD: after reboot it works, whet tried without sas2flash

Edited by robot468
Link to comment
Share on other sites

  • 1 month later...

Wanted to add some info here. I recently changed the motherboard in my proxmox server, where my DS3622xs+ redpill lives. Previously I had a motherboard and PCI HBA card (H710), the new motherboard has a build-in HBA (well, I flashed it to HBA). So after flashing the IT mode FW, and using LSIUTIL, with many thanks to @exodius for this great topic, I reconnected all 8 of my drives to the motherboard SFF HBA ports, and booted back to proxmox and my dsm instance.  It originally came up showing all 8 drives, all green, but the serial number order was all off, but DSM didn't complain (which I thought was strange).  So all my drives are labelled with serial numbers from Seagate (ironwolf's) and I labelled them with drive slot numbers (1-8). So after bootup drive 1 was now 3, 2 was now 8, etc, etc... but dsm said the array was healthy and no errors. (remember I changed motherboards, and now using built in HBA vs PCI card HBA before)

 

I didn't like that since I had them labelled just because of this. So, I powered down, restarted DSM and it booted to a DSM desktop with no drives (I didn't think it would but it did), and I re-attached each drive from 1 thru 8 one drive at a time and they all re-appeared in the correct slot order and cable order, which was not the case when it powered up with all 8 attached on initial power up.  So now all are serial correct, slot correct, numbered correct, and cable correct (drive 1 is SFF port A cable P1 and so on)

 

I just wanted to thank the OP again for this trick, and share my experience as it may help someone in the future, if your drives end up out of order, disconnect them all and re-attached (insert) them 1 drive at a time from drive 1 and continue thru until the end, that should get them back in the correct order.

  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...