Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: stop spamming error logs for disks without block dev queue stats
not all devices have them. fixes errors such as this: ``` [root@testbox-arch /]# journalctl -ex -u mango.service --no-pager | grep -i 'no such' Jul 28 18:52:50 testbox-arch mango[79]: {"time":"2024-07-28T18:52:50.862645518Z","level":"ERROR","msg":"Failed to get queue stats for block device","hostname":{"system":"testbox-arch","inventory":"testbox-arch"},"worker":"manager","manager":{"inventory":"/opt/mango/inventory","hostname":"testbox-arch","enrolled":true,"runID":"01J3XB0DSDX99FXHCJ79JM2HGE"},"metadata_collector":"storage","err":"open /sys/block/zram0/queue/nr_requests: no such file or directory","device":"zram0"} Jul 28 18:52:52 testbox-arch mango[79]: {"time":"2024-07-28T18:52:52.922005911Z","level":"ERROR","msg":"Failed to get queue stats for block device","hostname":{"system":"testbox-arch","inventory":"testbox-arch"},"worker":"manager","manager":{"inventory":"/opt/mango/inventory","hostname":"testbox-arch","enrolled":true,"runID":"01J3XB0FSQ6BPT9FP6ZXMJ78GT"},"metadata_collector":"storage","err":"open /sys/block/zram0/queue/nr_requests: no such file or directory","device":"zram0"} Jul 28 18:52:54 testbox-arch mango[79]: {"time":"2024-07-28T18:52:54.975231863Z","level":"ERROR","msg":"Failed to get queue stats for block device","hostname":{"system":"testbox-arch","inventory":"testbox-arch"},"worker":"manager","manager":{"inventory":"/opt/mango/inventory","hostname":"testbox-arch","enrolled":true,"runID":"01J3XB0HSWH4Y8BTAWD04T4875"},"metadata_collector":"storage","err":"open /sys/block/zram0/queue/rq_affinity: no such file or directory","device":"zram0"} Jul 28 18:52:57 testbox-arch mango[79]: {"time":"2024-07-28T18:52:57.018631108Z","level":"ERROR","msg":"Failed to get queue stats for block device","hostname":{"system":"testbox-arch","inventory":"testbox-arch"},"worker":"manager","manager":{"inventory":"/opt/mango/inventory","hostname":"testbox-arch","enrolled":true,"runID":"01J3XB0KSQKTX1EK7MVDXT5VRB"},"metadata_collector":"storage","err":"open /sys/block/zram0/queue/rq_affinity: no such file or directory","device":"zram0"} ```
- Loading branch information