007revad / Synology_HDD_db

Add your HDD, SSD and NVMe drives to your Synology's compatible drive database and a lot more

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

M2D18 not shown in GUI

bogdanrotariu opened this issue · comments

Hi,

Got a bunch of M2D18 that I've bought for use in 820+ and never used there and now I have added one card in a RS2421+.
fdisk -l shows the drives before using Synology_HDD_db, but even after running the script, the M2 drives are not shown in the GUI.

Am I missing something or this is not the intended behaviour of seeing and been able to use the M2 drives in GUI?

My full log:

Synology_HDD_db v3.0.56
RS2421+ DSM 7.2-64570-1
Using options: -nfr

HDD/SSD models found: 4
HDWF180,GX0B
HUS728T8TALE6L0,V8DERT06
ST8000NM000A-2KE101,SN03
ST8000VN004-2M2101,SC60

M.2 drive models found: 1
Samsung SSD 980 1TB,3B4QFXO7

M.2 PCIe card models found: 1
M2D18

No Expansion Units found

Added HDWF180 to rs2421+_host_v7.db
Added HDWF180 to ds2415+_host_v7.db
Added HDWF180 to ds2415+_host.db
Added HDWF180 to ds2415+_host_v7.db.new
Added HDWF180 to ds2415+_host.db.new
Added HUS728T8TALE6L0 to rs2421+_host_v7.db
Added HUS728T8TALE6L0 to ds2415+_host_v7.db
Added HUS728T8TALE6L0 to ds2415+_host.db
Added HUS728T8TALE6L0 to ds2415+_host_v7.db.new
Added HUS728T8TALE6L0 to ds2415+_host.db.new
Added ST8000NM000A-2KE101 to rs2421+_host_v7.db
Updated ST8000NM000A-2KE101 to ds2415+_host_v7.db
ST8000NM000A-2KE101 already exists in ds2415+_host.db
Updated ST8000NM000A-2KE101 to ds2415+_host_v7.db.new
ST8000NM000A-2KE101 already exists in ds2415+_host.db.new
Added ST8000VN004-2M2101 to rs2421+_host_v7.db
Added ST8000VN004-2M2101 to ds2415+_host_v7.db
Added ST8000VN004-2M2101 to ds2415+_host.db
Added ST8000VN004-2M2101 to ds2415+_host_v7.db.new
Added ST8000VN004-2M2101 to ds2415+_host.db.new
Added Samsung SSD 980 1TB to rs2421+_host_v7.db
Added Samsung SSD 980 1TB to ds2415+_host_v7.db
Added Samsung SSD 980 1TB to ds2415+_host.db
Added Samsung SSD 980 1TB to ds2415+_host_v7.db.new
Added Samsung SSD 980 1TB to ds2415+_host.db.new
Added Samsung SSD 980 1TB to ds2415+_m2d18_v7.db
Added Samsung SSD 980 1TB to rs2421+_m2d18_v7.db


Disabled support disk compatibility.

Disabled support memory compatibility.

Max memory already set to 32 GB.

Enabled M.2 volume support.

Disabled drive db auto updates.

DSM successfully checked disk compatibility.

You may need to reboot the Synology to see the changes.

Added model.dtb for RS2421+

model.dtb.zip

If everything worked as intended you should be able to see the M2D18 and NVMe drive in storage manager.

I've written a new script just for enabling M2 cards on some models that don't officially support them.
If you run it with the --check option it will show you what M2 card(s) and drive types are currently enabled in DSM in adapter_cards.conf and in model.dtb (for models that have a model.dtb file).

https://github.com/007revad/Synology_enable_M2_card
https://github.com/007revad/Synology_enable_M2_card/releases

Thank you for your involvement in this!
Unfortunately I do not see the NVMe's or the M2D18 in Storage Manager

Here is the output of the script:

`./syno_enable_m2_card.sh
Synology_enable_M2_card v1.0.1
RS2421+ DSM 7.2-64570-1

  1. E10M20-T1 3) M2D18 5) ALL
  2. M2D20 4) M2D17 6) Quit
    Select your M.2 Card: 3
    Backed up adapter_cards.conf

M2D18 NVMe already enabled for RS2421+
M2D18 SATA already enabled for RS2421+
Backed up model.dtb

Contact 007revad to get an edited model.dtb file for your model.

Finished
root@syno:/volume1/scripts# ./syno_enable_m2_card.sh --check
Synology_enable_M2_card v1.0.1
RS2421+ DSM 7.2-64570-1

Using options: --check

E10M20-T1 NIC = yes
E10M20-T1 NVMe = yes
E10M20-T1 SATA = yes
E10M20-T1 enabled in /etc.defaults/model.dtb

M2D20 NVMe = yes
M2D20 enabled in /etc.defaults/model.dtb

M2D18 NVMe = yes
M2D18 SATA = yes
M2D18 not enabled in /etc.defaults/model.dtb

M2D17 SATA =
M2D17 not enabled in /etc.defaults/model.dtb

root@syno:/volume1/scripts#
`

Can you run it again. I just added an edited version of the RS2421+ model.dtb that includes the M2D18

Tested main and development branch, /etc.defaults/model.dtb still missing M2D18.

# ./syno_enable_m2_card.sh 
Synology_enable_M2_card v1.0.1
RS2421+ DSM 7.2-64570-1 

1) E10M20-T1  3) M2D18	    5) ALL
2) M2D20      4) M2D17	    6) Quit
Select your M.2 Card: 3

M2D18 NVMe already enabled for RS2421+
M2D18 SATA already enabled for RS2421+

Contact 007revad to get an edited model.dtb file for your model.

Finished

# ./syno_enable_m2_card.sh --check
Synology_enable_M2_card v1.0.1
RS2421+ DSM 7.2-64570-1 

Using options: --check

E10M20-T1 NIC = yes
E10M20-T1 NVMe = yes
E10M20-T1 SATA = yes
E10M20-T1 enabled in /etc.defaults/model.dtb

M2D20 NVMe = yes
M2D20 enabled in /etc.defaults/model.dtb

M2D18 NVMe = yes
M2D18 SATA = yes
M2D18 not enabled in /etc.defaults/model.dtb

M2D17 SATA = yes
M2D17 not enabled in /etc.defaults/model.dtb

# grep -cia m2d1 /etc.defaults/model.dtb
0
# grep -cia m2d2 /etc.defaults/model.dtb
1

and bash -x output, maybe it helps

# bash -x syno_enable_m2_card.sh 
+ scriptver=v1.0.1
+ script=Synology_enable_M2_card
+ repo=007revad/Synology_enable_M2_card
++ basename /bin/bash
+ '[' '!' bash = bash ']'
+ Yellow='\e[0;33m'
+ Cyan='\e[0;36m'
+ Error='\e[41m'
+ Off='\e[0m'
+ args=("$@")
++ getopt -o abcdefghijklmnopqrstuvwxyz0123456789 -a -l check,restore,help,version,log,debug --
+ options=' --'
+ eval set -- ' --'
++ set -- --
+ true
+ case "${1,,}" in
+ shift
+ break
+ [[ '' == \y\e\s ]]
++ whoami
+ [[ root != \r\o\o\t ]]
+ echo 'Synology_enable_M2_card v1.0.1'
Synology_enable_M2_card v1.0.1
++ cat /proc/sys/kernel/syno_hw_version
+ model=RS2421+
+ modelname=RS2421+
++ get_key_value /etc.defaults/VERSION productversion
+ productversion=7.2
++ get_key_value /etc.defaults/VERSION buildphase
+ buildphase=GM
++ get_key_value /etc.defaults/VERSION buildnumber
+ buildnumber=64570
++ get_key_value /etc.defaults/VERSION smallfixnumber
+ smallfixnumber=1
+ [[ GM == GM ]]
+ buildphase=
+ [[ 1 -gt 0 ]]
+ smallfix=-1
+ echo -e 'RS2421+ DSM 7.2-64570-1 \n'
RS2421+ DSM 7.2-64570-1 

+ [[ 0 -gt 0 ]]
++ get_latest_release 007revad/Synology_enable_M2_card
++ curl --silent -m 10 --connect-timeout 5 https://api.github.com/repos/007revad/Synology_enable_M2_card/releases/latest
++ grep '"tag_name":'
++ sed -E 's/.*"([^"]+)".*/\1/'
+ tag=
+ shorttag=
+ source=syno_enable_m2_card.sh
+ '[' -L syno_enable_m2_card.sh ']'
+++ dirname syno_enable_m2_card.sh
++ cd -P .
++ pwd
+ scriptpath=/volume1/scripts/syno_enable_m2
+ printf '%s\n%s\n' '' v1.0.1
+ sort --check --version-sort
+ m2cardconf=/usr/syno/etc.defaults/adapter_cards.conf
+ modeldtb=/etc.defaults/model.dtb
+ [[ '' == \y\e\s ]]
+ [[ '' == \y\e\s ]]
+ PS3='Select your M.2 Card: '
+ options=("E10M20-T1" "M2D20" "M2D18" "M2D17" "ALL" "Quit")
+ select choice in "${options[@]}"
1) E10M20-T1  3) M2D18	    5) ALL
2) M2D20      4) M2D17	    6) Quit
Select your M.2 Card: 3
+ case "$choice" in
+ m2d18
+ backupdb /usr/syno/etc.defaults/adapter_cards.conf
+ [[ ! -f /usr/syno/etc.defaults/adapter_cards.conf.bak ]]
++ stat -c '%a %n' /usr/syno/etc.defaults/adapter_cards.conf
++ cut '-d ' -f1
+ octal=644
+ [[ ! 644 -eq 644 ]]
+ return 0
+ echo ''

+ enable_card /usr/syno/etc.defaults/adapter_cards.conf M2D18_sup_nvme 'M2D18 NVMe'
+ [[ -f /usr/syno/etc.defaults/adapter_cards.conf ]]
+ [[ -n M2D18_sup_nvme ]]
+ [[ -n M2D18 NVMe ]]
+ grep '^\[M2D18_sup_nvme\]$' /usr/syno/etc.defaults/adapter_cards.conf
++ get_section_key_value /usr/syno/etc.defaults/adapter_cards.conf M2D18_sup_nvme RS2421+
+ val=yes
+ [[ yes != \y\e\s ]]
+ echo -e '\e[0;33mM2D18 NVMe\e[0m already enabled for \e[0;36mRS2421+\e[0m'
M2D18 NVMe already enabled for RS2421+
+ enable_card /usr/syno/etc.defaults/adapter_cards.conf M2D18_sup_sata 'M2D18 SATA'
+ [[ -f /usr/syno/etc.defaults/adapter_cards.conf ]]
+ [[ -n M2D18_sup_sata ]]
+ [[ -n M2D18 SATA ]]
+ grep '^\[M2D18_sup_sata\]$' /usr/syno/etc.defaults/adapter_cards.conf
++ get_section_key_value /usr/syno/etc.defaults/adapter_cards.conf M2D18_sup_sata RS2421+
+ val=yes
+ [[ yes != \y\e\s ]]
+ echo -e '\e[0;33mM2D18 SATA\e[0m already enabled for \e[0;36mRS2421+\e[0m'
M2D18 SATA already enabled for RS2421+
+ edit_modeldtb M2D18
+ [[ -f /etc.defaults/model.dtb ]]
+ backupdb /etc.defaults/model.dtb
+ [[ ! -f /etc.defaults/model.dtb.bak ]]
++ stat -c '%a %n' /etc.defaults/model.dtb
++ cut '-d ' -f1
+ octal=644
+ [[ ! 644 -eq 644 ]]
+ return 0
+ grep --text M2D18 /etc.defaults/model.dtb
+ [[ RS2421+ == \D\S\1\8\2\1\+ ]]
+ [[ RS2421+ == \D\S\1\6\2\1\+ ]]
+ [[ RS2421+ == \D\S\1\5\2\0\+ ]]
+ [[ RS2421+ == \R\S\8\2\2\r\p\+ ]]
+ [[ RS2421+ == \R\S\8\2\2\+ ]]
+ [[ RS2421+ == \R\S\1\2\2\1\r\p\+ ]]
+ [[ RS2421+ == \R\S\1\2\2\1\+ ]]
+ echo -e '\n\e[0;36mContact 007revad to get an edited model.dtb file for your model.\e[0m'

Contact 007revad to get an edited model.dtb file for your model.
+ break
+ [[ '' == \y\e\s ]]
+ echo -e '\nFinished'

Finished

I see the problem. I've edited and uploaded 13 different NAS model's model.dtb file... but the script was only setup to download an edited model.dtb for 7 different models. I've added the 6 missing models to v1.0.2-beta
https://github.com/007revad/Synology_enable_M2_card/releases/tag/v1.0.2-beta

Yes, wanted to tell you now, added [[ $modelname == "RS2421+" ]] and it works!

Thank you very much!

Awesome! Thank you for testing and confirming it works.