diff --git a/CHANGES.txt b/CHANGES.txt
index 2926d54..da9b842 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -1,3 +1,6 @@
+v3.3.73
+- Bug fix for vendor id.
+
v3.3.72
- Bug fix for enabling creating storage pools in Storage Manager for M.2 drives in PCIe adaptor cards.
- Bug fix for not copying syno_hdd_db_vendors.txt to script location when script updates itself.
diff --git a/README.md b/README.md
index 4e37389..a925040 100644
--- a/README.md
+++ b/README.md
@@ -98,6 +98,20 @@ ### Running the script via SSH

+### vendor_ids.txt
+
+You only need to edit syno_hdd_vendor_ids.txt if the script warns you about a missing vendor id.
+
+If DSM doesn't know the brand of your NVMe drives they will show up in Storage Manager as Unknown brand, and Unrecognised firmware version.
+
+
+
+In this case the script will show you the vendor ID and advise you to add it to the syno_hdd_vendor_ids.txt file.
+
+
+
+
+
**Credits**
- The idea for this script came from a comment made by Empyrealist on the Synology subreddit.
diff --git a/images/vendor_ids.png b/images/vendor_ids.png
new file mode 100644
index 0000000..a0440f3
Binary files /dev/null and b/images/vendor_ids.png differ
diff --git a/syno_hdd_db.sh b/syno_hdd_db.sh
index bc363a4..02bc6fa 100644
--- a/syno_hdd_db.sh
+++ b/syno_hdd_db.sh
@@ -21,8 +21,8 @@
#
# Added new vendor ids for Apacer, aigo, Lexar and Transcend NVMe drives.
#
-# Now includes syno_hdd_vendor.txt so users can add their NVMe drive's vendor id.
-# - syno_hdd_vendor.txt needs to be in the same folder as syno_hdd_db.sh
+# Now includes syno_hdd_vendor_ids.txt so users can add their NVMe drive's vendor id.
+# - syno_hdd_vendor_ids.txt needs to be in the same folder as syno_hdd_db.sh
#
# Now warns if script is located on an M.2 volume.
@@ -178,7 +178,7 @@ fi
# Check script is running as root
if [[ $( whoami ) != "root" ]]; then
ding
- echo -e "${Error}ERROR${Off} This script must be run as root or sudo!"
+ echo -e "${Error}ERROR${Off} This script must be run as sudo or root!"
exit 1
fi
@@ -654,16 +654,16 @@ vendor_from_id(){
0x05dc) vendor=Lexar ;;
0x1d79) vendor=Transcend;;
*)
- # Get vendor from syno_hdd_vendor.txt
- vidlist="$scriptpath/syno_hdd_vendor.txt"
+ # Get vendor from syno_hdd_vendor_ids.txt
+ vidlist="$scriptpath/syno_hdd_vendor_ids.txt"
if [[ -r "$vidlist" ]]; then
val=$(synogetkeyvalue "$vidlist" "$1")
- if synogetkeyvalue "$vidlist" "$1"; then
+ if [[ -n "$val" ]]; then
vendor="$val"
else
- echo -e "\n${Yellow}WARNING{OFF} No vendor found for vid $1" >&2
- echo -e "You can add your drive's vendor to: "
- echo "$vidlist"
+ echo -e "\n${Yellow}WARNING${Off} No vendor found for vid $1" >&2
+ echo -e "You can add ${Cyan}$1${Off} and your drive's vendor to: " >&2
+ echo "$vidlist" >&2
fi
else
echo -e "\n${Error}ERROR{OFF} $vidlist not found!" >&2
@@ -681,9 +681,9 @@ set_vendor(){
synosetkeyvalue "$vidfile" "${vid,,}" "$vendor"
val=$(synogetkeyvalue "$vidfile" "${vid,,}")
if [[ $val == "${vendor}" ]]; then
- echo "Added $vendor to pci_vendor_ids" >&2
+ echo -e "\nAdded $vendor to pci_vendor_ids" >&2
else
- echo "Failed to add $vendor to pci_vendor_ids!" >&2
+ echo -e "\nFailed to add $vendor to pci_vendor_ids!" >&2
fi
fi
if ! grep "$vid" "$vidfile2" >/dev/null; then
@@ -1774,7 +1774,7 @@ if [[ $wdda == "no" ]]; then
fi
-# Enabled creating pool on drives in M.2 adaptor card
+# Enable creating pool on drives in M.2 adaptor card
if [[ -f "$strgmgr" ]]; then
# StorageManager package is installed
if [[ ${#m2cards[@]} -gt "0" ]]; then
diff --git a/syno_hdd_vendor_ids.txt b/syno_hdd_vendor_ids.txt
index 12bec6b..44f51d5 100644
--- a/syno_hdd_vendor_ids.txt
+++ b/syno_hdd_vendor_ids.txt
@@ -1,4 +1,6 @@
-# You can add your drive's vendor id and vendor name here
+# You can add your drive's vendor id and vendor name here.
+#
+# Only edit this file if the script warns you about a missing vendor id.
0x1dbe="ADATA"
0x0ed1="aigo"