Closed ChristianDresel closed 1 month ago
...... smartmon.sh ........
device_list="$(/usr/sbin/smartctl --scan-open | awk '/^\/dev/{print $1 "|" $3}')"
for device in ${device_list}; do
disk="$(echo ${device} | cut -f1 -d'|')"
type="$(echo ${device} | cut -f2 -d'|')"
if [[ $type == *"nvme"* ]]; then
continue
fi
active=1
........
This should work now after the rewrite.
Hello on my device i have 2 nvme SSDs:
/usr/sbin/smartctl --scan-open | awk '/^\/dev/{print $1 "|" $3}' /dev/nvme0|nvme /dev/nvme1|nvme
but the output from smartmon.sh is broken:
smart.txt
one device is not insert and the line 21 "smartmon_disk type is not sat, scsi or megaraid but nvme" is complety broken, prometheus node exporter say:
Mar 08 09:59:25 vserver2 prometheus-node-exporter[27170]: time="2021-03-08T09:59:25+01:00" level=error msg="Error parsing \"/var/lib/prometheus/node-exporter/smart_metrics.prom\": text format parsing error in line 20: unknown metric type \ M
It's a proxmox System with
smartctl -v smartctl 7.1 2019-12-30 r5022 [x86_64-linux-5.4.78-1-pve] (local build)