tomaae / homeassistant-openmediavault

OpenMediaVault integration for Home Assistant
Apache License 2.0
109 stars 16 forks source link

No temperature value on NVME drive #108

Closed BebeMischa closed 1 year ago

BebeMischa commented 1 year ago

Describe the issue

Temperature of NVME drive "unknown

How to reproduce the issue

Steps to reproduce the behavior:

  1. Install NVME drive
  2. Lookup available sensors

Expected behavior

The temperature of an NVME drive will be displayed the same way, ass SATA drives

Screenshots

afbeelding

Software versions

All fields in this sections are required.

Diagnostics data

config_entry-openmediavault-98524fbac0980bbe729327fa06f337d1.json.txt

Traceback/Error logs

Additional context

tomaae commented 1 year ago

Ah yea, nvme smart can be an issue. Can you try to debug it to see if it is even available via omv? Also, is nvme temperature visible in omv ui?

BebeMischa commented 1 year ago

Well, i can se the temp under SMART:

afbeelding

Will debug in the weekend time, to busy now ;-)

tomaae commented 1 year ago

sure, thanks :)

BebeMischa commented 1 year ago

home-assistant_openmediavault_2023-04-25T18-48-46.282Z(1).log

Hope, you can find something in here... ;-)

tomaae commented 1 year ago

yea, it is using different value names in smart. this should do it.

BebeMischa commented 1 year ago

Still gives 0 with 3542deb

afbeelding

tomaae commented 1 year ago

try now?

BebeMischa commented 1 year ago

ee07855

afbeelding

tomaae commented 1 year ago

oh, I made a mistake. nvme actually does not respond with data

2023-04-25 20:39:48.025 DEBUG (SyncWorker_6) [custom_components.openmediavault.omv_api] OpenMediaVault 192.168.178.133 query: Smart, getAttributes, {'devicefile': '/dev/nvme0n1'}, {'updatelastaccess': False}
2023-04-25 20:39:48.096 DEBUG (SyncWorker_6) [custom_components.openmediavault.omv_api] OpenMediaVault 192.168.178.133 query response: {'response': [], 'error': None}

Lets try different approach. Add smart to your dashboard and open inspector. Lookup for smart queries and lets see what kind of query and response we get for nvme.

Cant really give you exact example as smart wont work on VM, but this is close enough: image

BebeMischa commented 1 year ago

"Add smart to your dashboard"

How? (let me see, what is now covered by the inspector) ;-)

tomaae commented 1 year ago

I just added it like this: image

BebeMischa commented 1 year ago

Looks, like that gives only this, so there is no temperature info in it, I have to click on the nvme drive to see the info.

image

after click on nvme drive:

image

BebeMischa commented 1 year ago

Question:

{"service":"Smart","method":"getInformation","params":{"devicefile":"/dev/disk/by-id/nvme-SSSTC_CL1-8D128-HP_UJDJA01ZTDV489"},"options":null}

Answer:

{"response":{"devicefile":"\/dev\/nvme0n1","devicemodel":"SSSTC CL1-8D128-HP","serialnumber":"UJDJA01ZTDV489","wwn":"eui.38f6015630136112","firmwareversion":"L182","usercapacity":"","modelnumber":"SSSTC CL1-8D128-HP","pcivendorid":"0x1e95","pcivendorsubsystemid":"0x126f","ieeeouiidentifier":"0x38f601","totalnvmcapacity":"128,035,676,160 [128 GB]","unallocatednvmcapacity":"0","controllerid":"1","nvmeversion":"1.3","numberofnamespaces":"1","namespace1size\/capacity":"128,035,676,160 [128 GB]","namespace1formattedlbasize":"512","namespace1ieeeeui-64":"38f601 5630136112","localtimeis":"Thu Apr 27 12:10:47 2023 CEST","firmwareupdates(0x14)":"2 Slots, no Reset required","optionaladmincommands(0x0017)":"Security Format Frmw_DL Self_Test","optionalnvmcommands(0x001f)":"Comp Wr_Unc DS_Mngmt Wr_Zero Sav\/Sel_Feat","logpageattributes(0x07)":"S\/H_per_NS Cmd_Eff_Lg Ext_Get_Lg","maximumdatatransfersize":"64 Pages","warningcomp.temp.threshold":"84 Celsius","criticalcomp.temp.threshold":"85 Celsius","smartoverall-healthself-assessmenttestresult":"PASSED","criticalwarning":"0x00","temperature":"28","availablespare":"100%","availablesparethreshold":"5%","percentageused":"4%","dataunitsread":"1,770,735 [906 GB]","dataunitswritten":"3,169,343 [1.62 TB]","hostreadcommands":"28,036,584","hostwritecommands":"94,664,987","controllerbusytime":"1,176","powercycles":"76","poweronhours":"7,672","unsafeshutdowns":"42","mediaanddataintegrityerrors":"0","errorinformationlogentries":"0","warningcomp.temperaturetime":"0","criticalcomp.temperaturetime":"0","temperaturesensor1":"28 Celsius"},"error":null}
tomaae commented 1 year ago

can you try now?

BebeMischa commented 1 year ago

You are a fabulous winner! ;-)

image

tomaae commented 1 year ago

perfect :)