[GH-ISSUE #411] synosetkeyvalue error while run #647

Closed
opened 2026-03-11 12:52:26 +03:00 by kerem · 5 comments
Owner

Originally created by @phit42 on GitHub (Dec 29, 2024).
Original GitHub issue: https://github.com/007revad/Synology_HDD_db/issues/411

Should I worry when the script throws an error right in the middle of things and then apparently continues?

./syno_hdd_db.sh: line 2139: /tmpRoot/usr/syno/bin/synosetkeyvalue: No such file or directory

Here is the full log:
Synology_HDD_db-OUTPUT.txt

Also a little feature request: even when the vendor id has been matched, show it somewhere in the output to be able to confirm it.

Originally created by @phit42 on GitHub (Dec 29, 2024). Original GitHub issue: https://github.com/007revad/Synology_HDD_db/issues/411 Should I worry when the script throws an error right in the middle of things and then apparently continues? `./syno_hdd_db.sh: line 2139: /tmpRoot/usr/syno/bin/synosetkeyvalue: No such file or directory` Here is the full log: [Synology_HDD_db-OUTPUT.txt](https://github.com/user-attachments/files/18270116/Synology_HDD_db-OUTPUT.txt) Also a little feature request: even when the vendor id has been matched, show it somewhere in the output to be able to confirm it.
kerem closed this issue 2026-03-11 12:52:31 +03:00
Author
Owner

@007revad commented on GitHub (Dec 29, 2024):

Should I worry when the script throws an error right in the middle of things and then apparently continues?
Normally I would worry too, except in this the error was trivial and the script did actually do what it was supposed to on the previous line.

/usr/syno/bin/synosetkeyvalue /etc.defaults/synoinfo.conf drive_db_test_url "127.0.0.1"
[ -d /tmpRoot ] && /tmpRoot/usr/syno/bin/synosetkeyvalue /tmpRoot/etc.defaults/synoinfo.conf drive_db_test_url "127.0.0.1"

The 2nd line was added by one of the xpenology devs, and I assumed they knew what they doing. I guess they didn't care if there was a trivial error message because they run the script while DSM is booting so nobody would see the message.

The reason they wanted that line added was because during DSM's junior boot process /usr/syno/bin/synosetkeyvalue is not available, so during boot xpe has it's own copy of synosetkeyvalue (and other files) that run from /tmpRoot

I'm not sure how your NAS has /tmpRoot but it does not contain /tmpRoot/usr/syno/bin/synosetkeyvalue

To make that line bulletproof I'd need to check both files exist in /tmpRoot

if [ -f /tmpRoot/usr/syno/bin/synosetkeyvalue ] && [ -f /tmpRoot/etc.defaults/synoinfo.conf ]; then
    /tmpRoot/usr/syno/bin/synosetkeyvalue /tmpRoot/etc.defaults/synoinfo.conf drive_db_test_url "127.0.0.1"
fi
<!-- gh-comment-id:2564816982 --> @007revad commented on GitHub (Dec 29, 2024): > Should I worry when the script throws an error right in the middle of things and then apparently continues? Normally I would worry too, except in this the error was trivial and the script did actually do what it was supposed to on the previous line. ``` /usr/syno/bin/synosetkeyvalue /etc.defaults/synoinfo.conf drive_db_test_url "127.0.0.1" [ -d /tmpRoot ] && /tmpRoot/usr/syno/bin/synosetkeyvalue /tmpRoot/etc.defaults/synoinfo.conf drive_db_test_url "127.0.0.1" ``` The 2nd line was added by one of the xpenology devs, and I assumed they knew what they doing. I guess they didn't care if there was a trivial error message because they run the script while DSM is booting so nobody would see the message. The reason they wanted that line added was because during DSM's junior boot process /usr/syno/bin/synosetkeyvalue is not available, so during boot xpe has it's own copy of synosetkeyvalue (and other files) that run from /tmpRoot I'm not sure how your NAS has /tmpRoot but it does not contain /tmpRoot/usr/syno/bin/synosetkeyvalue To make that line bulletproof I'd need to check both files exist in /tmpRoot ``` if [ -f /tmpRoot/usr/syno/bin/synosetkeyvalue ] && [ -f /tmpRoot/etc.defaults/synoinfo.conf ]; then /tmpRoot/usr/syno/bin/synosetkeyvalue /tmpRoot/etc.defaults/synoinfo.conf drive_db_test_url "127.0.0.1" fi ```
Author
Owner

@007revad commented on GitHub (Dec 29, 2024):

A bigger concern is why one of your drive models is shown as "4TB"
4TB,VE0R5305,4000 GB

From a quick google for VE0R5305 it looks like that SSD drive is an Intenso SSD 4TB

Also a little feature request: even when the vendor id has been matched, show it somewhere in the output to be able to confirm it.
Good idea.

FYI the script only checks the vendor id for NVMe drives. There has never been a need to get the vendor id for SATA, or SAS, SSDs and HDDs.

<!-- gh-comment-id:2564819014 --> @007revad commented on GitHub (Dec 29, 2024): A bigger concern is why one of your drive models is shown as "4TB" `4TB,VE0R5305,4000 GB` From a quick google for VE0R5305 it looks like that SSD drive is an Intenso SSD 4TB > Also a little feature request: even when the vendor id has been matched, show it somewhere in the output to be able to confirm it. Good idea. FYI the script only checks the vendor id for NVMe drives. There has never been a need to get the vendor id for SATA, or SAS, SSDs and HDDs.
Author
Owner

@phit42 commented on GitHub (Dec 30, 2024):

A bigger concern is why one of your drive models is shown as "4TB" 4TB,VE0R5305,4000 GB

From a quick google for VE0R5305 it looks like that SSD drive is an Intenso SSD 4TB

Also a little feature request: even when the vendor id has been matched, show it somewhere in the output to be able to confirm it.
Good idea.

FYI the script only checks the vendor id for NVMe drives. There has never been a need to get the vendor id for SATA, or SAS, SSDs and HDDs.

Because it is a cheap rip-off, I now assume :(

Anyway, thank you for the quick fix.
Should my tmpRoot point to sth and is broken, or is it sth the script is using?

<!-- gh-comment-id:2565999243 --> @phit42 commented on GitHub (Dec 30, 2024): > A bigger concern is why one of your drive models is shown as "4TB" `4TB,VE0R5305,4000 GB` > > From a quick google for VE0R5305 it looks like that SSD drive is an Intenso SSD 4TB > > > Also a little feature request: even when the vendor id has been matched, show it somewhere in the output to be able to confirm it. > > Good idea. > > FYI the script only checks the vendor id for NVMe drives. There has never been a need to get the vendor id for SATA, or SAS, SSDs and HDDs. Because it is a cheap rip-off, I now assume :( Anyway, thank you for the quick fix. Should my tmpRoot point to sth and is broken, or is it sth the script is using?
Author
Owner

@007revad commented on GitHub (Dec 31, 2024):

tmpRoot is created by DSM when booting. But it should not exist once DSM has booted. None of my 3 Synology NAS has a /tmpRoot folder or symlink.

<!-- gh-comment-id:2566047885 --> @007revad commented on GitHub (Dec 31, 2024): tmpRoot is created by DSM when booting. But it should not exist once DSM has booted. None of my 3 Synology NAS has a /tmpRoot folder or symlink.
Author
Owner

@phit42 commented on GitHub (Dec 31, 2024):

Thanx 007revad. This can be closed.

<!-- gh-comment-id:2566497580 --> @phit42 commented on GitHub (Dec 31, 2024): Thanx 007revad. This can be closed.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/Synology_HDD_db#647
No description provided.