Closed FedorPRO closed 1 year ago
Strange, it works for me with NVMe disks. What does the python script from this repo show?
Like:
# /etc/zabbix/scripts/sensors.py
{
"hwmon0-nvme": {
"temp1": {
"alarm": 0,
"crit": 94850,
"input": 54850,
"label": "Composite",
"max": 89850,
"min": -60150,
"sensor_type": "temp"
}
},
"hwmon1-nvme": {
"temp1": {
"alarm": 0,
"crit": 94850,
"input": 55850,
"label": "Composite",
"max": 89850,
"min": -60150,
"sensor_type": "temp"
}
},
"hwmon2-pch_lewisburg": {
"temp1": {
"input": 67000,
"sensor_type": "temp"
}
},
"hwmon3-coretemp": {
"temp1": {
"crit": 99000,
"crit_alarm": 0,
"input": 63000,
"label": "Package id 0",
"max": 89000,
"sensor_type": "temp"
},
"temp2": {
"crit": 99000,
"crit_alarm": 0,
"input": 61000,
"label": "Core 0",
"max": 89000,
"sensor_type": "temp"
},
"temp3": {
"crit": 99000,
"crit_alarm": 0,
"input": 59000,
"label": "Core 1",
"max": 89000,
"sensor_type": "temp"
},
"temp4": {
"crit": 99000,
"crit_alarm": 0,
"input": 63000,
"label": "Core 3",
"max": 89000,
"sensor_type": "temp"
},
"temp5": {
"crit": 99000,
"crit_alarm": 0,
"input": 60000,
"label": "Core 4",
"max": 89000,
"sensor_type": "temp"
}
}
}
I checked the script sensors.py and it is completely identical to the one in the repository
Script output:
root@pve02:~# /etc/zabbix/scripts/sensors.py
[
{
"{#ADAPTER}": "nvme-pci-0400",
"{#TYPE}": "TEMP",
"{#NAME}": "Composite",
"{#MIN}": -273.15,
"{#HIGH}": 82.85,
"{#CRIT}": 84.85,
"{#TEMP_ID}": "temp1"
},
{
"{#ADAPTER}": "nvme-pci-0200",
"{#TYPE}": "TEMP",
"{#NAME}": "Composite",
"{#MIN}": -273.15,
"{#HIGH}": 82.85,
"{#CRIT}": 84.85,
"{#TEMP_ID}": "temp1"
},
{
"{#ADAPTER}": "acpitz-acpi-0",
"{#TYPE}": "TEMP",
"{#NAME}": "temp1",
"{#MIN}": 0.0,
"{#HIGH}": 90.0,
"{#CRIT}": 100.0,
"{#TEMP_ID}": "temp1"
},
{
"{#ADAPTER}": "acpitz-acpi-0",
"{#TYPE}": "TEMP",
"{#NAME}": "temp2",
"{#MIN}": 0.0,
"{#HIGH}": 90.0,
"{#CRIT}": 100.0,
"{#TEMP_ID}": "temp2"
},
{
"{#ADAPTER}": "coretemp-isa-0000",
"{#TYPE}": "TEMP",
"{#NAME}": "Package id 0",
"{#MIN}": 0.0,
"{#HIGH}": 68.0,
"{#CRIT}": 73.0,
"{#TEMP_ID}": "temp1"
},
{
"{#ADAPTER}": "coretemp-isa-0000",
"{#TYPE}": "TEMP",
"{#NAME}": "Core 0",
"{#MIN}": 0.0,
"{#HIGH}": 68.0,
"{#CRIT}": 73.0,
"{#TEMP_ID}": "temp2"
},
{
"{#ADAPTER}": "coretemp-isa-0000",
"{#TYPE}": "TEMP",
"{#NAME}": "Core 1",
"{#MIN}": 0.0,
"{#HIGH}": 68.0,
"{#CRIT}": 73.0,
"{#TEMP_ID}": "temp3"
},
{
"{#ADAPTER}": "coretemp-isa-0000",
"{#TYPE}": "TEMP",
"{#NAME}": "Core 2",
"{#MIN}": 0.0,
"{#HIGH}": 68.0,
"{#CRIT}": 73.0,
"{#TEMP_ID}": "temp4"
},
{
"{#ADAPTER}": "coretemp-isa-0000",
"{#TYPE}": "TEMP",
"{#NAME}": "Core 3",
"{#MIN}": 0.0,
"{#HIGH}": 68.0,
"{#CRIT}": 73.0,
"{#TEMP_ID}": "temp5"
},
{
"{#ADAPTER}": "nvme-pci-0300",
"{#TYPE}": "TEMP",
"{#NAME}": "Composite",
"{#MIN}": -273.15,
"{#HIGH}": 82.85,
"{#CRIT}": 84.85,
"{#TEMP_ID}": "temp1"
},
{
"{#ADAPTER}": "nvme-pci-0100",
"{#TYPE}": "TEMP",
"{#NAME}": "Composite",
"{#MIN}": -273.15,
"{#HIGH}": 82.85,
"{#CRIT}": 84.85,
"{#TEMP_ID}": "temp1"
}
]
Hmm, now I wonder if I did some changes to script and didn't commit it... let me check
I've committed the latest version that I had - it's using direct access to sysfs
instead of calling sensors
. Templates are also re-uploaded to match. Please try. Also sensors.conf
was updated so also fetch to match.
Yes, I deployed all the updated files to 3 servers in my home lab - and for all servers, information is now correctly collected (CPU, NVME disks and mb sensors). Thank you very much for your hard work, how can I thank you?
Super. No worries! :)
Hello! First of all, many thanks for the template and scripts. I haven't found a better fit for my case, but I've run into a problem that I can't solve on my own. I spent a lot of time, but to no avail. The problem is that this set of scripts and the zabbix template normally work only with the CPU temperature, if there are NMVE disks or motherboard sensors in the system agent will swear with errors:
This is an example of a sensors -j command output from a server where there is no collection from NMVE and ACPI interface:
Can you tell me in which direction to search for the cause of the problem in order to collect information completely on all sensors. I am using Zabbix Server version 6.4 and Zabbix Agent 2 on hosts