Commit graph

3 commits

Author SHA1 Message Date
Konstantin Shalygin
3a49418e45
collect-smartctl-json: shell fixes for script (#188)
* Remove `"`, `(` and `)` from file names (see #188)
* Added regex ignore for some devices, fixes:

```
Collecting data for '/dev/sda'...       Saving to sat-Intel_S4510_S4610_S4500_S4600_Series_SSDs-INTEL_SSDSC2KB240G8-sda.json
Collecting data for '/dev/sdb'...       Saving to sat-Intel_S4510_S4610_S4500_S4600_Series_SSDs-INTEL_SSDSC2KB240G8-sdb.json
Collecting data for '/dev/bus/0'...jq: error (at <stdin>:34): null (null) cannot be matched, as it is not a string
        Saving to null-null--0.json
Collecting data for '/dev/bus/0'...jq: error (at <stdin>:34): null (null) cannot be matched, as it is not a string
        Saving to null-null--0.json
Collecting data for '/dev/nvme0'...     Saving to nvme-null-HUSMR7632BHP301-nvme0.json
Collecting data for '/dev/nvme1'...     Saving to nvme-null-HUSMR7632BHP301-nvme1.json
Collecting data for '/dev/nvme2'...     Saving to nvme-null-HUSMR7632BHP301-nvme2.json
Collecting data for '/dev/nvme3'...     Saving to nvme-null-HUSMR7632BHP301-nvme3.json
Collecting data for '/dev/nvme4'...     Saving to nvme-null-HUSMR7632BHP301-nvme4.json
```

The `/dev/bus/*` is some pseudo-device comes with Broadcom driver, after fix:

```
Collecting data for '/dev/sda'...       Saving to sat-Intel_S4510_S4610_S4500_S4600_Series_SSDs-INTEL_SSDSC2KB240G8-sda.json
Collecting data for '/dev/sdb'...       Saving to sat-Intel_S4510_S4610_S4500_S4600_Series_SSDs-INTEL_SSDSC2KB240G8-sdb.json
Collecting data for '/dev/nvme0'...     Saving to nvme-null-HUSMR7632BHP301-nvme0.json
Collecting data for '/dev/nvme1'...     Saving to nvme-null-HUSMR7632BHP301-nvme1.json
Collecting data for '/dev/nvme2'...     Saving to nvme-null-HUSMR7632BHP301-nvme2.json
Collecting data for '/dev/nvme3'...     Saving to nvme-null-HUSMR7632BHP301-nvme3.json
Collecting data for '/dev/nvme4'...     Saving to nvme-null-HUSMR7632BHP301-nvme4.json
```

Signed-off-by: Konstantin Shalygin <k0ste@k0ste.ru>
2023-12-30 12:55:13 +03:00
Konstantin Shalygin
9db6746825
collect-smartctl-json: shell fixes for script (#178)
Signed-off-by: Konstantin Shalygin <k0ste@k0ste.ru>
2023-11-20 16:33:28 +01:00
David Randall
8193e8eb3b Chg: Impvoe the JSON collection script; now requires jq/yq
Signed-off-by: David Randall <David@NiceGuyIT.biz>
2023-11-15 20:43:43 -05:00