There's no lsblk
in Synology DSM or openwrt. You could search for /sys/block/*/device
similarly as when looking for the disk sizes.
This can be rounded up, because on systems which have 1GB of RAM, it will result in 0GB (because it subtracts the amount allocated for the kernel).
There is a trick to make the code more readable. Use a negative condition and continue
. This will reduce indentation.
It misreports on some DDR4 systems and I haven't found conclusive clarification. I have one system for example which reports TotalWidth 72 and DataWidth 72. But it doesn't influence the amount of…
one:
Handle 0x0001, DMI type 1, 27 bytes
System Information
Manufacturer: To Be Filled By O.E.M.
Product Name: X570D4U
Version: To Be Filled By O.E.M.
Serial Number: To Be Filled By…
I need to verify how it works if there are multiple processors. I have a couple of dual-socket systems, but they always have the same processor model.
I was looking at some systems, and sometimes both TotalWidth and DataWidth is 72. I'm not really sure what it means. I vaguely remember reading that that's a bug in some DDR4 modules or motherboards. For now I would only check for TotalWidth and ignore DataWidth.