smart scheduled tests problem

  • Hi guys, I have a strange problem with how hard disks are displayed in the "Scheduled tests" tab of SMART menu. There are six disks connected to Odroid based hardware using Orico USB-to-sata bridges. But OMV shows only two available disks on the "Scheduled Test" tab when I attempt to schedule a test. I have tested it with other cheap USB-to-Sata convertes, but with the same result. Am I doing something wrong or did I discover a bug?

  • Thank you for help. The results are below:


    {
    "enable": true,
    "interval": 1800,
    "monitor": {
    "device": [
    {
    "devicefile": "/dev/disk/by-id/usb-WDC_WD32_00BEVT-22ZCT0_20120816-0:0",
    "devicetype": "sat",
    "enable": true,
    "uuid": "e8189f6d-ca26-493f-b19a-b22368c1e0d7"
    },
    {
    "devicefile": "/dev/disk/by-id/usb-WDC_WD75_00BPKT-22PK4T0_20120816-0:0",
    "devicetype": "sat",
    "enable": true,
    "uuid": "a5cbbabf-7a01-4b18-82b3-94bb5ae2899a"
    },
    {
    "devicefile": "/dev/disk/by-id/usb-DH_Ext._HDD_20161012-0:0",
    "devicetype": "sat",
    "enable": true,
    "uuid": "4ad036a8-a05c-411a-b9c9-730e52215a9d"
    },
    {
    "devicefile": "/dev/disk/by-id/usb-HGST_HTS_721010A9E630_20120816-0:0",
    "devicetype": "sat",
    "enable": true,
    "uuid": "c5c68593-4703-4a22-aca4-1a89bbf3e371"
    },
    {
    "devicefile": "/dev/disk/by-id/usb-WDC_WD75_00BPKT-22PK4T0_0000000000000033-0:0",
    "devicetype": "sat",
    "enable": true,
    "uuid": "d831dbdd-ff7e-4118-8ef5-595611af6a1d"
    },
    {
    "devicefile": "/dev/disk/by-id/usb-Genesys_USB3_SATA_Bridge_0000000000000033-0:0",
    "devicetype": "sat",
    "enable": true,
    "uuid": "92da75a8-7a64-4beb-8165-5bd833bb60af"
    },
    {
    "devicefile": "/dev/disk/by-id/usb-ATA_ST4000LM024-2AN1_0123456789ABCDE-0:0",
    "devicetype": "sat",
    "enable": true,
    "uuid": "aa82d723-a015-4963-8f4e-ffa907565cd1"
    },
    {
    "devicefile": "/dev/disk/by-id/usb-ST4000LM_024-2AN17V_20120816-0:0",
    "devicetype": "sat",
    "enable": true,
    "uuid": "adf28eee-c836-4efd-a00e-04b3412c16c0"
    },
    {
    "devicefile": "/dev/disk/by-id/usb-ATA_HGST_HTS721010A9_0123456789ABCDE-0:0",
    "devicetype": "sat",
    "enable": true,
    "uuid": "6e9dac9d-0de5-410d-bd13-8abb337790fa"
    },
    {
    "devicefile": "/dev/disk/by-id/usb-External_USB3.0_201703310007F-0:0",
    "devicetype": "sat",
    "enable": true,
    "uuid": "3a6c3fb4-5c69-4870-92ae-c3a322b199ce"
    }
    ]
    },
    "powermode": "idle",
    "scheduledtests": {
    "job": [
    {
    "comment": "",
    "dayofmonth": "*",
    "dayofweek": "*",
    "devicefile": "/dev/disk/by-id/usb-External_USB3.0_201703310007F-0:0",
    "enable": false,
    "hour": "19",
    "month": "*",
    "type": "L",
    "uuid": "699d6d51-1e92-440b-be06-13ffef850ce7"
    },
    {
    "comment": "",
    "dayofmonth": "*",
    "dayofweek": "*",
    "devicefile": "/dev/disk/by-id/usb-External_USB3.0_201703310007F-0:0",
    "enable": false,
    "hour": "19",
    "month": "*",
    "type": "L",
    "uuid": "9853b86e-6093-42d8-845a-6b6e22c82e42"
    },
    {
    "comment": "",
    "dayofmonth": "*",
    "dayofweek": "*",
    "devicefile": "/dev/disk/by-id/usb-External_USB3.0_201703310007F-0:0",
    "enable": false,
    "hour": "19",
    "month": "*",
    "type": "L",
    "uuid": "e129287b-192e-4b72-8c96-7be16a7dd5b1"
    },
    {
    "comment": "",
    "dayofmonth": "*",
    "dayofweek": "*",
    "devicefile": "/dev/disk/by-id/usb-External_USB3.0_201703310007F-0:0",
    "enable": false,
    "hour": "19",
    "month": "*",
    "type": "L",
    "uuid": "7ca431b7-321c-4cbc-bef5-4d5d0d73ddd7"
    }
    ]
    },
    "tempcrit": 0,
    "tempdiff": 0,
    "tempinfo": 0
    }

  • The results are:


    [{"devicename":"sda","devicefile":"\/dev\/sda","devicelinks":["\/dev\/disk\/by-id\/usb-ATA_HGST_HTS721010A9_0123456789ABCDE-0:0","\/dev\/disk\/by-path\/platform-xhci-hcd.2.auto-usb-0:1.1.1.1:1.0-scsi-0:0:0:0"],"model":"HGST HTS721010A9","size":"1000204886016","temperature":"37\u00b0C","description":"HGST HTS721010A9 [\/dev\/sda, 931.51 GiB]","vendor":"ATA","serialnumber":"0123456789ABCDE","overallstatus":"GOOD"},{"devicename":"sdb","devicefile":"\/dev\/sdb","devicelinks":["\/dev\/disk\/by-id\/usb-ATA_HGST_HTS721010A9_0123456789ABCDE-0:0","\/dev\/disk\/by-path\/platform-xhci-hcd.2.auto-usb-0:1.1.1.2:1.0-scsi-0:0:0:0"],"model":"HGST HTS721010A9","size":"1000204886016","temperature":"28\u00b0C","description":"HGST HTS721010A9 [\/dev\/sdb, 931.51 GiB]","vendor":"ATA","serialnumber":"0123456789ABCDE","overallstatus":"GOOD"},{"devicename":"sdc","devicefile":"\/dev\/sdc","devicelinks":["\/dev\/disk\/by-id\/usb-External_USB3.0_201703310007F-0:0","\/dev\/disk\/by-path\/platform-xhci-hcd.2.auto-usb-0:1.1.1.4:1.0-scsi-0:0:0:0"],"model":"USB3.0","size":"4000787030016","temperature":"40\u00b0C","description":"USB3.0 [\/dev\/sdc, 3.63 TiB]","vendor":"External","serialnumber":"201703310007F","overallstatus":"GOOD"},{"devicename":"sdd","devicefile":"\/dev\/sdd","devicelinks":["\/dev\/disk\/by-id\/usb-External_USB3.0_201703310007F-0:0","\/dev\/disk\/by-path\/platform-xhci-hcd.2.auto-usb-0:1.1.2:1.0-scsi-0:0:0:0"],"model":"USB3.0","size":"4000787030016","temperature":"30\u00b0C","description":"USB3.0 [\/dev\/sdd, 3.63 TiB]","vendor":"External","serialnumber":"201703310007F","overallstatus":"GOOD"},{"devicename":"sde","devicefile":"\/dev\/sde","devicelinks":["\/dev\/disk\/by-id\/usb-External_USB3.0_201703310007F-0:0","\/dev\/disk\/by-path\/platform-xhci-hcd.2.auto-usb-0:1.1.3:1.0-scsi-0:0:0:0"],"model":"USB3.0","size":"4000787030016","temperature":"33\u00b0C","description":"USB3.0 [\/dev\/sde, 3.63 TiB]","vendor":"External","serialnumber":"201703310007F","overallstatus":"GOOD"},{"devicename":"sdf","devicefile":"\/dev\/sdf","devicelinks":["\/dev\/disk\/by-id\/usb-External_USB3.0_201703310007F-0:0","\/dev\/disk\/by-path\/platform-xhci-hcd.2.auto-usb-0:1.1.4:1.0-scsi-0:0:0:0"],"model":"USB3.0","size":"4000787030016","temperature":"29\u00b0C","description":"USB3.0 [\/dev\/sdf, 3.63 TiB]","vendor":"External","serialnumber":"201703310007F","overallstatus":"GOOD"}]

  • This is really strange, but the device file usb-External_USB3.0_201703310007F-0:0 exists four times, but every time with a different /dev/disk/by-path/ device file. This looks to me there is a bug in the kernel which does not generate unique device files.


    Code
    /dev/disk/by-id/usb-External_USB3.0_201703310007F-0:0 /dev/disk/by-path/platform-xhci-hcd.2.auto-usb-0:1.1.1.4:1.0-scsi-0:0:0:0
    /dev/disk/by-id/usb-External_USB3.0_201703310007F-0:0 /dev/disk/by-path/platform-xhci-hcd.2.auto-usb-0:1.1.2:1.0-scsi-0:0:0:0
    /dev/disk/by-id/usb-External_USB3.0_201703310007F-0:0 /dev/disk/by-path/platform-xhci-hcd.2.auto-usb-0:1.1.3:1.0-scsi-0:0:0:0
    /dev/disk/by-id/usb-External_USB3.0_201703310007F-0:0 /dev/disk/by-path/platform-xhci-hcd.2.auto-usb-0:1.1.4:1.0-scsi-0:0:0:0


    Please execute the following to approve the data collected by OMV.



    Bash
    # udevadm info --query=property --name=/dev/sdb
    # udevadm info --query=property --name=/dev/sdc
    # udevadm info --query=property --name=/dev/sdd
    # udevadm info --query=property --name=/dev/sde
  • I've done as you said. The output is:


    # udevadm info --query=property --name=/dev/sdb
    DEVLINKS=/dev/disk/by-id/usb-ATA_HGST_HTS721010A9_0123456789ABCDE-0:0 /dev/disk/by-path/platform-xhci-hcd.2.auto-usb-0:1.1.1.2:1.0-scsi-0:0:0:0
    DEVNAME=/dev/sdb
    DEVPATH=/devices/platform/soc:/soc:usb3-0:/12000000.dwc3:/xhci-hcd.2.auto/usb4/4-1/4-1.1/4-1.1.1/4-1.1.1.2/4-1.1.1.2:1.0/host1/target1:0:0/1:0:0:0/block/sdb
    DEVTYPE=disk
    ID_BUS=usb
    ID_INSTANCE=0:0
    ID_MODEL=HGST_HTS721010A9
    ID_MODEL_ENC=HGST\x20HTS721010A9
    ID_MODEL_ID=1066
    ID_PART_TABLE_TYPE=gpt
    ID_PART_TABLE_UUID=970c8767-28a4-43c3-85c9-8d208aa23cae
    ID_PATH=platform-xhci-hcd.2.auto-usb-0:1.1.1.2:1.0-scsi-0:0:0:0
    ID_PATH_TAG=platform-xhci-hcd_2_auto-usb-0_1_1_1_2_1_0-scsi-0_0_0_0
    ID_REVISION=A3J0
    ID_SERIAL=ATA_HGST_HTS721010A9_0123456789ABCDE-0:0
    ID_SERIAL_SHORT=0123456789ABCDE
    ID_TYPE=disk
    ID_USB_DRIVER=usb-storage
    ID_USB_INTERFACES=:080650:
    ID_USB_INTERFACE_NUM=00
    ID_VENDOR=ATA
    ID_VENDOR_ENC=ATA\x20\x20\x20\x20\x20
    ID_VENDOR_ID=2537
    MAJOR=8
    MINOR=16
    SUBSYSTEM=block
    TAGS=:systemd:
    USEC_INITIALIZED=72457



    # udevadm info --query=property --name=/dev/sdc
    DEVLINKS=/dev/disk/by-id/usb-External_USB3.0_201703310007F-0:0 /dev/disk/by-path/platform-xhci-hcd.2.auto-usb-0:1.1.1.4:1.0-scsi-0:0:0:0
    DEVNAME=/dev/sdc
    DEVPATH=/devices/platform/soc:/soc:usb3-0:/12000000.dwc3:/xhci-hcd.2.auto/usb4/4-1/4-1.1/4-1.1.1/4-1.1.1.4/4-1.1.1.4:1.0/host2/target2:0:0/2:0:0:0/block/sdc
    DEVTYPE=disk
    ID_BUS=usb
    ID_INSTANCE=0:0
    ID_MODEL=USB3.0
    ID_MODEL_ENC=USB3.0\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20
    ID_MODEL_ID=0578
    ID_PATH=platform-xhci-hcd.2.auto-usb-0:1.1.1.4:1.0-scsi-0:0:0:0
    ID_PATH_TAG=platform-xhci-hcd_2_auto-usb-0_1_1_1_4_1_0-scsi-0_0_0_0
    ID_REVISION=0204
    ID_SERIAL=External_USB3.0_201703310007F-0:0
    ID_SERIAL_SHORT=201703310007F
    ID_TYPE=disk
    ID_USB_DRIVER=uas
    ID_USB_INTERFACES=:080650:080662:
    ID_USB_INTERFACE_NUM=00
    ID_VENDOR=External
    ID_VENDOR_ENC=External
    ID_VENDOR_ID=152d
    MAJOR=8
    MINOR=32
    SUBSYSTEM=block



    # udevadm info --query=property --name=/dev/sdd
    DEVLINKS=/dev/disk/by-id/usb-External_USB3.0_201703310007F-0:0 /dev/disk/by-path/platform-xhci-hcd.2.auto-usb-0:1.1.2:1.0-scsi-0:0:0:0
    DEVNAME=/dev/sdd
    DEVPATH=/devices/platform/soc:/soc:usb3-0:/12000000.dwc3:/xhci-hcd.2.auto/usb4/4-1/4-1.1/4-1.1.2/4-1.1.2:1.0/host3/target3:0:0/3:0:0:0/block/sdd
    DEVTYPE=disk
    ID_BUS=usb
    ID_INSTANCE=0:0
    ID_MODEL=USB3.0
    ID_MODEL_ENC=USB3.0\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20
    ID_MODEL_ID=0578
    ID_PATH=platform-xhci-hcd.2.auto-usb-0:1.1.2:1.0-scsi-0:0:0:0
    ID_PATH_TAG=platform-xhci-hcd_2_auto-usb-0_1_1_2_1_0-scsi-0_0_0_0
    ID_REVISION=0204
    ID_SERIAL=External_USB3.0_201703310007F-0:0
    ID_SERIAL_SHORT=201703310007F
    ID_TYPE=disk
    ID_USB_DRIVER=uas
    ID_USB_INTERFACES=:080650:080662:
    ID_USB_INTERFACE_NUM=00
    ID_VENDOR=External
    ID_VENDOR_ENC=External
    ID_VENDOR_ID=152d
    MAJOR=8
    MINOR=48
    SUBSYSTEM=block
    TAGS=:systemd:
    USEC_INITIALIZED=1053688



    # udevadm info --query=property --name=/dev/sde
    DEVLINKS=/dev/disk/by-id/usb-External_USB3.0_201703310007F-0:0 /dev/disk/by-path/platform-xhci-hcd.2.auto-usb-0:1.1.3:1.0-scsi-0:0:0:0
    DEVNAME=/dev/sde
    DEVPATH=/devices/platform/soc:/soc:usb3-0:/12000000.dwc3:/xhci-hcd.2.auto/usb4/4-1/4-1.1/4-1.1.3/4-1.1.3:1.0/host4/target4:0:0/4:0:0:0/block/sde
    DEVTYPE=disk
    ID_BUS=usb
    ID_INSTANCE=0:0
    ID_MODEL=USB3.0
    ID_MODEL_ENC=USB3.0\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20
    ID_MODEL_ID=0578
    ID_PATH=platform-xhci-hcd.2.auto-usb-0:1.1.3:1.0-scsi-0:0:0:0
    ID_PATH_TAG=platform-xhci-hcd_2_auto-usb-0_1_1_3_1_0-scsi-0_0_0_0
    ID_REVISION=0204
    ID_SERIAL=External_USB3.0_201703310007F-0:0
    ID_SERIAL_SHORT=201703310007F
    ID_TYPE=disk
    ID_USB_DRIVER=uas
    ID_USB_INTERFACES=:080650:080662:
    ID_USB_INTERFACE_NUM=00
    ID_VENDOR=External
    ID_VENDOR_ENC=External
    ID_VENDOR_ID=152d
    MAJOR=8
    MINOR=64
    SUBSYSTEM=block
    TAGS=:systemd:



    # udevadm info --query=property --name=/dev/sdf
    DEVLINKS=/dev/disk/by-id/usb-External_USB3.0_201703310007F-0:0 /dev/disk/by-path/platform-xhci-hcd.2.auto-usb-0:1.1.4:1.0-scsi-0:0:0:0
    DEVNAME=/dev/sdf
    DEVPATH=/devices/platform/soc:/soc:usb3-0:/12000000.dwc3:/xhci-hcd.2.auto/usb4/4-1/4-1.1/4-1.1.4/4-1.1.4:1.0/host5/target5:0:0/5:0:0:0/block/sdf
    DEVTYPE=disk
    ID_BUS=usb
    ID_INSTANCE=0:0
    ID_MODEL=USB3.0
    ID_MODEL_ENC=USB3.0\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20
    ID_MODEL_ID=0578
    ID_PATH=platform-xhci-hcd.2.auto-usb-0:1.1.4:1.0-scsi-0:0:0:0
    ID_PATH_TAG=platform-xhci-hcd_2_auto-usb-0_1_1_4_1_0-scsi-0_0_0_0
    ID_REVISION=0204
    ID_SERIAL=External_USB3.0_201703310007F-0:0
    ID_SERIAL_SHORT=201703310007F
    ID_TYPE=disk
    ID_USB_DRIVER=uas
    ID_USB_INTERFACES=:080650:080662:
    ID_USB_INTERFACE_NUM=00
    ID_VENDOR=External
    ID_VENDOR_ENC=External
    ID_VENDOR_ID=152d
    MAJOR=8
    MINOR=80
    SUBSYSTEM=block
    TAGS=:systemd:
    USEC_INITIALIZED=8561318
    USEC_INITIALIZED=268818



    I wonder if USB hub can be part of the problem. I can try disconnecting the four 4TB disks from from externally powered USB hub and connecting two of them directly to Odroid. I don't like doing that due to the limited current on Odroid power supply, large capacity hdd can be very power-hungry, but if it will provide any useful information I will happy to do it. Do you think it is worth doing that?

  • This issue is still present even after connecting two 4TB hdds directly to the available USB3.0 ports on Odroid. This made me believe that USB hub is not problematic. It happens because each type of USB-to-SATA bridge provides the same ID_SERIAL , hence if there are several hdds connected via identical USB-to-SATA bridges then they will all have same ID_SERIAL. This problem is unfortunately unavoidable unless I buy different USB-to-SATA bridge for each hdd, it is a bit unpractical and risky. I guess I'll have to do smart test manually. It would be nice if OMV had a a tick box to schedule smart tests on all available hdds without worrying which hdd is which, I think users want to test all hdds on regular basis anyway. Or perhaps I could use OMV "Scheduled Jobs" to achieve the same?

  • This is a problem related to JMicron USB-to-SATA bridges (in this case JMS578 but this also applies to at least JMS567) and could be fixed with a firmware upgrade: https://forum.armbian.com/topi…findComment&comment=43735


    @jtronics: you should report this over at Hardkernel forums too since there are currently a couple of issues with JMicron firmwares and they're already in touch with the vendor (who is most probably not even aware of the issue now)

  • Thank you for helping me understand this all. I upgraded the firmware on four USB-to-SATA bridges. That solved the spin-down problem which I wasn't even aware that it exists. The smart devices tab now looks differently, model numbers are completely gone and verndor changed to JMicron. I'm also under impression that omv shows hdd smart informatino more promptly and does not display any errors as it used to happen before. But this maybe a placebo effect.


    Can you please help me understand why hdd model and vendor fields are different on omv devices tab and on hdd smart information window, as shown on the attached pictures? I'm guessing omv uses different utilities to get this information? Interestingly hdd serial numbers are different in the hdd smart information window.

  • Compare the output below please:


    root@odroidxu4:~# udevadm info --query=property --name=/dev/sda | grep -i serial
    ID_SERIAL=JMicron_USB_to_SATA_bridge_DB00000000013B-0:0
    ID_SERIAL_SHORT=DB00000000013B
    root@odroidxu4:~# smartctl -d sat -a /dev/sda | grep -i serial
    Serial Number: S1RLNSAF805588
    root@odroidxu4:~# lsusb -v | grep -i serial
    ...
    iSerial 3 DB00000000013B


    root@odroidxu4:~# udevadm info --query=property --name=/dev/sda | grep -i serial
    ID_SERIAL=SAMSUNG_MZ7TE128HMGR-00004_S1RLNSAF805588
    ID_SERIAL_SHORT=S1RLNSAF805588
    root@odroidxu4:~# smartctl -a /dev/sda | grep -i serial
    Serial Number: S1RLNSAF805588
    root@odroidxu4:~# lsusb -v | grep -i serial
    ...
    iSerial 1 2014010000C5


    JMS578 and then ASM1153. The latter handing out the drive's serial to udev, the former the chip's firmware revision or whatever. This needs to be fixed by JMicron since drive serial numbers (and WWNs) exist for a reason. We need JMicron firmware upgrades fixing the SAT ( SCSI / ATA translation) and serial number issues.

  • I always dreamed to operate RAID6 array

    Tired of repeating the same again and again :)


    RAID is only about availability (business continuity) so it's pretty useless at home. When users don't understand that it has zero data protection features (as an awful lot of OMV users do) then it gets already dangerous and when it's implemented with a huge single point of failure as central design element (USB hub) it gets bizarre.

  • You ruined my dreams :) however I suppose its better be safe than sorry. I'll experiment with snapraid instead and leaving few hard drives on the shelf until sudden hardware failure. This also makes me wonder if Olimex-Lime2 with native SATA interface would a better candidate for a home server.

  • If I would want to combine a bunch of USB disks behind an USB hub at least with kernel 4.9 or higher I would most probably choose a btrfs linear setup (I explained it recently in the Raspberry Pi announcement thread since there all disks are behind an USB hub all the time and playing USB RAID with Raspberries would be even more insane)

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!