Skip to content

fix(collector): preserve jmb39x-q device type and accept usable SMART JSON #663

Description

@Starosdev

Summary

Scrutiny cannot reliably monitor QNAP TR-004 disks in Individual mode when smartmontools uses the jmb39x-q,N backend.

Source

Upstream discussion: AnalogJ#1028

Problem

Two collector behaviors prevent usable SMART data:

  1. A configured device type such as jmb39x-q,0 is split into separate arguments instead of being passed as one --device jmb39x-q,0 value.
  2. The collector rejects otherwise complete SMART JSON when smartctl returns exit_status = 4 for the non-fatal warning Read Device Statistics page 0x00 failed.

Expected behavior

  • Preserve jmb39x-q,N as one smartctl device-type argument for information and SMART collection commands.
  • Parse and store valid SMART data when the JSON contains usable identity and metrics despite a non-zero warning status.
  • Continue rejecting genuinely unusable or fatal smartctl output.

Acceptance criteria

  • Add regression coverage for comma-containing device types such as jmb39x-q,0.
  • Add regression coverage for valid SMART JSON with non-zero warning exit status.
  • Verify QNAP TR-004 collection produces device identity and SMART metrics instead of No Data.
  • Document any required QNAP collector configuration.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingcollectorCollector component

    Projects

    Status
    Bug Backlog

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions