Jump to content
XPEnology Community

Mobo implements only latter half of SATA ports, making whole controller unusable


updateing

Recommended Posts

I've got the following setup:

 

CPU: Intel Core i7-12700

Mobo: ASRock H670M-ITX/ax

RAM: 8GB DDR4-2400 *2

Storage: 3TB Toshiba HDD *1 (this is only a test drive)

NIC: Mellanox ConnectX-2 10Gb (Ethernet)

OS: Proxmox VE 7.4

 

A virtual machine with onboard SATA controller and 10G NIC VF passthrough has been setup to run TCRP and DSM. Software versions are listed as follows:

 

Loader: TCRP 0.8.0.3 (setup as DS918+ with redpill-acpid extension)

DSM: 7.1.0-42661

 

When executing `./rploader.sh satamap now` in TC, it showed:

 

tc@box:~$ ./rploader.sh satamap now
Machine is VIRTUAL Hypervisor=KVM

Found "00:1f.2 Intel Corporation 82801IR/IO/IH (ICH9R/DO/DH) 6 port SATA Controller [AHCI mode] (rev 02)"
Detected 6 ports/0 drives. Mapping KVM q35 bogus controller after maxdisks

Found "01:00.0 Intel Corporation Device 7ae2 (rev 11)"
Detected 8 ports/1 drives. Bad ports: 1 2 3 4. Override # of ports or ENTER to accept <8>

Computed settings:
SataPortMap=18
DiskIdxMap=1000

WARNING: Bad ports are mapped. The DSM installation will fail!

Should i update the user_config.json with these values ? [Yy/Nn]

 

It suggests ports 1, 2, 3 and 4 on onboard SATA controller is bad. After some digging into the script I'm able to confirm that:

 

tc@box:~$ sudo dmesg|grep ata
[    0.031244] Memory: 6093272K/6290892K available (10242K kernel code, 1227K rwdata, 1916K rodata, 1184K init, 3660K bss, 197364K reserved, 0K cma-reserved)
[    0.295897] libata version 3.00 loaded.
[    0.437601] ata1: SATA max UDMA/133 abar m4096@0xfea1f000 port 0xfea1f100 irq 28
[    0.437604] ata2: SATA max UDMA/133 abar m4096@0xfea1f000 port 0xfea1f180 irq 28
[    0.437606] ata3: SATA max UDMA/133 abar m4096@0xfea1f000 port 0xfea1f200 irq 28
[    0.437608] ata4: SATA max UDMA/133 abar m4096@0xfea1f000 port 0xfea1f280 irq 28
[    0.437611] ata5: SATA max UDMA/133 abar m4096@0xfea1f000 port 0xfea1f300 irq 28
[    0.437613] ata6: SATA max UDMA/133 abar m4096@0xfea1f000 port 0xfea1f380 irq 28
[    0.497715] ata7: DUMMY
[    0.497716] ata8: DUMMY
[    0.497716] ata9: DUMMY
[    0.497716] ata10: DUMMY
[    0.497722] ata11: SATA max UDMA/133 abar m2048@0xfe803000 port 0xfe803300 irq 29
[    0.497723] ata12: SATA max UDMA/133 abar m2048@0xfe803000 port 0xfe803380 irq 29
[    0.497724] ata13: SATA max UDMA/133 abar m2048@0xfe803000 port 0xfe803400 irq 29
[    0.497726] ata14: SATA max UDMA/133 abar m2048@0xfe803000 port 0xfe803480 irq 29
[    0.498087] scsi host14: pata_legacy
[    0.498097] ata15: PATA max PIO4 cmd 0x1f0 ctl 0x3f6 irq 14
[    0.766974] ata5: SATA link down (SStatus 0 SControl 300)
[    0.767034] ata1: SATA link down (SStatus 0 SControl 300)
[    0.767125] ata4: SATA link down (SStatus 0 SControl 300)
[    0.767188] ata3: SATA link down (SStatus 0 SControl 300)
[    0.770401] ata6: SATA link down (SStatus 0 SControl 300)
[    0.773793] ata2: SATA link up 1.5 Gbps (SStatus 113 SControl 300)
[    0.773933] ata2.00: ATAPI: QEMU DVD-ROM, 2.5+, max UDMA/100
[    0.773934] ata2.00: applying bridge limits
[    0.774254] ata2.00: configured for UDMA/100
[    0.809825] ata14: SATA link down (SStatus 0 SControl 300)
[    0.810038] ata12: SATA link down (SStatus 0 SControl 300)
[    0.810057] ata11: SATA link up 6.0 Gbps (SStatus 133 SControl 300)
[    0.810071] ata13: SATA link down (SStatus 0 SControl 300)
[    0.811840] ata11.00: ATA-8: TOSHIBA DT01ACA300, MX6OABB0, max UDMA/133
[    0.811841] ata11.00: 5860533168 sectors, multi 16: LBA48 NCQ (depth 32), AA
[    0.813863] ata11.00: configured for UDMA/133
[    0.906407] scsi host14: pata_legacy
[    0.906443] ata16: PATA max PIO4 cmd 0x170 ctl 0x376 irq 15
[    1.110280] usbcore: registered new interface driver ums-datafab
[    1.132122] Write protecting the kernel read-only data: 14336k
[    1.132615] Freeing unused kernel image (text/rodata gap) memory: 2044K
[    1.132714] Freeing unused kernel image (rodata/data gap) memory: 132K

 

ata7~ata14 is the onboard SATA controller. Only the latter 4 ports are actually implemented on the board.

 

This can be also verified in Proxmox VE kernel messages:

 

root@Hamster-PVE:~# dmesg|grep -i ata
[    0.000000] BIOS-e820: [mem 0x0000000065612000-0x00000000656dffff] ACPI data
[    0.012427] NODE_DATA(0) allocated [mem 0x48f7d6000-0x48f7fffff]
[    0.079435] Memory: 15984708K/16544452K available (16393K kernel code, 4342K rwdata, 10192K rodata, 2888K init, 4900K bss, 559484K reserved, 0K cma-reserved)
[    0.488570] libata version 3.00 loaded.
[    1.137309] Write protecting the kernel read-only data: 28672k
[    1.137958] Freeing unused kernel image (text/rodata gap) memory: 2036K
[    1.138203] Freeing unused kernel image (rodata/data gap) memory: 48K
[    1.206668] ahci 0000:00:17.0: AHCI 0001.0301 32 slots 4 ports 6 Gbps 0xf0 impl SATA mode
[    1.247136] ata1: DUMMY
[    1.247137] ata2: DUMMY
[    1.247137] ata3: DUMMY
[    1.247138] ata4: DUMMY
[    1.247143] ata5: SATA max UDMA/133 abar m2048@0x70c22000 port 0x70c22300 irq 125
[    1.247144] ata6: SATA max UDMA/133 abar m2048@0x70c22000 port 0x70c22380 irq 125
[    1.247146] ata7: SATA max UDMA/133 abar m2048@0x70c22000 port 0x70c22400 irq 125
[    1.247146] ata8: SATA max UDMA/133 abar m2048@0x70c22000 port 0x70c22480 irq 125
[    1.559759] ata8: SATA link down (SStatus 0 SControl 300)
[    1.563563] ata6: SATA link down (SStatus 0 SControl 300)
[    1.563613] ata5: SATA link up 6.0 Gbps (SStatus 133 SControl 300)
[    1.563959] ata7: SATA link down (SStatus 0 SControl 300)
[    1.564828] ata5.00: ATA-8: TOSHIBA DT01ACA300, MX6OABB0, max UDMA/133
[    1.565066] ata5.00: ATA Identify Device Log not supported
[    1.565066] ata5.00: 5860533168 sectors, multi 16: LBA48 NCQ (depth 32), AA
[    1.566639] ata5.00: ATA Identify Device Log not supported
[    1.566640] ata5.00: configured for UDMA/133
[    1.566706] scsi 4:0:0:0: Direct-Access     ATA      TOSHIBA DT01ACA3 ABB0 PQ: 0 ANSI: 5

 

I've tried using `SataPortMap=18 DiskIdxMap=1000` suggested by rploader.sh, but DSM installation just won't start saying "We've detected errors on your hard drives (1,2,3,4) and the SATA ports have also been disabled." Adding `DiskSeqReverse=08` or `sata_remap=0>7:7>0` does not affect the probing of first 4 ports, and DSM still refuses to install.

 

I'm out of ideas here. Can anybody help? Thanks!

Edited by updateing
Add TCRP configuration
Link to comment
Share on other sites

11 minutes ago, updateing said:

I've tried using `SataPortMap=18 DiskIdxMap=1000` suggested by rploader.sh

 

It also specifically reported

WARNING: Bad ports are mapped. The DSM installation will fail!

 

Disable your physical SATA controller and install using a virtual disk.  Then once DSM is installed, restore the satamap to support the SATA controller.  The DUMMY entries are only an issue for the initial installation.

 

Many options are explained in the tutorial here:

https://xpenology.com/forum/topic/62221-tutorial-installmigrate-to-dsm-7x-with-tinycore-redpill-tcrp-loader/

Link to comment
Share on other sites

Wow that's really quick. Thanks for the tip! I'll try and report back in a day.

 

I have to admit that I truly did not notice the presence of that thread, sorry :-| But some minor suggestions might be useful: I've tried searching for "WARNING: Bad ports are mapped" and "Bad ports are mapped", nothing came up. Maybe we can extend the sentence to its whole in the thread, so that people can find them more easily?

 

And the post is not referenced in the most exposed FAQ threads either (the DSM7 Loader and Platforms thread has more exposure there). Maybe we can add link to this thread to "Links to Loaders" thread?

Edited by updateing
Add links
Link to comment
Share on other sites

I'm reporting back: after some trial and error this thing finally worked!

 

The keys are:

 

* there must be no dummy ata ports during initial installation.

* a disk with loader's DSM version installed must be listed before any dummy ata port for post-installation operation.

 

Here is what I did:

 

0. To begin with, I had 2 SATA controllers in my VM: the first one is a bogus q35 controller, the second one is the passthrough onboard SATA controller. The latter exposed 8 ports where first 4 were dummy.

1. I removed the passthrough controller (setting SataPortMap=10 caused a kernel panic so I had to take the trouble to remove it), and added a virtual SATA disk.

2. Last step made SATA controllers in VM appear as: q35 bogus + emulated ICH SATA controller. I set SataPortMap=14, DiskIdxMap=1000 and DSM installation went fine.

3. Added the passthrough onboard SATA controller back.

4. Controller in VM was q35 bogus + onboard + emulated. I set SataPortMap=181, DiskIdxMap=100100, and DSM could boot with all 4 physical disks populated. I tried SataPortMap=181 and DiskIdxMap=100008, DSM would go into "Migratable" state and fail with the infamous "We detected errors on your hard drive..." message.

 

I'm planning to add "sata_remap" to fix port ordering, but at least it works now.

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...